mirror of
https://github.com/flarum/core.git
synced 2025-08-13 11:54:32 +02:00
Compare commits
94 Commits
as/code-mo
...
sm/3504-fi
Author | SHA1 | Date | |
---|---|---|---|
|
1caff3e6fc | ||
|
e21a1e09fd | ||
|
03178bb460 | ||
|
5753edac79 | ||
|
2e3d6dfa2c | ||
|
7cd28710bc | ||
|
bc1d6f9e91 | ||
|
bf4c543692 | ||
|
709c5566bb | ||
|
9a62c32c28 | ||
|
bbf90e42ff | ||
|
0859bb13a5 | ||
|
62be3e01be | ||
|
613523c9b4 | ||
|
3e56bd3dc6 | ||
|
293e8ab8b6 | ||
|
824fb2feff | ||
|
4923253fbf | ||
|
36c296d787 | ||
|
9fc2e5e2c0 | ||
|
cb47a9c92e | ||
|
5dedec12f9 | ||
|
5e81592e18 | ||
|
74bcab866c | ||
|
1d949a3170 | ||
|
79e0f44324 | ||
|
976a03c9e5 | ||
|
49ab6630d4 | ||
|
27fb011bf5 | ||
|
6466427061 | ||
|
818035f385 | ||
|
4748f31d93 | ||
|
e049e9d7ae | ||
|
776f9bf132 | ||
|
f882ff9bb5 | ||
|
535052e3dc | ||
|
c2ba3bb7d5 | ||
|
b7332895db | ||
|
0a3f449f9e | ||
|
df1bdd2ad8 | ||
|
8e2a99c1eb | ||
|
e45547c649 | ||
|
29362ed924 | ||
|
eb4bac3b8f | ||
|
584884a3c9 | ||
|
96ead2a4df | ||
|
556f10ddd8 | ||
|
a79e2c20fe | ||
|
89b194034b | ||
|
01c54b13c8 | ||
|
24c8c65aa5 | ||
|
17de76f326 | ||
|
d3008d1e62 | ||
|
471947dfa7 | ||
|
2f506f1b24 | ||
|
81cf6047f9 | ||
|
57d3c9a99a | ||
|
999b345db1 | ||
|
5e2f952fe6 | ||
|
899b931b89 | ||
|
0431f15ac0 | ||
|
6c57470b13 | ||
|
6ca2ebc437 | ||
|
dd915c126c | ||
|
62ffe5ffdf | ||
|
592039c483 | ||
|
2f64f023b2 | ||
|
316a2067b6 | ||
|
de8d0d1d37 | ||
|
aea1a4cf63 | ||
|
7f5593021d | ||
|
f9ae7cd67f | ||
|
843a613cda | ||
|
da83e0c1a0 | ||
|
903026a7e4 | ||
|
1954d0383e | ||
|
2e89ba3c94 | ||
|
b14c0780d2 | ||
|
d465fd27bc | ||
|
ffc9f9f5a4 | ||
|
290bc19922 | ||
|
863a8ddfff | ||
|
b8df3863d1 | ||
|
4cb15501a2 | ||
|
42602a099f | ||
|
be2da3e12f | ||
|
09bed537b3 | ||
|
fb717db57c | ||
|
cca97f32c6 | ||
|
c658eb10f4 | ||
|
f667faa1bd | ||
|
542cc42538 | ||
|
518b39610e | ||
|
6de1ea0194 |
23
.github/ISSUE_TEMPLATE/feature-request.md
vendored
23
.github/ISSUE_TEMPLATE/feature-request.md
vendored
@@ -1,26 +1,7 @@
|
||||
---
|
||||
name: "🚀 Feature Request"
|
||||
about: "I have a suggestion (and may want to implement it!)"
|
||||
about: "If you have a suggestion please head over to our forum!"
|
||||
|
||||
---
|
||||
|
||||
<!--
|
||||
IMPORTANT: Feature requests on this GitHub issue tracker are only accepted in case they have been approved by a core developer or contain extensive argumentation and directions for implementation. For all other feature requests, ideas and feedback please post in the Flarum Community: https://discuss.flarum.org/t/feedback.
|
||||
-->
|
||||
|
||||
## Feature Request
|
||||
|
||||
**Is your feature request related to a problem? Please describe.**
|
||||
A clear and concise description of what the problem is. eg. I have an issue when [...]
|
||||
|
||||
**Describe the solution you'd like**
|
||||
A detailed description of your proposed solution. Include:
|
||||
- How the feature would work/behave
|
||||
- Any potential drawbacks
|
||||
- Maybe a screenshot, design, or example code
|
||||
|
||||
**Justify why this feature belongs in Flarum's core, rather than in a third-party extension**
|
||||
Consider who this change will be useful to – most Flarum forums, or just a few?
|
||||
|
||||
**Describe alternatives you've considered**
|
||||
A clear and concise description of any alternative solutions or features you've considered.
|
||||
We primarily use GitHub as a bug tracker and issue tracker for items we are sure to tackle in the near future. For feature requests, ideas and feedback please post in the Flarum Community: https://discuss.flarum.org/t/proposals. Feature requests are added to GitHub only when they have been accepted by the development team and implementation details have been laid out.
|
||||
|
2
.github/ISSUE_TEMPLATE/support-question.md
vendored
2
.github/ISSUE_TEMPLATE/support-question.md
vendored
@@ -4,7 +4,7 @@ about: "If you have a question, please check out our forum or Discord!"
|
||||
|
||||
---
|
||||
|
||||
We primarily use GitHub as an issue tracker; for usage and support questions, please check out these resources below. Thanks!
|
||||
We primarily use GitHub as a bug tracker and issue tracker for items we are sure to tackle in the near future; for usage and support questions, please check out these resources below. Thanks!
|
||||
|
||||
* Flarum Community: https://discuss.flarum.org/
|
||||
* Discord Chat: https://flarum.org/discord/
|
||||
|
112
.github/workflows/REUSABLE_backend.yml
vendored
Normal file
112
.github/workflows/REUSABLE_backend.yml
vendored
Normal file
@@ -0,0 +1,112 @@
|
||||
name: Flarum Backend Jobs
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
enable_backend_testing:
|
||||
description: "Enable Backend Testing?"
|
||||
type: boolean
|
||||
default: true
|
||||
required: false
|
||||
|
||||
backend_directory:
|
||||
description: The directory of the project where backend code is located. This should contain a `composer.json` file, and is generally the root directory of the repo.
|
||||
type: string
|
||||
required: false
|
||||
default: '.'
|
||||
|
||||
php_versions:
|
||||
description: Versions of PHP to test with. Should be array of strings encoded as JSON array
|
||||
type: string
|
||||
required: false
|
||||
default: '["7.4", "8.0", "8.1"]'
|
||||
db_versions:
|
||||
description: Versions of databases to test with. Should be array of strings encoded as JSON array
|
||||
type: string
|
||||
required: false
|
||||
default: '["mysql:5.7", "mariadb"]'
|
||||
|
||||
php_ini_values:
|
||||
description: PHP ini values
|
||||
type: string
|
||||
required: false
|
||||
default: error_reporting=E_ALL
|
||||
|
||||
env:
|
||||
COMPOSER_ROOT_VERSION: dev-main
|
||||
FLARUM_TEST_TMP_DIR_LOCAL: tests/integration/tmp
|
||||
|
||||
jobs:
|
||||
test:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
php: ${{ fromJSON(inputs.php_versions) }}
|
||||
service: ${{ fromJSON(inputs.db_versions) }}
|
||||
prefix: ['', flarum_]
|
||||
|
||||
include:
|
||||
- service: 'mysql:5.7'
|
||||
db: MySQL
|
||||
- service: mariadb
|
||||
db: MariaDB
|
||||
- prefix: flarum_
|
||||
prefixStr: (prefix)
|
||||
|
||||
exclude:
|
||||
- php: 8.0
|
||||
service: 'mysql:5.7'
|
||||
prefix: flarum_
|
||||
- php: 8.0
|
||||
service: mariadb
|
||||
prefix: flarum_
|
||||
|
||||
services:
|
||||
mysql:
|
||||
image: ${{ matrix.service }}
|
||||
ports:
|
||||
- 13306:3306
|
||||
|
||||
name: 'PHP ${{ matrix.php }} / ${{ matrix.db }} ${{ matrix.prefixStr }}'
|
||||
|
||||
if: inputs.enable_backend_testing
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@master
|
||||
|
||||
- name: Setup PHP
|
||||
uses: shivammathur/setup-php@v2
|
||||
with:
|
||||
php-version: ${{ matrix.php }}
|
||||
coverage: xdebug
|
||||
extensions: curl, dom, gd, json, mbstring, openssl, pdo_mysql, tokenizer, zip
|
||||
tools: phpunit, composer:v2
|
||||
ini-values: ${{ inputs.php_ini_values }}
|
||||
|
||||
# The authentication alter is necessary because newer mysql versions use the `caching_sha2_password` driver,
|
||||
# which isn't supported prior to PHP7.4
|
||||
# When we drop support for PHP7.3, we should remove this from the setup.
|
||||
- name: Create MySQL Database
|
||||
run: |
|
||||
sudo systemctl start mysql
|
||||
mysql -uroot -proot -e 'CREATE DATABASE flarum_test;' --port 13306
|
||||
mysql -uroot -proot -e "ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root';" --port 13306
|
||||
|
||||
- name: Install Composer dependencies
|
||||
run: composer install
|
||||
working-directory: ${{ inputs.backend_directory }}
|
||||
|
||||
- name: Setup Composer tests
|
||||
run: composer test:setup
|
||||
working-directory: ${{ inputs.backend_directory }}
|
||||
env:
|
||||
DB_PORT: 13306
|
||||
DB_PASSWORD: root
|
||||
DB_PREFIX: ${{ matrix.prefix }}
|
||||
|
||||
- name: Run Composer tests
|
||||
run: composer test
|
||||
working-directory: ${{ inputs.backend_directory }}
|
||||
env:
|
||||
COMPOSER_PROCESS_TIMEOUT: 600
|
220
.github/workflows/REUSABLE_frontend.yml
vendored
Normal file
220
.github/workflows/REUSABLE_frontend.yml
vendored
Normal file
@@ -0,0 +1,220 @@
|
||||
name: Flarum Frontend Jobs
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
enable_bundlewatch:
|
||||
description: "Enable Bundlewatch?"
|
||||
type: boolean
|
||||
default: false
|
||||
required: false
|
||||
enable_prettier:
|
||||
description: "Enable Prettier?"
|
||||
type: boolean
|
||||
default: true
|
||||
required: false
|
||||
enable_typescript:
|
||||
description: "Enable TypeScript?"
|
||||
type: boolean
|
||||
default: true
|
||||
required: false
|
||||
|
||||
backend_directory:
|
||||
description: The directory of the project where backend code is located. This should contain a `composer.json` file, and is generally the root directory of the repo.
|
||||
type: string
|
||||
required: false
|
||||
default: '.'
|
||||
frontend_directory:
|
||||
description: The directory of the project where frontend code is located. This should contain a `package.json` file.
|
||||
type: string
|
||||
required: false
|
||||
default: './js'
|
||||
main_git_branch:
|
||||
description: The main git branch to use for the workflow.
|
||||
type: string
|
||||
required: false
|
||||
default: main
|
||||
node_version:
|
||||
description: The node version to use for the workflow.
|
||||
type: number
|
||||
required: false
|
||||
default: 16
|
||||
|
||||
js_package_manager:
|
||||
description: "Enable TypeScript?"
|
||||
type: string
|
||||
default: yarn
|
||||
required: false
|
||||
cache_dependency_path:
|
||||
description: "The path to the cache dependency file."
|
||||
type: string
|
||||
required: false
|
||||
|
||||
secrets:
|
||||
bundlewatch_github_token:
|
||||
description: The GitHub token to use for Bundlewatch.
|
||||
required: false
|
||||
|
||||
env:
|
||||
COMPOSER_ROOT_VERSION: dev-main
|
||||
ci_script: ${{ inputs.js_package_manager == 'yarn' && 'yarn install --immutable' || 'npm ci' }}
|
||||
cache_dependency_path: ${{ inputs.cache_dependency_path || format(inputs.js_package_manager == 'yarn' && '{0}/yarn.lock' || '{0}/package-lock.json', inputs.frontend_directory) }}
|
||||
|
||||
jobs:
|
||||
bundlewatch:
|
||||
name: Bundlewatch
|
||||
runs-on: ubuntu-latest
|
||||
if: inputs.enable_bundlewatch
|
||||
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: ${{ inputs.node_version }}
|
||||
cache: ${{ inputs.js_package_manager }}
|
||||
cache-dependency-path: ${{ env.cache_dependency_path }}
|
||||
|
||||
- name: Build production assets
|
||||
uses: flarum/action-build@2
|
||||
with:
|
||||
github_token: ${{ secrets.github_token }}
|
||||
build_script: build
|
||||
package_manager: ${{ inputs.js_package_manager }}
|
||||
js_path: ${{ inputs.frontend_directory }}
|
||||
do_not_commit: true
|
||||
|
||||
- name: Check bundle size change
|
||||
run: node_modules/.bin/bundlewatch --config .bundlewatch.config.json
|
||||
working-directory: ${{ inputs.frontend_directory }}
|
||||
env:
|
||||
BUNDLEWATCH_GITHUB_TOKEN: ${{ secrets.bundlewatch_github_token }}
|
||||
CI_COMMIT_SHA: ${{ github.event.pull_request.head.sha }}
|
||||
|
||||
prettier:
|
||||
name: Prettier
|
||||
runs-on: ubuntu-latest
|
||||
if: inputs.enable_prettier
|
||||
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: ${{ inputs.node_version }}
|
||||
cache: ${{ inputs.js_package_manager }}
|
||||
cache-dependency-path: ${{ env.cache_dependency_path }}
|
||||
|
||||
- name: Install JS dependencies
|
||||
run: ${{ env.ci_script }}
|
||||
working-directory: ${{ inputs.frontend_directory }}
|
||||
|
||||
- name: Check JS formatting
|
||||
run: ${{ inputs.js_package_manager }} run format-check
|
||||
working-directory: ${{ inputs.frontend_directory }}
|
||||
|
||||
typecheck:
|
||||
name: Typecheck
|
||||
runs-on: ubuntu-latest
|
||||
if: inputs.enable_typescript
|
||||
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: ${{ inputs.node_version }}
|
||||
cache: ${{ inputs.js_package_manager }}
|
||||
cache-dependency-path: ${{ env.cache_dependency_path }}
|
||||
|
||||
- name: Setup PHP
|
||||
uses: shivammathur/setup-php@v2
|
||||
with:
|
||||
php-version: '8.0'
|
||||
extensions: curl, dom, gd, json, mbstring, openssl, pdo_mysql, tokenizer, zip
|
||||
tools: composer:v2
|
||||
|
||||
# Needed since tsconfig draws typings from vendor folder.
|
||||
- name: Install Composer dependencies
|
||||
run: composer install
|
||||
working-directory: ${{ inputs.backend_directory }}
|
||||
|
||||
- name: Install JS dependencies
|
||||
run: ${{ env.ci_script }}
|
||||
working-directory: ${{ inputs.frontend_directory }}
|
||||
|
||||
- name: Typecheck
|
||||
run: ${{ inputs.js_package_manager }} run check-typings
|
||||
working-directory: ${{ inputs.frontend_directory }}
|
||||
|
||||
type-coverage:
|
||||
name: Type Coverage
|
||||
runs-on: ubuntu-latest
|
||||
if: inputs.enable_typescript
|
||||
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: ${{ inputs.node_version }}
|
||||
cache: ${{ inputs.js_package_manager }}
|
||||
cache-dependency-path: ${{ env.cache_dependency_path }}
|
||||
|
||||
- name: Install JS dependencies
|
||||
run: ${{ env.ci_script }}
|
||||
working-directory: ${{ inputs.frontend_directory }}
|
||||
|
||||
- name: Check type coverage
|
||||
run: ${{ inputs.js_package_manager }} run check-typings-coverage
|
||||
working-directory: ${{ inputs.frontend_directory }}
|
||||
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ubuntu-latest
|
||||
if: "always() && !contains(needs.*.result, 'failed') && !contains(needs.*.result, 'cancelled')"
|
||||
needs: [bundlewatch, prettier, typecheck, type-coverage]
|
||||
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: ${{ inputs.node_version }}
|
||||
cache: ${{ inputs.js_package_manager }}
|
||||
cache-dependency-path: ${{ env.cache_dependency_path }}
|
||||
|
||||
# Our action will install npm/yarn, cd into `${{ inputs.frontend_directory }}`, build dist JS and typings,
|
||||
# then commit and upload any changes iff we are on the main branch and have just pushed.
|
||||
- name: Build production JS
|
||||
if: inputs.enable_typescript
|
||||
uses: flarum/action-build@2
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
build_script: build
|
||||
package_manager: ${{ inputs.js_package_manager }}
|
||||
typings_script: build-typings
|
||||
js_path: ${{ inputs.frontend_directory }}
|
||||
do_not_commit: ${{ github.ref != format('refs/heads/{0}', inputs.main_git_branch) || github.event_name != 'push' }}
|
||||
|
||||
# Our action will install npm/yarn, cd into `${{ inputs.frontend_directory }}`, build dist JS and typings,
|
||||
# then commit and upload any changes iff we are on the main branch and have just pushed.
|
||||
- name: Build production JS
|
||||
if: "! inputs.enable_typescript"
|
||||
uses: flarum/action-build@2
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
build_script: build
|
||||
package_manager: ${{ inputs.js_package_manager }}
|
||||
js_path: ${{ inputs.frontend_directory }}
|
||||
do_not_commit: ${{ github.ref != format('refs/heads/{0}', inputs.main_git_branch) || github.event_name != 'push' }}
|
6
.github/workflows/flarum-akismet-backend.yml
vendored
6
.github/workflows/flarum-akismet-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Akismet PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: true
|
||||
|
||||
|
@@ -2,13 +2,9 @@ name: Akismet JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/akismet/js
|
||||
backend_directory: ./extensions/akismet
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
@@ -2,13 +2,9 @@ name: Approval PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
|
||||
|
@@ -2,13 +2,9 @@ name: Approval JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/approval/js
|
||||
backend_directory: ./extensions/approval
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
6
.github/workflows/flarum-core-backend.yml
vendored
6
.github/workflows/flarum-core-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Core PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: true
|
||||
|
||||
|
7
.github/workflows/flarum-core-frontend.yml
vendored
7
.github/workflows/flarum-core-frontend.yml
vendored
@@ -2,13 +2,9 @@ name: Core JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: true
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./framework/core/js
|
||||
backend_directory: ./framework/core
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
6
.github/workflows/flarum-embed-backend.yml
vendored
6
.github/workflows/flarum-embed-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Embed PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
|
||||
|
7
.github/workflows/flarum-embed-frontend.yml
vendored
7
.github/workflows/flarum-embed-frontend.yml
vendored
@@ -2,13 +2,9 @@ name: Embed JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/embed/js
|
||||
backend_directory: ./extensions/embed
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
6
.github/workflows/flarum-emoji-backend.yml
vendored
6
.github/workflows/flarum-emoji-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Emoji PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
|
||||
|
7
.github/workflows/flarum-emoji-frontend.yml
vendored
7
.github/workflows/flarum-emoji-frontend.yml
vendored
@@ -2,13 +2,9 @@ name: Emoji JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/emoji/js
|
||||
backend_directory: ./extensions/emoji
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
6
.github/workflows/flarum-flags-backend.yml
vendored
6
.github/workflows/flarum-flags-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Flags PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: true
|
||||
|
||||
|
7
.github/workflows/flarum-flags-frontend.yml
vendored
7
.github/workflows/flarum-flags-frontend.yml
vendored
@@ -2,13 +2,9 @@ name: Flags JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/flags/js
|
||||
backend_directory: ./extensions/flags
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
6
.github/workflows/flarum-likes-backend.yml
vendored
6
.github/workflows/flarum-likes-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Likes PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
|
||||
|
7
.github/workflows/flarum-likes-frontend.yml
vendored
7
.github/workflows/flarum-likes-frontend.yml
vendored
@@ -2,13 +2,9 @@ name: Likes JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/likes/js
|
||||
backend_directory: ./extensions/likes
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
6
.github/workflows/flarum-lock-backend.yml
vendored
6
.github/workflows/flarum-lock-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Lock PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
|
||||
|
7
.github/workflows/flarum-lock-frontend.yml
vendored
7
.github/workflows/flarum-lock-frontend.yml
vendored
@@ -2,13 +2,9 @@ name: Lock JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/lock/js
|
||||
backend_directory: ./extensions/lock
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
@@ -2,13 +2,9 @@ name: Markdown PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
|
||||
|
@@ -2,13 +2,9 @@ name: Markdown JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/markdown/js
|
||||
backend_directory: ./extensions/markdown
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
@@ -2,13 +2,9 @@ name: Mentions PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: true
|
||||
|
||||
|
@@ -2,13 +2,9 @@ name: Mentions JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/mentions/js
|
||||
backend_directory: ./extensions/mentions
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
@@ -2,13 +2,9 @@ name: Nicknames PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: true
|
||||
|
||||
|
@@ -2,13 +2,9 @@ name: Nicknames JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/nicknames/js
|
||||
backend_directory: ./extensions/nicknames
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
11
.github/workflows/flarum-package-manager-backend.yml
vendored
Normal file
11
.github/workflows/flarum-package-manager-backend.yml
vendored
Normal file
@@ -0,0 +1,11 @@
|
||||
name: Package Manager PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: true
|
||||
|
||||
backend_directory: ./extensions/package-manager
|
@@ -2,13 +2,9 @@ name: Package Manager JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/package-manager/js
|
||||
backend_directory: ./extensions/package-manager
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
6
.github/workflows/flarum-pusher-backend.yml
vendored
6
.github/workflows/flarum-pusher-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Pusher PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
|
||||
|
7
.github/workflows/flarum-pusher-frontend.yml
vendored
7
.github/workflows/flarum-pusher-frontend.yml
vendored
@@ -2,13 +2,9 @@ name: Pusher JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/pusher/js
|
||||
backend_directory: ./extensions/pusher
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
@@ -2,13 +2,9 @@ name: Statistics PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: true
|
||||
|
||||
|
@@ -2,13 +2,9 @@ name: Statistics JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/statistics/js
|
||||
backend_directory: ./extensions/statistics
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
8
.github/workflows/flarum-sticky-backend.yml
vendored
8
.github/workflows/flarum-sticky-backend.yml
vendored
@@ -2,14 +2,10 @@ name: Sticky PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
enable_backend_testing: true
|
||||
|
||||
backend_directory: ./extensions/sticky
|
||||
|
7
.github/workflows/flarum-sticky-frontend.yml
vendored
7
.github/workflows/flarum-sticky-frontend.yml
vendored
@@ -2,13 +2,9 @@ name: Sticky JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/sticky/js
|
||||
backend_directory: ./extensions/sticky
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
@@ -2,13 +2,9 @@ name: Subscriptions PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
|
||||
|
@@ -2,13 +2,9 @@ name: Subscriptions JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/subscriptions/js
|
||||
backend_directory: ./extensions/subscriptions
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
6
.github/workflows/flarum-suspend-backend.yml
vendored
6
.github/workflows/flarum-suspend-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Suspend PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: false
|
||||
|
||||
|
@@ -2,13 +2,9 @@ name: Suspend JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: true
|
||||
@@ -17,6 +13,7 @@ jobs:
|
||||
frontend_directory: ./extensions/suspend/js
|
||||
backend_directory: ./extensions/suspend
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
|
||||
secrets:
|
||||
|
6
.github/workflows/flarum-tags-backend.yml
vendored
6
.github/workflows/flarum-tags-backend.yml
vendored
@@ -2,13 +2,9 @@ name: Tags PHP
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_backend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_backend.yml
|
||||
with:
|
||||
enable_backend_testing: true
|
||||
|
||||
|
9
.github/workflows/flarum-tags-frontend.yml
vendored
9
.github/workflows/flarum-tags-frontend.yml
vendored
@@ -2,21 +2,18 @@ name: Tags JS
|
||||
|
||||
on: [workflow_dispatch, push, pull_request]
|
||||
|
||||
# The reusable workflow definitions will be moved to the `flarum/framework` repo soon.
|
||||
# This will break your current script.
|
||||
# When this happens, run `flarum-cli audit infra --fix` to update your infrastructure.
|
||||
|
||||
jobs:
|
||||
run:
|
||||
uses: flarum/.github/.github/workflows/REUSABLE_frontend.yml@main
|
||||
uses: ./.github/workflows/REUSABLE_frontend.yml
|
||||
with:
|
||||
enable_bundlewatch: false
|
||||
enable_prettier: false
|
||||
enable_prettier: true
|
||||
enable_typescript: true
|
||||
|
||||
frontend_directory: ./extensions/tags/js
|
||||
backend_directory: ./extensions/tags
|
||||
js_package_manager: yarn
|
||||
cache_dependency_path: ./yarn.lock
|
||||
main_git_branch: main
|
||||
secrets:
|
||||
bundlewatch_github_token: ${{ secrets.BUNDLEWATCH_GITHUB_TOKEN }}
|
||||
|
4
.gitignore
vendored
4
.gitignore
vendored
@@ -1 +1,3 @@
|
||||
node_modules
|
||||
node_modules
|
||||
vendor
|
||||
composer.lock
|
||||
|
@@ -1,6 +1,57 @@
|
||||
# Changelog
|
||||
|
||||
## [1.2.0](https://github.com/flarum/flarum-core/compare/v1.1.1...v1.2.0)
|
||||
## [1.3.1](https://github.com/flarum/framework/compare/v1.3.0...v1.3.1)
|
||||
|
||||
### Changed
|
||||
- UserCard now has ItemList for easier extending (https://github.com/flarum/framework/pull/3436)
|
||||
|
||||
### Fixed
|
||||
- Button to go directly to all results page is hidden while API request for search hasn't completed (https://github.com/flarum/framework/pull/3431)
|
||||
- Setting extender does not register modifications beyond first fluent call (https://github.com/flarum/framework/pull/3439)
|
||||
- Link to font awesome icons list no longer works (https://github.com/flarum/framework/commit/df1bdd2ad84e992414c0e1e7be576558b4b0fe29)
|
||||
- Mentions: mentions with deleted authors not showing (https://github.com/flarum/framework/pull/3432)
|
||||
- Nicknames: regex validation isn't functional (https://github.com/flarum/framework/pull/3430)
|
||||
- Subscriptions: reply notifications not working (https://github.com/flarum/framework/pull/3445)
|
||||
- Suspend: not providing suspension reason breaks mail (https://github.com/flarum/framework/pull/3433)
|
||||
|
||||
<!-- One-time commit-based diff due to monorepo rework. Diffing against the 1.2.1 tag doesn't work due to unrelated histories. -->
|
||||
## [1.3.0](https://github.com/flarum/framework/compare/33d939cb012716ed6309ea02236737ad4f25a75b...v1.3.0)
|
||||
|
||||
From v1.2.1 on all bundled Flarum extensions and `flarum/core` are merged into one monorepo. As a result of this, the full code diff linked above
|
||||
looks rather complex and messy compared to the full list of changes made for this release.
|
||||
|
||||
### Added
|
||||
- [A11Y] Added role feed to DiscussionList (https://github.com/flarum/framework/pull/3359)
|
||||
- Support multiple confirmation dialogs when closing a tab/window (https://github.com/flarum/framework/pull/3372)
|
||||
- Markdown: markdown toolbar support for admin frontend (https://github.com/flarum/framework/commit/16d5cc11e3aee5c94aeed877987cdb199a2a0d2c)
|
||||
|
||||
### Changed
|
||||
- Post number calculation is now executed inside the database layer, preventing integrity constraints (https://github.com/flarum/framework/pull/3358)
|
||||
- Errors from within extensions no longer make Flarum crash but trigger a visible warning (https://github.com/flarum/framework/pull/3349)
|
||||
- Sorting options for discussion index is now extensible (https://github.com/flarum/framework/pull/3377)
|
||||
- Event listeners from the framework now are added before those of extensions (https://github.com/flarum/framework/pull/3373)
|
||||
|
||||
### Fixed
|
||||
- Typings and missing typescript components (https://github.com/flarum/framework/pull/3348)
|
||||
- `Post--by-start-user` CSS class is not added to post html (https://github.com/flarum/framework/pull/3356)
|
||||
- Timestamps for notifications are incorrect on servers that have a timezone different than UTC (https://github.com/flarum/framework/pull/3379)
|
||||
- Extensions with dependencies that are enabled do not cause dependencies to be enforced (https://github.com/flarum/framework/pull/3352)
|
||||
- Search using non-words doesn't work (https://github.com/flarum/framework/pull/3385)
|
||||
- Slugs are not working for other languages than English (https://github.com/flarum/framework/pull/3387)
|
||||
- Deprecations are triggered on PHP 8.1 (https://github.com/flarum/framework/pull/3384)
|
||||
- Post permalink for subdirectory installs have duplicate paths segments (https://github.com/flarum/framework/pull/3354)
|
||||
- Composer discussion title is not always clearly visible (https://github.com/flarum/framework/pull/3413)
|
||||
- Mentions: extensions re-using mentions can cause errors due to missing context (https://github.com/flarum/framework/pull/3382)
|
||||
- Tags: tag selection modal errors on new discussions when pressing down (https://github.com/flarum/framework/issues/3403)
|
||||
- [A11Y] Tags: focus to input and layout of tag selection modal are off (https://github.com/flarum/framework/pull/3412)
|
||||
- Subscriptions: searching inside the following page will search in all discussions (https://github.com/flarum/framework/pull/3376)
|
||||
|
||||
## [1.2.1](https://github.com/flarum/framework/compare/v1.2.0...v1.2.1)
|
||||
|
||||
### Fixed
|
||||
- Don't escape single quotes in discussion title meta tags (60600f4d2b8f0c5dac94c329041427a0a08fad42)
|
||||
|
||||
## [1.2.0](https://github.com/flarum/framework/compare/v1.1.1...v1.2.0)
|
||||
|
||||
### Added
|
||||
- View `README` documentation in extension pages (https://github.com/flarum/framework/pull/3094).
|
||||
@@ -106,12 +157,12 @@
|
||||
### Deprecated
|
||||
- Unused `evented` utility (https://github.com/flarum/framework/pull/3125).
|
||||
|
||||
## [1.1.1](https://github.com/flarum/flarum-core/compare/v1.1.0...v1.1.1)
|
||||
## [1.1.1](https://github.com/flarum/framework/compare/v1.1.0...v1.1.1)
|
||||
|
||||
### Fixed
|
||||
- Performance issue with very large communities.
|
||||
|
||||
## [1.1.0](https://github.com/flarum/flarum-core/compare/v1.0.4...v1.1.0)
|
||||
## [1.1.0](https://github.com/flarum/framework/compare/v1.0.4...v1.1.0)
|
||||
|
||||
### Added
|
||||
- Info command now displays MySQL version, queue driver, mail driver (https://github.com/flarum/framework/pull/2991)
|
||||
@@ -165,13 +216,13 @@
|
||||
###### Issue Reporters
|
||||
@uamv, @dannyuk1982, @BurnNoticeSpy, @haarp, @peopleinside, @matteocontrini
|
||||
|
||||
## [1.0.4](https://github.com/flarum/flarum-core/compare/v1.0.3...v1.0.4)
|
||||
## [1.0.4](https://github.com/flarum/framework/compare/v1.0.3...v1.0.4)
|
||||
|
||||
### Fixed
|
||||
|
||||
- Upgrade to v1.0 resets the "view" permission on all tags (https://github.com/flarum/framework/pull/2941)
|
||||
|
||||
## [1.0.3](https://github.com/flarum/flarum-core/compare/v1.0.2...v1.0.3)
|
||||
## [1.0.3](https://github.com/flarum/framework/compare/v1.0.2...v1.0.3)
|
||||
|
||||
### Changed
|
||||
|
||||
@@ -185,17 +236,17 @@
|
||||
- Avatar in notifications list are incorrectly aligned (https://github.com/flarum/framework/pull/2906)
|
||||
- FilesystemManager is not compatible with upstream Laravel implementation (https://github.com/flarum/framework/pull/2936)
|
||||
|
||||
## [1.0.2](https://github.com/flarum/flarum-core/compare/v1.0.1...v1.0.2)
|
||||
## [1.0.2](https://github.com/flarum/framework/compare/v1.0.1...v1.0.2)
|
||||
|
||||
### Fixed
|
||||
- Critical XSS vulnerability
|
||||
|
||||
## [1.0.1](https://github.com/flarum/flarum-core/compare/v1.0.0...v1.0.1)
|
||||
## [1.0.1](https://github.com/flarum/framework/compare/v1.0.0...v1.0.1)
|
||||
|
||||
### Fixed
|
||||
- Installation fails on environments without proc_* functions enabled or mysql client binary (https://github.com/flarum/framework/issues/2890)
|
||||
|
||||
## [1.0.0](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.16...v1.0.0)
|
||||
## [1.0.0](https://github.com/flarum/framework/compare/v0.1.0-beta.16...v1.0.0)
|
||||
|
||||
### Added
|
||||
- Task scheduling
|
||||
@@ -261,7 +312,7 @@
|
||||
- The session is no longer available from the User class (https://github.com/flarum/framework/pull/2790)
|
||||
- The `mail` key is removed from the laravel related config (https://github.com/flarum/framework/pull/2796)
|
||||
|
||||
## [0.1.0-beta.16](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.15...v0.1.0-beta.16)
|
||||
## [0.1.0-beta.16](https://github.com/flarum/framework/compare/v0.1.0-beta.15...v0.1.0-beta.16)
|
||||
|
||||
### Added
|
||||
- Allow event subscribers (https://github.com/flarum/framework/pull/2535)
|
||||
@@ -352,7 +403,7 @@
|
||||
- `UserFilter` ([91e8b56](https://github.com/flarum/framework/commit/91e8b569618957c86757ef89bac666e9102db5ae))
|
||||
|
||||
|
||||
## [0.1.0-beta.15](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.14.1...v0.1.0-beta.15)
|
||||
## [0.1.0-beta.15](https://github.com/flarum/framework/compare/v0.1.0-beta.14.1...v0.1.0-beta.15)
|
||||
|
||||
### Added
|
||||
|
||||
@@ -410,7 +461,7 @@
|
||||
|
||||
- `CheckingForFlooding` (https://github.com/flarum/framework/commit/8e25bcb68f86cc992c46dfa70368419fe9f936ac).
|
||||
|
||||
## [0.1.0-beta.14.1](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.14...v0.1.0-beta.14.1)
|
||||
## [0.1.0-beta.14.1](https://github.com/flarum/framework/compare/v0.1.0-beta.14...v0.1.0-beta.14.1)
|
||||
|
||||
### Fixed
|
||||
|
||||
@@ -420,7 +471,7 @@
|
||||
- Sub path installations have no page title.
|
||||
- Losing focus of Composer area when coming from fullscreen.
|
||||
|
||||
## [0.1.0-beta.14](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.13...v0.1.0-beta.14)
|
||||
## [0.1.0-beta.14](https://github.com/flarum/framework/compare/v0.1.0-beta.13...v0.1.0-beta.14)
|
||||
|
||||
### Added
|
||||
|
||||
@@ -517,7 +568,7 @@
|
||||
- Global path helpers, `Flarum\Foundation\Application` path methods (https://github.com/flarum/framework/pull/2155)
|
||||
- `Flarum\User\AssertPermissionTrait` (https://github.com/flarum/framework/pull/2044)
|
||||
|
||||
## [0.1.0-beta.13](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.12...v0.1.0-beta.13)
|
||||
## [0.1.0-beta.13](https://github.com/flarum/framework/compare/v0.1.0-beta.12...v0.1.0-beta.13)
|
||||
|
||||
### Added
|
||||
- Console extender (#2057)
|
||||
@@ -570,7 +621,7 @@
|
||||
- `Flarum\Event\ConfigureForumRoutes` event class
|
||||
- `Flarum\Event\ConfigureLocales` event class
|
||||
|
||||
## [0.1.0-beta.12](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.11.1...v0.1.0-beta.12)
|
||||
## [0.1.0-beta.12](https://github.com/flarum/framework/compare/v0.1.0-beta.11.1...v0.1.0-beta.12)
|
||||
|
||||
### Added
|
||||
- Full support for PHP 7.4 (#1980)
|
||||
@@ -595,12 +646,12 @@
|
||||
- Translation fallback was ignored for client-rendered pages (#1774, #1961)
|
||||
- The success alert when posting replies was invisible (#1976)
|
||||
|
||||
## [0.1.0-beta.11.1](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.11...v0.1.0-beta.11.1)
|
||||
## [0.1.0-beta.11.1](https://github.com/flarum/framework/compare/v0.1.0-beta.11...v0.1.0-beta.11.1)
|
||||
|
||||
### Fixed
|
||||
- Saving custom css in admin failed (#1946)
|
||||
|
||||
## [0.1.0-beta.11](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.10...v0.1.0-beta.11)
|
||||
## [0.1.0-beta.11](https://github.com/flarum/framework/compare/v0.1.0-beta.10...v0.1.0-beta.11)
|
||||
|
||||
### Added
|
||||
- Comments have an additional class `Post--by-actor` when posted by the user (#1927)
|
||||
@@ -627,7 +678,7 @@
|
||||
- Debug button no longer visible (#1687)
|
||||
- Modals on smaller screens use the whole width of the page
|
||||
|
||||
## [0.1.0-beta.10](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.9...v0.1.0-beta.10)
|
||||
## [0.1.0-beta.10](https://github.com/flarum/framework/compare/v0.1.0-beta.9...v0.1.0-beta.10)
|
||||
|
||||
### Added
|
||||
- Initial queue support: Infrastructure for offloading long-running tasks (e.g. email sending) to background workers (#1773)
|
||||
@@ -653,7 +704,7 @@
|
||||
- API requests authenticated using access tokens needed to provide a CSRF token (#1828)
|
||||
- Accessibility: Screenreaders did not read the "Back to discussion list" link (#1835)
|
||||
|
||||
## [0.1.0-beta.9](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.8.2...v0.1.0-beta.9)
|
||||
## [0.1.0-beta.9](https://github.com/flarum/framework/compare/v0.1.0-beta.8.2...v0.1.0-beta.9)
|
||||
|
||||
### Added
|
||||
- New `hasPermission()` helper method for `Group` objects ([9684fbc](https://github.com/flarum/framework/commit/9684fbc4da07d32aa322d9228302a23418412cb9))
|
||||
@@ -700,7 +751,7 @@
|
||||
- `php flarum install --defaults` - this was meant to be used in our old development VM ([44c9109](https://github.com/flarum/framework/commit/44c91099cd77138bb5fc29f14fb1e81a9781272d))
|
||||
- Obsolete `id` attributes in JSON-API responses ([ecc3b5e](https://github.com/flarum/framework/commit/ecc3b5e2271f8d9b38d52cd54476d86995dbe32e) and [7a44086](https://github.com/flarum/framework/commit/7a44086bf3a0e3ba907dceb13d07ac695eca05ea))
|
||||
|
||||
## [0.1.0-beta.8.1](https://github.com/flarum/flarum-core/compare/v0.1.0-beta.8...v0.1.0-beta.8.1)
|
||||
## [0.1.0-beta.8.1](https://github.com/flarum/framework/compare/v0.1.0-beta.8...v0.1.0-beta.8.1)
|
||||
|
||||
### Fixed
|
||||
- Fix live output in `migrate:reset` command ([f591585](https://github.com/flarum/framework/commit/f591585d02f8c4ff0211c5bf4413dd6baa724c05))
|
@@ -1,11 +1,11 @@
|
||||
<p align="center"><img src="https://flarum.org/assets/img/logo.png"></p>
|
||||
|
||||
<p align="center">
|
||||
<a href="https://github.com/flarum/framework/actions?query=workflow%3ATests"><img src="https://github.com/flarum/framework/workflows/Tests/badge.svg" alt="PHP Tests"></a>
|
||||
<a href="https://github.com/flarum/core/actions?query=workflow%3ATests"><img src="https://github.com/flarum/core/workflows/Tests/badge.svg" alt="PHP Tests"></a>
|
||||
<a href="https://packagist.org/packages/flarum/core"><img src="https://img.shields.io/packagist/dt/flarum/core" alt="Total Downloads"></a>
|
||||
<a href="https://packagist.org/packages/flarum/core"><img src="https://img.shields.io/github/v/release/flarum/framework?sort=semver" alt="Latest Version"></a>
|
||||
<a href="https://packagist.org/packages/flarum/core"><img src="https://img.shields.io/github/v/release/flarum/core?sort=semver" alt="Latest Version"></a>
|
||||
<a href="https://packagist.org/packages/flarum/core"><img src="https://img.shields.io/packagist/l/flarum/core" alt="License"></a>
|
||||
<a href="https://huntr.dev/bounties/disclose/?target=https://github.com/flarum/framework"><img src="https://cdn.huntr.dev/huntr_security_badge_mono.svg" alt="huntr"></a>
|
||||
<a href="https://huntr.dev/bounties/disclose/?target=https://github.com/flarum/core"><img src="https://cdn.huntr.dev/huntr_security_badge_mono.svg" alt="huntr"></a>
|
||||
<a href="https://github.styleci.io/repos/28257573"><img src="https://github.styleci.io/repos/28257573/shield?style=flat" alt="StyleCI"></a>
|
||||
</p>
|
||||
|
||||
@@ -31,7 +31,7 @@ Thank you for considering contributing to Flarum! Please read the **[Contributin
|
||||
|
||||
## Security Vulnerabilities
|
||||
|
||||
If you discover a security vulnerability within Flarum, please send an e-mail to [security@flarum.org](mailto:security@flarum.org). All security vulnerabilities will be promptly addressed. More details can be found in our [security policy](https://github.com/flarum/framework/security/policy).
|
||||
If you discover a security vulnerability within Flarum, please send an e-mail to [security@flarum.org](mailto:security@flarum.org). All security vulnerabilities will be promptly addressed. More details can be found in our [security policy](https://github.com/flarum/core/security/policy).
|
||||
|
||||
## License
|
||||
|
||||
|
182
composer.json
Normal file
182
composer.json
Normal file
@@ -0,0 +1,182 @@
|
||||
{
|
||||
"name": "flarum/framework",
|
||||
"description": "Delightfully simple forum software.",
|
||||
"keywords": [
|
||||
"forum",
|
||||
"discussion"
|
||||
],
|
||||
"homepage": "https://flarum.org/",
|
||||
"license": "MIT",
|
||||
"authors": [
|
||||
{
|
||||
"name": "Flarum",
|
||||
"email": "info@flarum.org",
|
||||
"homepage": "https://flarum.org/team"
|
||||
}
|
||||
],
|
||||
"funding": [
|
||||
{
|
||||
"type": "opencollective",
|
||||
"url": "https://opencollective.com/flarum"
|
||||
},
|
||||
{
|
||||
"type": "github",
|
||||
"url": "https://github.com/sponsors/flarum"
|
||||
},
|
||||
{
|
||||
"type": "other",
|
||||
"url": "https://flarum.org/donate"
|
||||
}
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/core",
|
||||
"docs": "https://docs.flarum.org",
|
||||
"forum": "https://discuss.flarum.org",
|
||||
"chat": "https://flarum.org/chat"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Flarum\\": "framework/core/src",
|
||||
"Flarum\\Akismet\\": "extensions/akismet/src",
|
||||
"Flarum\\Approval\\": "extensions/approval/src",
|
||||
"Flarum\\Flags\\": "extensions/flags/src",
|
||||
"Flarum\\Likes\\": "extensions/likes/src",
|
||||
"Flarum\\Lock\\": "extensions/lock/src",
|
||||
"Flarum\\Mentions\\": "extensions/mentions/src",
|
||||
"Flarum\\Nicknames\\": "extensions/nicknames/src",
|
||||
"Flarum\\PackageManager\\": "extensions/package-manager/src",
|
||||
"Flarum\\Pusher\\": "extensions/pusher/src",
|
||||
"Flarum\\Statistics\\": "extensions/statistics/src",
|
||||
"Flarum\\Sticky\\": "extensions/sticky/src",
|
||||
"Flarum\\Subscriptions\\": "extensions/subscriptions/src",
|
||||
"Flarum\\Suspend\\": "extensions/suspend/src",
|
||||
"Flarum\\Tags\\": "extensions/tags/src",
|
||||
"Flarum\\PHPStan\\": "php-packages/phpstan/src",
|
||||
"Flarum\\Testing\\": "php-packages/testing/src"
|
||||
},
|
||||
"files": [
|
||||
"framework/core/src/helpers.php"
|
||||
]
|
||||
},
|
||||
"replace": {
|
||||
"flarum/core": "self.version",
|
||||
"flarum/akismet": "self.version",
|
||||
"flarum/approval": "self.version",
|
||||
"flarum/bbcode": "self.version",
|
||||
"flarum/embed": "self.version",
|
||||
"flarum/emoji": "self.version",
|
||||
"flarum/flags": "self.version",
|
||||
"flarum/lang-english": "self.version",
|
||||
"flarum/likes": "self.version",
|
||||
"flarum/lock": "self.version",
|
||||
"flarum/markdown": "self.version",
|
||||
"flarum/mentions": "self.version",
|
||||
"flarum/nicknames": "self.version",
|
||||
"flarum/package-manager": "self.version",
|
||||
"flarum/pusher": "self.version",
|
||||
"flarum/statistics": "self.version",
|
||||
"flarum/sticky": "self.version",
|
||||
"flarum/subscriptions": "self.version",
|
||||
"flarum/suspend": "self.version",
|
||||
"flarum/tags": "self.version",
|
||||
"flarum/phpstan": "self.version",
|
||||
"flarum/testing": "self.version"
|
||||
},
|
||||
"require": {
|
||||
"ext-json": "*",
|
||||
"php": ">=7.3",
|
||||
"components/font-awesome": "^5.14.0",
|
||||
"composer/composer": "^2.0",
|
||||
"dflydev/fig-cookies": "^3.0.0",
|
||||
"doctrine/dbal": "^2.7",
|
||||
"dragonmantank/cron-expression": "^3.1.0",
|
||||
"franzl/whoops-middleware": "^2.0.0",
|
||||
"guzzlehttp/guzzle": "^7.4",
|
||||
"illuminate/bus": "^8.0",
|
||||
"illuminate/cache": "^8.0",
|
||||
"illuminate/config": "^8.0",
|
||||
"illuminate/console": "^8.0",
|
||||
"illuminate/container": "^8.0",
|
||||
"illuminate/contracts": "^8.0",
|
||||
"illuminate/database": "^8.0",
|
||||
"illuminate/events": "^8.0",
|
||||
"illuminate/filesystem": "^8.0",
|
||||
"illuminate/hashing": "^8.0",
|
||||
"illuminate/mail": "^8.0",
|
||||
"illuminate/queue": "^8.0",
|
||||
"illuminate/session": "^8.0",
|
||||
"illuminate/support": "^8.0",
|
||||
"illuminate/validation": "^8.0",
|
||||
"illuminate/view": "^8.0",
|
||||
"intervention/image": "2.5.* || ^2.6.1",
|
||||
"laminas/laminas-diactoros": "^2.4.1",
|
||||
"laminas/laminas-httphandlerrunner": "^1.2.0",
|
||||
"laminas/laminas-stratigility": "^3.2.2",
|
||||
"league/flysystem": "^1.0.11",
|
||||
"matthiasmullie/minify": "^1.3",
|
||||
"middlewares/base-path": "^2.0.1",
|
||||
"middlewares/base-path-router": "^2.0.1",
|
||||
"middlewares/request-handler": "^2.0.1",
|
||||
"monolog/monolog": "^1.16.0",
|
||||
"nesbot/carbon": "^2.0",
|
||||
"nikic/fast-route": "^0.6",
|
||||
"psr/http-message": "^1.0",
|
||||
"psr/http-server-handler": "^1.0",
|
||||
"psr/http-server-middleware": "^1.0",
|
||||
"pusher/pusher-php-server": "^2.2",
|
||||
"s9e/text-formatter": "^2.3.6",
|
||||
"sycho/json-api": "^0.5.0",
|
||||
"sycho/sourcemap": "^2.0.0",
|
||||
"symfony/config": "^5.2.2",
|
||||
"symfony/console": "^5.2.2",
|
||||
"symfony/event-dispatcher": "^5.2.2",
|
||||
"symfony/mime": "^5.2.0",
|
||||
"symfony/polyfill-intl-messageformatter": "^1.22.0",
|
||||
"symfony/translation": "^5.1.5",
|
||||
"symfony/yaml": "^5.2.2",
|
||||
"wikimedia/less.php": "^3.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"mockery/mockery": "^1.4",
|
||||
"phpunit/phpunit": "^9.0",
|
||||
"phpstan/phpstan-php-parser": "^1.0",
|
||||
"phpstan/phpstan": "^1.2"
|
||||
},
|
||||
"config": {
|
||||
"sort-packages": true
|
||||
},
|
||||
"minimum-stability": "dev",
|
||||
"prefer-stable": true,
|
||||
"extra": {
|
||||
"flarum-subextensions": [
|
||||
"extensions/akismet",
|
||||
"extensions/approval",
|
||||
"extensions/bbcode",
|
||||
"extensions/embed",
|
||||
"extensions/emoji",
|
||||
"extensions/flags",
|
||||
"extensions/lang-english",
|
||||
"extensions/likes",
|
||||
"extensions/lock",
|
||||
"extensions/markdown",
|
||||
"extensions/mentions",
|
||||
"extensions/nicknames",
|
||||
"extensions/package-manager",
|
||||
"extensions/pusher",
|
||||
"extensions/statistics",
|
||||
"extensions/sticky",
|
||||
"extensions/subscriptions",
|
||||
"extensions/suspend",
|
||||
"extensions/tags"
|
||||
],
|
||||
"branch-alias": {
|
||||
"dev-main": "1.x-dev"
|
||||
},
|
||||
"phpstan": {
|
||||
"includes": [
|
||||
"extension.neon"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/akismet",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2",
|
||||
"flarum/core": "^1.3",
|
||||
"flarum/approval": "^1.2",
|
||||
"guzzlehttp/guzzle": "^7.4"
|
||||
},
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/approval",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2",
|
||||
"flarum/core": "^1.3",
|
||||
"flarum/flags": "^1.2"
|
||||
},
|
||||
"autoload": {
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/bbcode",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
|
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/embed",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/emoji",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
|
2
extensions/emoji/js/dist/forum.js
generated
vendored
2
extensions/emoji/js/dist/forum.js
generated
vendored
File diff suppressed because one or more lines are too long
2
extensions/emoji/js/dist/forum.js.map
generated
vendored
2
extensions/emoji/js/dist/forum.js.map
generated
vendored
File diff suppressed because one or more lines are too long
8862
extensions/emoji/js/package-lock.json
generated
8862
extensions/emoji/js/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -4,18 +4,18 @@
|
||||
"version": "0.0.0",
|
||||
"prettier": "@flarum/prettier-config",
|
||||
"dependencies": {
|
||||
"simple-emoji-map": "^0.4.1",
|
||||
"twemoji": "^13.1.0"
|
||||
"simple-emoji-map": "^0.5.1",
|
||||
"twemoji": "^14.0.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"prettier": "^2.5.1",
|
||||
"flarum-webpack-config": "^2.0.0",
|
||||
"webpack": "^5.65.0",
|
||||
"webpack-cli": "^4.9.1",
|
||||
"@flarum/prettier-config": "^1.0.0",
|
||||
"flarum-tsconfig": "^1.0.2",
|
||||
"flarum-webpack-config": "^2.0.0",
|
||||
"prettier": "^2.5.1",
|
||||
"typescript": "^4.5.4",
|
||||
"typescript-coverage-report": "^0.6.1"
|
||||
"typescript-coverage-report": "^0.6.1",
|
||||
"webpack": "^5.65.0",
|
||||
"webpack-cli": "^4.9.1"
|
||||
},
|
||||
"scripts": {
|
||||
"dev": "webpack --mode development --watch",
|
||||
|
@@ -39,7 +39,7 @@ export default function renderEmoji() {
|
||||
// wrap it in a node. In our `parseHTML` implementation, we wrap it in a `<body>`
|
||||
// element. This gets stripped below.
|
||||
//
|
||||
// See https://github.com/flarum/framework/issues/2958
|
||||
// See https://github.com/flarum/core/issues/2958
|
||||
const emojifiedDom = twemoji.parse(parseHTML(contentHtml), options);
|
||||
|
||||
// Steal the HTML string inside the emojified DOM `<body>` tag.
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/flags",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -66,8 +66,8 @@ No changes.
|
||||
## [0.1.0-beta.13](https://github.com/flarum/lang-english/compare/v0.1.0-beta.12...v0.1.0-beta.13)
|
||||
|
||||
### Added
|
||||
- Keys for hidden permission groups (#153, flarum/framework#2129, flarum/framework#845)
|
||||
- Keys for post deletion confirmation (#162, flarum/framework#2135)
|
||||
- Keys for hidden permission groups (#153, flarum/core#2129, flarum/core#845)
|
||||
- Keys for post deletion confirmation (#162, flarum/core#2135)
|
||||
- Keys for HTML meta data (#154, flarum/tags#72)
|
||||
|
||||
### Changed
|
||||
|
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
|
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/likes",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/lock",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/markdown",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -33,8 +33,8 @@ No changes.
|
||||
|
||||
### Fixed
|
||||
- Unrecognised user/post mentions (https://github.com/flarum/mentions/pulls/71)
|
||||
- Reduced bugginess in mentions username search (https://github.com/flarum/framework/issues/3095)
|
||||
- Fixed missing space after mentions inserted via post reply (https://github.com/flarum/framework/issues/3096)
|
||||
- Reduced bugginess in mentions username search (https://github.com/flarum/core/issues/3095)
|
||||
- Fixed missing space after mentions inserted via post reply (https://github.com/flarum/core/issues/3096)
|
||||
|
||||
## [1.0.0](https://github.com/flarum/mentions/compare/v0.1.0-beta.16...v1.0.0)
|
||||
|
||||
|
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/mentions",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
|
2
extensions/mentions/js/dist/forum.js
generated
vendored
2
extensions/mentions/js/dist/forum.js
generated
vendored
File diff suppressed because one or more lines are too long
2
extensions/mentions/js/dist/forum.js.map
generated
vendored
2
extensions/mentions/js/dist/forum.js.map
generated
vendored
File diff suppressed because one or more lines are too long
@@ -23,6 +23,6 @@ export default class PostMentionedNotification extends Notification {
|
||||
}
|
||||
|
||||
excerpt() {
|
||||
return truncate(this.attrs.notification.subject().contentPlain(), 200);
|
||||
return truncate(this.attrs.notification.subject().contentPlain() || '', 200);
|
||||
}
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* This file is part of Flarum.
|
||||
*
|
||||
* For detailed copyright and license information, please view the
|
||||
* LICENSE file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Schema\Builder;
|
||||
|
||||
return [
|
||||
'up' => function (Builder $schema) {
|
||||
$schema->table('post_mentions_post', function (Blueprint $table) {
|
||||
$table->timestamp('created_at')->nullable();
|
||||
});
|
||||
|
||||
// do this manually because dbal doesn't recognize timestamp columns
|
||||
$connection = $schema->getConnection();
|
||||
$prefix = $connection->getTablePrefix();
|
||||
$connection->statement("ALTER TABLE `${prefix}post_mentions_post` MODIFY created_at TIMESTAMP NULL DEFAULT CURRENT_TIMESTAMP");
|
||||
},
|
||||
|
||||
'down' => function (Builder $schema) {
|
||||
$schema->table('post_mentions_post', function (Blueprint $table) {
|
||||
$table->dropColumn('created_at');
|
||||
});
|
||||
}
|
||||
];
|
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* This file is part of Flarum.
|
||||
*
|
||||
* For detailed copyright and license information, please view the
|
||||
* LICENSE file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Schema\Builder;
|
||||
|
||||
return [
|
||||
'up' => function (Builder $schema) {
|
||||
$schema->table('post_mentions_user', function (Blueprint $table) {
|
||||
$table->timestamp('created_at')->nullable();
|
||||
});
|
||||
|
||||
// do this manually because dbal doesn't recognize timestamp columns
|
||||
$connection = $schema->getConnection();
|
||||
$prefix = $connection->getTablePrefix();
|
||||
$connection->statement("ALTER TABLE `${prefix}post_mentions_user` MODIFY created_at TIMESTAMP NULL DEFAULT CURRENT_TIMESTAMP");
|
||||
},
|
||||
|
||||
'down' => function (Builder $schema) {
|
||||
$schema->table('post_mentions_user', function (Blueprint $table) {
|
||||
$table->dropColumn('created_at');
|
||||
});
|
||||
}
|
||||
];
|
@@ -125,10 +125,13 @@ class ConfigureMentions
|
||||
{
|
||||
$post = CommentPost::find($tag->getAttribute('id'));
|
||||
|
||||
if ($post && $post->user) {
|
||||
if ($post) {
|
||||
$tag->setAttribute('discussionid', (int) $post->discussion_id);
|
||||
$tag->setAttribute('number', (int) $post->number);
|
||||
$tag->setAttribute('displayname', $post->user->display_name);
|
||||
|
||||
if ($post->user) {
|
||||
$tag->setAttribute('displayname', $post->user->display_name);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@@ -14,7 +14,7 @@ use Flarum\Testing\integration\RetrievesAuthorizedUsers;
|
||||
use Flarum\Testing\integration\TestCase;
|
||||
use Illuminate\Support\Arr;
|
||||
|
||||
class ListTest extends TestCase
|
||||
class ListPostsTest extends TestCase
|
||||
{
|
||||
use RetrievesAuthorizedUsers;
|
||||
|
||||
@@ -85,4 +85,26 @@ class ListTest extends TestCase
|
||||
$ids = Arr::pluck($data, 'id');
|
||||
$this->assertEqualsCanonicalizing(['4'], $ids, 'IDs do not match');
|
||||
}
|
||||
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
public function mentioned_filter_works_with_sort()
|
||||
{
|
||||
$response = $this->send(
|
||||
$this->request('GET', '/api/posts')
|
||||
->withQueryParams([
|
||||
'filter' => ['mentioned' => 1],
|
||||
'sort' => '-createdAt'
|
||||
])
|
||||
);
|
||||
|
||||
$data = json_decode($response->getBody()->getContents(), true)['data'];
|
||||
|
||||
$this->assertEquals(200, $response->getStatusCode());
|
||||
|
||||
// Order-independent comparison
|
||||
$ids = Arr::pluck($data, 'id');
|
||||
$this->assertEqualsCanonicalizing(['2', '3'], $ids, 'IDs do not match');
|
||||
}
|
||||
}
|
||||
|
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/nicknames",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
|
2
extensions/nicknames/js/dist/forum.js.map
generated
vendored
2
extensions/nicknames/js/dist/forum.js.map
generated
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
@@ -40,7 +40,7 @@ class AddNicknameValidation
|
||||
function ($attribute, $value, $fail) {
|
||||
$regex = $this->settings->get('flarum-nicknames.regex');
|
||||
if ($regex && ! preg_match_all("/$regex/", $value)) {
|
||||
$this->translator->trans('flarum-nicknames.api.invalid_nickname_message');
|
||||
$fail($this->translator->trans('flarum-nicknames.api.invalid_nickname_message'));
|
||||
}
|
||||
},
|
||||
'min:'.$this->settings->get('flarum-nicknames.min'),
|
||||
|
@@ -74,4 +74,48 @@ class RegisterTest extends TestCase
|
||||
|
||||
$this->assertEquals(403, $response->getStatusCode());
|
||||
}
|
||||
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
public function cant_register_with_nickname_if_invalid_regex()
|
||||
{
|
||||
$this->setting('flarum-nicknames.set_on_registration', true);
|
||||
$this->setting('flarum-nicknames.regex', '^[A-z]+$');
|
||||
|
||||
$response = $this->send(
|
||||
$this->request('POST', '/register', [
|
||||
'json' => [
|
||||
'nickname' => '007',
|
||||
'username' => 'test',
|
||||
'password' => 'too-obscure',
|
||||
'email' => 'test@machine.local',
|
||||
]
|
||||
])
|
||||
);
|
||||
|
||||
$this->assertEquals(422, $response->getStatusCode());
|
||||
}
|
||||
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
public function can_register_with_nickname_if_valid_regex()
|
||||
{
|
||||
$this->setting('flarum-nicknames.set_on_registration', true);
|
||||
$this->setting('flarum-nicknames.regex', '^[A-z]+$');
|
||||
|
||||
$response = $this->send(
|
||||
$this->request('POST', '/register', [
|
||||
'json' => [
|
||||
'nickname' => 'Acme',
|
||||
'username' => 'test',
|
||||
'password' => 'too-obscure',
|
||||
'email' => 'test@machine.local',
|
||||
]
|
||||
])
|
||||
);
|
||||
|
||||
$this->assertEquals(201, $response->getStatusCode());
|
||||
}
|
||||
}
|
||||
|
@@ -23,7 +23,7 @@
|
||||
},
|
||||
"require": {
|
||||
"flarum/core": "^1.0.0",
|
||||
"composer/composer": "^2.0"
|
||||
"composer/composer": "^2.3"
|
||||
},
|
||||
"require-dev": {
|
||||
"flarum/testing": "^1.0.0",
|
||||
@@ -86,7 +86,7 @@
|
||||
"test:integration": "phpunit -c tests/phpunit.integration.xml",
|
||||
"test:setup": [
|
||||
"@php tests/integration/setup.php",
|
||||
"cd $FLARUM_TEST_TMP_DIR_LOCAL && composer install"
|
||||
"cd ${FLARUM_TEST_TMP_DIR_LOCAL:-${FLARUM_TEST_TMP_DIR:-./tests/integration/tmp}} && composer install"
|
||||
]
|
||||
},
|
||||
"scripts-descriptions": {
|
||||
|
3
extensions/package-manager/js/dist-typings/components/WhyNotModal.d.ts
generated
vendored
3
extensions/package-manager/js/dist-typings/components/WhyNotModal.d.ts
generated
vendored
@@ -1,4 +1,3 @@
|
||||
/// <reference path="../../../vendor/flarum/core/js/src/common/translator-icu-rich.d.ts" />
|
||||
import Mithril from 'mithril';
|
||||
import Modal, { IInternalModalAttrs } from 'flarum/common/components/Modal';
|
||||
export interface WhyNotModalAttrs extends IInternalModalAttrs {
|
||||
@@ -8,7 +7,7 @@ export default class WhyNotModal<Attrs extends WhyNotModalAttrs = WhyNotModalAtt
|
||||
loading: boolean;
|
||||
whyNot: string | null;
|
||||
className(): string;
|
||||
title(): import("@askvortsov/rich-icu-message-formatter").NestedStringArray;
|
||||
title(): any;
|
||||
oncreate(vnode: Mithril.VnodeDOM<Attrs, this>): void;
|
||||
content(): JSX.Element;
|
||||
requestWhyNot(): void;
|
||||
|
1211
extensions/package-manager/js/dist/admin.js
generated
vendored
1211
extensions/package-manager/js/dist/admin.js
generated
vendored
File diff suppressed because one or more lines are too long
2
extensions/package-manager/js/dist/admin.js.map
generated
vendored
2
extensions/package-manager/js/dist/admin.js.map
generated
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
@@ -58,7 +58,7 @@ class CheckForUpdatesHandler
|
||||
$actor->assertAdmin();
|
||||
|
||||
$firstOutput = $this->runComposerCommand(false);
|
||||
$firstOutput = json_decode($firstOutput, true);
|
||||
$firstOutput = json_decode($this->cleanJson($firstOutput), true);
|
||||
|
||||
$majorUpdates = false;
|
||||
|
||||
@@ -71,7 +71,7 @@ class CheckForUpdatesHandler
|
||||
|
||||
if ($majorUpdates) {
|
||||
$secondOutput = $this->runComposerCommand(true);
|
||||
$secondOutput = json_decode($secondOutput, true);
|
||||
$secondOutput = json_decode($this->cleanJson($secondOutput), true);
|
||||
}
|
||||
|
||||
if (! isset($secondOutput)) {
|
||||
@@ -101,6 +101,15 @@ class CheckForUpdatesHandler
|
||||
->save();
|
||||
}
|
||||
|
||||
/**
|
||||
* Composer can sometimes return text above the JSON.
|
||||
* This method tries to remove such occurences.
|
||||
*/
|
||||
protected function cleanJson(string $composerOutput): string
|
||||
{
|
||||
return preg_replace('/^[^{]+\n({.*)/ms', '$1', $composerOutput);
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws ComposerCommandFailedException
|
||||
*/
|
||||
|
@@ -15,27 +15,11 @@ class SetupComposer
|
||||
{
|
||||
use UsesTmpDir;
|
||||
|
||||
private $config = [
|
||||
'require' => [
|
||||
'flarum/core' => '1.0.0',
|
||||
'flarum/tags' => '1.0.3',
|
||||
'flarum/lang-english' => '*',
|
||||
],
|
||||
'config' => [
|
||||
'preferred-install' => 'dist',
|
||||
'sort-packages' => true,
|
||||
],
|
||||
'repositories' => [
|
||||
[
|
||||
'type' => 'path',
|
||||
'url' => __DIR__.'/tmp/packages/*',
|
||||
]
|
||||
]
|
||||
];
|
||||
private $config;
|
||||
|
||||
public function __construct(array $config = null)
|
||||
{
|
||||
$this->config = array_merge($this->config, $config ?? []);
|
||||
$this->config = $config;
|
||||
}
|
||||
|
||||
public function run()
|
||||
@@ -44,7 +28,7 @@ class SetupComposer
|
||||
$composerLock = $this->tmpDir().'/composer.lock';
|
||||
$packages = $this->tmpDir().'/packages';
|
||||
|
||||
file_put_contents($composerJson, json_encode($this->config, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT));
|
||||
file_put_contents($composerJson, json_encode($this->getConfig(), JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT));
|
||||
|
||||
if (! file_exists($packages)) {
|
||||
mkdir($packages);
|
||||
@@ -53,5 +37,28 @@ class SetupComposer
|
||||
if (file_exists($composerLock)) {
|
||||
unlink($composerLock);
|
||||
}
|
||||
|
||||
echo 'composer.json created with testing packages directory.';
|
||||
}
|
||||
|
||||
private function getConfig(): array
|
||||
{
|
||||
return array_merge([
|
||||
'require' => [
|
||||
'flarum/core' => '1.0.0',
|
||||
'flarum/tags' => '1.0.3',
|
||||
'flarum/lang-english' => '*',
|
||||
],
|
||||
'config' => [
|
||||
'preferred-install' => 'dist',
|
||||
'sort-packages' => true,
|
||||
],
|
||||
'repositories' => [
|
||||
[
|
||||
'type' => 'path',
|
||||
'url' => realpath($this->tmpDir()).'/packages/*',
|
||||
]
|
||||
]
|
||||
], $this->config ?? []);
|
||||
}
|
||||
}
|
||||
|
@@ -19,10 +19,7 @@
|
||||
<testsuites>
|
||||
<testsuite name="Flarum Integration Tests">
|
||||
<directory suffix="Test.php">./integration</directory>
|
||||
<exclude>./integration/tmp</exclude>
|
||||
<exclude>./integration/tmp</exclude>
|
||||
</testsuite>
|
||||
</testsuites>
|
||||
<php>
|
||||
<env name="FLARUM_TEST_TMP_DIR_LOCAL" value="tests/integration/tmp" force="true" />
|
||||
</php>
|
||||
</phpunit>
|
||||
|
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/pusher",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2",
|
||||
"flarum/core": "^1.3",
|
||||
"pusher/pusher-php-server": "^2.2"
|
||||
},
|
||||
"require-dev": {
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/statistics",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -7,7 +7,7 @@
|
||||
],
|
||||
"license": "MIT",
|
||||
"support": {
|
||||
"issues": "https://github.com/flarum/framework/issues",
|
||||
"issues": "https://github.com/flarum/core/issues",
|
||||
"source": "https://github.com/flarum/sticky",
|
||||
"forum": "https://discuss.flarum.org"
|
||||
},
|
||||
@@ -19,7 +19,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"flarum/core": "^1.2"
|
||||
"flarum/core": "^1.3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
@@ -51,7 +51,7 @@
|
||||
"prettier": true,
|
||||
"typescript": false,
|
||||
"bundlewatch": false,
|
||||
"backendTesting": false,
|
||||
"backendTesting": true,
|
||||
"editorConfig": true,
|
||||
"styleci": true
|
||||
}
|
||||
@@ -64,5 +64,28 @@
|
||||
}
|
||||
],
|
||||
"minimum-stability": "dev",
|
||||
"prefer-stable": true
|
||||
"prefer-stable": true,
|
||||
"autoload-dev": {
|
||||
"psr-4": {
|
||||
"Flarum\\Sticky\\Tests\\": "tests/"
|
||||
}
|
||||
},
|
||||
"scripts": {
|
||||
"test": [
|
||||
"@test:unit",
|
||||
"@test:integration"
|
||||
],
|
||||
"test:unit": "phpunit -c tests/phpunit.unit.xml",
|
||||
"test:integration": "phpunit -c tests/phpunit.integration.xml",
|
||||
"test:setup": "@php tests/integration/setup.php"
|
||||
},
|
||||
"scripts-descriptions": {
|
||||
"test": "Runs all tests.",
|
||||
"test:unit": "Runs all unit tests.",
|
||||
"test:integration": "Runs all integration tests.",
|
||||
"test:setup": "Sets up a database for use with integration tests. Execute this only once."
|
||||
},
|
||||
"require-dev": {
|
||||
"flarum/testing": "^1.0.0"
|
||||
}
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -60,7 +60,6 @@ class PinStickiedDiscussionsToTop
|
||||
$query->orderByRaw('is_sticky and not exists ('.$read->toSql().') and last_posted_at > ? desc')
|
||||
->addBinding(array_merge($read->getBindings(), [$filterState->getActor()->read_time ?: 0]), 'union');
|
||||
|
||||
$query->unionOrders = array_merge($query->unionOrders, $query->orders);
|
||||
$query->unionLimit = $query->limit;
|
||||
$query->unionOffset = $query->offset;
|
||||
|
||||
|
0
extensions/sticky/tests/fixtures/.gitkeep
vendored
Normal file
0
extensions/sticky/tests/fixtures/.gitkeep
vendored
Normal file
@@ -0,0 +1,90 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* This file is part of Flarum.
|
||||
*
|
||||
* For detailed copyright and license information, please view the
|
||||
* LICENSE file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Flarum\Sticky\tests\integration\api;
|
||||
|
||||
use Carbon\Carbon;
|
||||
use Flarum\Testing\integration\RetrievesAuthorizedUsers;
|
||||
use Flarum\Testing\integration\TestCase;
|
||||
use Illuminate\Support\Arr;
|
||||
|
||||
class ListDiscussionsTest extends TestCase
|
||||
{
|
||||
use RetrievesAuthorizedUsers;
|
||||
|
||||
protected function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
|
||||
$this->extension('flarum-sticky');
|
||||
|
||||
$this->prepareDatabase([
|
||||
'users' => [
|
||||
['id' => 1, 'username' => 'Muralf', 'email' => 'muralf@machine.local', 'is_email_confirmed' => 1],
|
||||
$this->normalUser()
|
||||
],
|
||||
'discussions' => [
|
||||
['id' => 1, 'title' => __CLASS__, 'created_at' => Carbon::now(), 'last_posted_at' => Carbon::now(), 'user_id' => 1, 'first_post_id' => 1, 'comment_count' => 1, 'is_sticky' => true],
|
||||
['id' => 2, 'title' => __CLASS__, 'created_at' => Carbon::now()->addMinute(), 'last_posted_at' => Carbon::now(), 'user_id' => 1, 'first_post_id' => 1, 'comment_count' => 1, 'is_sticky' => false],
|
||||
['id' => 3, 'title' => __CLASS__, 'created_at' => Carbon::now()->addMinutes(2), 'last_posted_at' => Carbon::now(), 'user_id' => 1, 'first_post_id' => 1, 'comment_count' => 1, 'is_sticky' => true],
|
||||
['id' => 4, 'title' => __CLASS__, 'created_at' => Carbon::now()->addMinutes(3), 'last_posted_at' => Carbon::now(), 'user_id' => 1, 'first_post_id' => 1, 'comment_count' => 1, 'is_sticky' => false],
|
||||
],
|
||||
'discussion_user' => [
|
||||
['discussion_id' => 1, 'user_id' => 1, 'last_read_post_number' => 1],
|
||||
['discussion_id' => 3, 'user_id' => 1, 'last_read_post_number' => 1],
|
||||
]
|
||||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function list_discussions_shows_sticky_first_as_guest()
|
||||
{
|
||||
$response = $this->send(
|
||||
$this->request('GET', '/api/discussions')
|
||||
);
|
||||
|
||||
$this->assertEquals(200, $response->getStatusCode());
|
||||
|
||||
$data = json_decode($response->getBody()->getContents(), true);
|
||||
|
||||
$this->assertEqualsCanonicalizing([1, 3, 2, 4], Arr::pluck($data['data'], 'id'));
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function list_discussions_shows_sticky_unread_first_as_user()
|
||||
{
|
||||
$response = $this->send(
|
||||
$this->request('GET', '/api/discussions', [
|
||||
'authenticatedAs' => 2
|
||||
])
|
||||
);
|
||||
|
||||
$this->assertEquals(200, $response->getStatusCode());
|
||||
|
||||
$data = json_decode($response->getBody()->getContents(), true);
|
||||
|
||||
$this->assertEqualsCanonicalizing([1, 3, 2, 4], Arr::pluck($data['data'], 'id'));
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function list_discussions_shows_normal_order_when_all_read_as_user()
|
||||
{
|
||||
$response = $this->send(
|
||||
$this->request('GET', '/api/discussions', [
|
||||
'authenticatedAs' => 1
|
||||
])
|
||||
);
|
||||
|
||||
$this->assertEquals(200, $response->getStatusCode());
|
||||
|
||||
$data = json_decode($response->getBody()->getContents(), true);
|
||||
|
||||
$this->assertEqualsCanonicalizing([1, 2, 3, 4], Arr::pluck($data['data'], 'id'));
|
||||
}
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user