Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #trap_stack_test
- rm trap_stack_test.log
- touch trap_stack_test.log
- source trap_stack.sh
- rm trap_test_out.log
- touch trap_test_out.log
- trap_1(){ echo "trap_1" | tee -a trap_stack_test.log; }
- trap_2(){ echo "trap 2" | tee -a trap_stack_test.log; }
- trap trap_1 SIGINT
- trap_push_append "trap_2" SIGINT
- read -p "Press enter to continue"
Advertisement
Add Comment
Please, Sign In to add comment