Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
main: fix adjustments of bash options
- Loading branch information
1 parent
cdf74c2
commit 138c476
Showing
5 changed files
with
99 additions
and
3 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
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,25 @@ | ||
# debug | ||
|
||
print_posix() { | ||
local tag=$1 | ||
if [[ -o posix ]]; then | ||
echo "${tag:+$tag: }posix [POSIXLY_CORRECT=${POSIXLY_CORRECT-(unset)}]" | ||
else | ||
echo "${tag:+$tag: }not posix [POSIXLY_CORRECT=${POSIXLY_CORRECT-(unset)}]" | ||
fi >/dev/pts/3 | ||
} | ||
print_posix profile1 | ||
set +o posix | ||
print_posix profile2 | ||
|
||
# Test 1 (prompt attach) | ||
#source ~/.mwg/src/ble.sh/out/ble.sh --attach=prompt | ||
#PROMPT_COMMAND+=('print_posix PROMPT_COMMAND; unset POSIXLY_CORRECT') | ||
|
||
# Test 2 (direct attach) | ||
#source ~/.mwg/src/ble.sh/out/ble.sh --attach=attach | ||
|
||
# Test 3 (manual attach) | ||
source ~/.mwg/src/ble.sh/out/ble.sh --attach=none | ||
ble-attach | ||
#echo ATTACHED >/dev/tty |
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