-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(entrypoint): properly handle whitespace depending on the script kind
- Loading branch information
1 parent
0c79364
commit 29d9a25
Showing
3 changed files
with
72 additions
and
6 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
29 changes: 29 additions & 0 deletions
29
tests/__snapshots__/test_entrypoint/test_serilization[whitespaces].sh
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,29 @@ | ||
#!/bin/sh | ||
|
||
export PYTHONPATH=./lib | ||
export PATH=./bin:$PATH | ||
|
||
usage() { | ||
echo "Available commands" | ||
echo "==================" | ||
echo "cmd: whitespaces…" | ||
echo "shell: whitespaces…" | ||
echo "composite: whitespaces…" | ||
} | ||
|
||
case ${1} in | ||
cmd) | ||
whitespaces are ignored | ||
;; | ||
shell) | ||
whitespaces | ||
should be | ||
preserved | ||
;; | ||
composite) | ||
whitespaces are ignored | ||
;; | ||
*) | ||
usage | ||
;; | ||
esac |
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