add new chinese translations

This commit is contained in:
2024-12-30 15:25:56 +08:00
parent a850046d7b
commit 0d798759fd
5418 changed files with 105800 additions and 7052 deletions

20
pages.zh/linux/trap.md Normal file
View File

@@ -0,0 +1,20 @@
# trap
> 在事件发生时执行命令。
> 更多信息:<https://www.gnu.org/software/bash/manual/bash.html#index-trap>。
- 列出可用的事件名称(例如 `SIGWINCH`
`trap -l`
- 列出命令和预期事件的名称:
`trap -p`
- 在接收到信号时执行命令:
`trap 'echo "捕获信号 {{SIGHUP}}"' {{SIGHUP}}`
- 移除命令:
`trap - {{SIGHUP}} {{SIGINT}}`