Skip to content

Commit

Permalink
tested scenario
Browse files Browse the repository at this point in the history
  • Loading branch information
dsx724 committed May 8, 2022
1 parent 55dc5c7 commit db4de2c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Bash Trap Stack
## Purpose
The traps.sh shell script allows you to create a stack of commands to execute for trap.
The traps.sh bash shell script allows you to create a stack of commands to execute for trap.
## Commands
* traps_start - registers the exit trap
* traps_push $@ - pushes $@ as one entry to the stack
Expand All @@ -20,4 +20,5 @@ The traps.sh shell script allows you to create a stack of commands to execute fo
* traps_pop
* traps_stop
## Notes
Tested against Bash 5.
You can use *set -eE* along with *TRAPS_SIGNAL=ERR* before you start the trap stack to get the function and line number that triggered the trap.

0 comments on commit db4de2c

Please sign in to comment.