-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into mehulkar/turbo-955-polish-globalhashsummary-…
- Loading branch information
Showing
108 changed files
with
367 additions
and
928 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
Setup | ||
$ . ${TESTDIR}/../setup.sh | ||
$ . ${TESTDIR}/setup.sh $(pwd) | ||
|
||
Run script with INT handler and verify that INT gets passed to script | ||
|
||
Start turbo in the background | ||
$ ${TURBO} trap & | ||
Save the PID of turbo | ||
$ TURBO_PID=$! | ||
We send INT to turbo, but with a delay to give us time to bring turbo back to | ||
the foreground. | ||
$ sh -c "sleep 1 && kill -2 ${TURBO_PID}" & | ||
Bring turbo back to the foreground | ||
$ fg 1 | ||
${TURBO} trap | ||
\xe2\x80\xa2 Packages in scope: test (esc) | ||
\xe2\x80\xa2 Running trap in 1 packages (esc) | ||
\xe2\x80\xa2 Remote caching disabled (esc) | ||
test:trap: cache miss, executing d25759ee0a8e12ae | ||
test:trap: | ||
test:trap: > trap | ||
test:trap: > trap 'echo trap hit; sleep 1; echo trap finish' INT; sleep 5 && echo 'script finish' | ||
test:trap: | ||
test:trap: trap hit | ||
test:trap: trap finish | ||
test:trap: npm ERR! Lifecycle script `trap` failed with error: | ||
test:trap: npm ERR! Error: command failed | ||
test:trap: npm ERR! in workspace: test | ||
test:trap: npm ERR! at location: .*ctrlc.t/apps/test (re) | ||
[1] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#!/bin/bash | ||
# Enable jobcontrol as we need it for fg to work | ||
set -m | ||
|
||
SCRIPT_DIR=$(dirname ${BASH_SOURCE[0]}) | ||
TARGET_DIR=$1 | ||
cp -a ${SCRIPT_DIR}/test_repo/. ${TARGET_DIR}/ | ||
${SCRIPT_DIR}/../setup_git.sh ${TARGET_DIR} |
6 changes: 6 additions & 0 deletions
6
cli/integration_tests/signal_handling/test_repo/apps/test/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"name": "test", | ||
"scripts": { | ||
"trap": "trap 'echo trap hit; sleep 1; echo trap finish' INT; sleep 5 && echo 'script finish'" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"name": "signal-test", | ||
"workspaces": [ | ||
"apps/*" | ||
], | ||
"packageManager": "npm@8.0.0" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"$schema": "https://turbo.build/schema.json", | ||
"pipeline": { | ||
"trap": {} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.