Skip to content

Commit

Permalink
github actions: use rex-console setup (#5391)
Browse files Browse the repository at this point in the history
Co-authored-by: Gregor Harlan <330436+gharlan@users.noreply.github.com>
  • Loading branch information
staabm and gharlan committed Mar 10, 2023
1 parent ab45718 commit 581315c
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 85 deletions.
28 changes: 0 additions & 28 deletions .github/workflows/default.config.yml.github-action.diff

This file was deleted.

5 changes: 3 additions & 2 deletions .github/workflows/static-analysis.yml
Expand Up @@ -137,8 +137,9 @@ jobs:
run: |
sudo /etc/init.d/mysql start
mysql -uroot -h127.0.0.1 -proot -e 'create database redaxo5;'
git apply .github/workflows/default.config.yml.github-action.diff
php .tools/bin/setup
php redaxo/bin/console setup:run -n --lang=de_de --db-host=127.0.0.1 --db-name=redaxo5 --db-password=root --db-createdb=no --db-setup=normal --admin-username=admin --admin-password=adminpassword --error-email=test@redaxo.invalid --ansi
php redaxo/bin/console config:set --type boolean debug.enabled true
php redaxo/bin/console config:set --type boolean debug.throw_always_exception true
- name: Run phpstan analysis
run: vendor/bin/phpstan analyse --ansi
5 changes: 3 additions & 2 deletions .github/workflows/styles-compile.yml
Expand Up @@ -43,8 +43,9 @@ jobs:
run: |
sudo /etc/init.d/mysql start
mysql -uroot -h127.0.0.1 -proot -e 'create database redaxo5;'
git apply .github/workflows/default.config.yml.github-action.diff
php .tools/bin/setup
php redaxo/bin/console setup:run -n --lang=de_de --db-host=127.0.0.1 --db-name=redaxo5 --db-password=root --db-createdb=no --db-setup=normal --admin-username=admin --admin-password=adminpassword --error-email=test@redaxo.invalid --ansi
php redaxo/bin/console config:set --type boolean debug.enabled true
php redaxo/bin/console config:set --type boolean debug.throw_always_exception true
- name: Compile styles
run: php redaxo/bin/console be_style:compile --ansi
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/unit-tests.yml
Expand Up @@ -67,8 +67,9 @@ jobs:
- name: Setup REDAXO
run: |
mysql -uroot -h127.0.0.1 -proot -e 'create database redaxo5;'
git apply .github/workflows/default.config.yml.github-action.diff
php .tools/bin/setup
php redaxo/bin/console setup:run -n --lang=de_de --db-host=127.0.0.1 --db-name=redaxo5 --db-password=root --db-createdb=no --db-setup=normal --admin-username=admin --admin-password=adminpassword --error-email=test@redaxo.invalid --ansi
php redaxo/bin/console config:set --type boolean debug.enabled true
php redaxo/bin/console config:set --type boolean debug.throw_always_exception true
redaxo/bin/console system:report
- name: Run phpunit
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/visual-tests.yml
Expand Up @@ -64,11 +64,10 @@ jobs:
run: |
sudo /etc/init.d/mysql start
mysql -uroot -h127.0.0.1 -proot -e 'create database redaxo5;'
git apply .github/workflows/default.config.yml.github-action.diff
php redaxo/bin/console setup:run -n --lang=de_de --db-host=127.0.0.1 --db-name=redaxo5 --db-password=root --db-createdb=no --db-setup=normal --admin-username=admin --admin-password=adminpassword --error-email=test@redaxo.invalid --ansi
php redaxo/bin/console config:set --type boolean debug.enabled true
php redaxo/bin/console config:set --type boolean debug.throw_always_exception true
- name: Setup
run: |
php .tools/bin/setup
- name: Create user, update config
run: |
php redaxo/bin/console user:create myusername mypassword --admin --ansi
Expand All @@ -78,7 +77,7 @@ jobs:
mkdir -p $GITHUB_WORKSPACE/redaxo/data/addons/backup && cp -r .github/imports/inital-content-for-visual-tests.sql $GITHUB_WORKSPACE/redaxo/data/addons/backup/
cp -r .github/imports/media/* $GITHUB_WORKSPACE/media/
cp -f .github/imports/README.md $GITHUB_WORKSPACE/redaxo/src/addons/project/README.de.md
php redaxo/bin/console setup:run -n --lang=de_de --agree-license --db-password=root --db-setup=import --db-import=inital-content-for-visual-tests --admin-username=myusername --admin-password=mypassword --ansi
php redaxo/bin/console setup:run -n --lang=de_de --db-password=root --db-setup=import --db-import=inital-content-for-visual-tests --admin-username=myusername --admin-password=mypassword --ansi
- name: Install packages
run: |
php redaxo/bin/console package:install phpmailer --ansi
Expand Down
1 change: 0 additions & 1 deletion .php-cs-fixer.dist.php
Expand Up @@ -26,7 +26,6 @@
__DIR__.'/rector.php',
$tools.'/bin/clone-addon',
$tools.'/bin/release',
$tools.'/bin/setup',
$tools.'/bin/update-root-composer',
])
->filter(static function (SplFileInfo $file) use ($bootPath) {
Expand Down
45 changes: 0 additions & 45 deletions .tools/bin/setup

This file was deleted.

2 changes: 2 additions & 0 deletions redaxo/src/core/lib/console/setup/run.php
Expand Up @@ -66,6 +66,8 @@ protected function execute(InputInterface $input, OutputInterface $output): int
return $value;
};

rex_setup::init();

// ---------------------------------- Step 1 . Language
$io->title('Step 1 of 5 / Language');
$langs = [];
Expand Down

0 comments on commit 581315c

Please sign in to comment.