Skip to content

Commit

Permalink
Fix race condition between cat and tee
Browse files Browse the repository at this point in the history
  • Loading branch information
deviantintegral committed Sep 29, 2023
1 parent 90319b3 commit 36f06cf
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .github/workflows/TestEnv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,10 @@ jobs:
ddev composer config --no-plugins allow-plugins.lullabot/drainpipe true
ddev composer config repositories.drainpipe --json "{\"type\": \"path\", \"url\": \"drainpipe\", \"options\": {\"symlink\": false}}"
ddev composer config minimum-stability dev
cat composer.json | jq --indent 4 '."autoload-dev" = {"files": ["vendor/lullabot/drainpipe/scaffold/env/dotenv.php"]}' | tee composer.json
# cat + tee still has a race condition causing random failures.
# https://stackoverflow.com/a/68676400
cat composer.json | jq --indent 4 '."autoload-dev" = {"files": ["vendor/lullabot/drainpipe/scaffold/env/dotenv.php"]}' | tee composer.new.json
mv composer.new.json composer.json
ddev composer update --lock
ddev composer validate
ddev composer require lullabot/drainpipe --with-all-dependencies
Expand Down

0 comments on commit 36f06cf

Please sign in to comment.