Skip to content

Commit

Permalink
trap: simplify example and add example (#15683)
Browse files Browse the repository at this point in the history
  • Loading branch information
Managor authored Feb 6, 2025
1 parent 1da2707 commit c3b82e7
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pages/linux/trap.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

- List the commands and the names of the expected events:

`trap -p`
`trap`

- Execute a command when a signal is received:

Expand All @@ -18,3 +18,7 @@
- Remove commands:

`trap - {{SIGHUP}} {{SIGINT}}`

- Ignore a signal:

`trap '' {{SIGINT}}`

0 comments on commit c3b82e7

Please sign in to comment.