From 5a1b0c464bd07376ba9d192fb566dff2e6ecc8e3 Mon Sep 17 00:00:00 2001 From: chrisdebian Date: Wed, 8 Jul 2026 13:50:38 +0100 Subject: [PATCH] feat: forward parameters to acclint/acceptance-lint, add bundlelock alias acceptance-lint and acclint ran run_linting.sh with no way to pass extra arguments through, unlike acctest/acceptance-test next to them which already forward "${@:2}". Bring them into line so linting scripts can accept flags (e.g. auto-fix) the same way test scripts accept cucumber args. Also adds a bundlelock alias, following the same ex/manage() pattern, to run `bundle lock` in a container - optionally scoped to specific gem names to update just those. Closes #145. --- scripts/add-aliases.sh | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/scripts/add-aliases.sh b/scripts/add-aliases.sh index f14f5f9..d9b21a5 100755 --- a/scripts/add-aliases.sh +++ b/scripts/add-aliases.sh @@ -148,17 +148,21 @@ function acctest(){ } function acceptance-lint(){ - run ${1} sh run_linting.sh + run ${1} sh run_linting.sh "${@:2}" } function acclint(){ - run ${1} sh run_linting.sh + run ${1} sh run_linting.sh "${@:2}" } function manage(){ ex ${1} python3 manage.py ${@:2} } +function bundlelock(){ + ex ${1} bundle lock "${@:2}" +} + function localstack(){ ex localstack awslocal ${@:1} } @@ -199,8 +203,8 @@ function devenv-help(){ integration-test - run the integration tests for an application (this expects there to be a Makefile with a integrationtest command) acceptance-test | acctest - run the acceptance tests run_tests.sh script inside the given container. If using the skeleton, any further parameters will be passed to cucumber. - acceptance-lint | acclint - run the acceptance tests run_linting.sh script inside the given container. - + acceptance-lint | acclint - run the acceptance tests run_linting.sh script inside the given container. Any further parameters are passed through to the linting script. + [linting args] format - run the formatter for an application (this expects there to be a Makefile with a format command) lint [-r] [-f] - run the linter for an application (this expects there to be a Makefile with a lint command) if you add -r it will output reports to the test-output folder @@ -210,6 +214,7 @@ function devenv-help(){ psql17 - run psql in the postgres-17 container db2co - run db2 command line in the db2_community container manage - run manage.py commands in a container + bundlelock [gem names] - run bundle lock in a container, updating the Gemfile.lock; pass gem names to update only those gems alembic - run an alembic db command in a container, with the appropriate environment variables preset add-to-docker-compose - looks in fragments folder of loaded apps to search for a new compose-fragment including the provided parameter eg docker-compose-syt2-fragment then runs docker-compose up