1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-29 23:24:55 +02:00

glances, ifconfig, kill, killall, nano, neofetch, pm2, and screen: add Chinese translation (#14628)

* Add Chinese translations for glances, ifconfig, kill, killall, nano, neofetch, pm2, and screen.

* Improvement to the Chinese translation for screen.

* Fix formatting issues in glances, pm2, and neofetch Chinese versions

* Update nano and screen Chinese pages to match English page.

* Update pages.zh/common/screen.md

Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>

* Update pages.zh/common/nano.md

Ensure the format is the same as the English version

Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>

* glances, nano: Ensure Chinese version matches English format

* nano: Chinese translation correction

* nano: Second revision of Chinese translation, fixing all missing backticks.

* nano: Handle missing quotation marks in Chinese translation

* Update pages.zh/common/neofetch.md

Co-authored-by: Jack Lin <blueskyson1401@gmail.com>

* Update pages.zh/common/ifconfig.md

Co-authored-by: Jack Lin <blueskyson1401@gmail.com>

* Update pages.zh/common/glances.md

Co-authored-by: Jack Lin <blueskyson1401@gmail.com>

* Update pages.zh/common/glances.md

Co-authored-by: Jack Lin <blueskyson1401@gmail.com>

* Update neofetch.md

* Update neofetch.md

---------

Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
Co-authored-by: Jack Lin <blueskyson1401@gmail.com>
This commit is contained in:
Jin 2024-11-06 03:43:50 -05:00 committed by GitHub
parent 07ab2a759a
commit 236cafb0e1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 228 additions and 0 deletions

View file

@ -0,0 +1,24 @@
# glances
> 一个跨平台的系统监控工具。
> 更多信息:<https://nicolargo.github.io/glances/>.
- 启动 glances,实时显示系统状态:
`glances`
- 以网页服务器模式启动,在浏览器中查看监控数据:
`glances -w`
- 以服务器模式启动,允许其他 glances 客户端连接以查看数据:
`glances -s`
- 作为客户端连接到 glances 服务器:
`glances -c {{主机名或IP地址}}`
- 在(网页)服务器模式下启用密码保护:
`glances -s --password`

View file

@ -0,0 +1,24 @@
# ifconfig
> 网络接口配置工具。
> 更多信息:<https://net-tools.sourceforge.io/man/ifconfig.8.html>.
- 查看某个网络接口的网络设置:
`ifconfig {{接口名称}}`
- 显示所有接口的详细信息,包括已禁用的接口:
`ifconfig -a`
- 禁用一个接口:
`ifconfig {{接口名称}} down`
- 启用一个接口:
`ifconfig {{接口名称}} up`
- 为一个接口分配 IP 地址:
`ifconfig {{接口名称}} {{IP地址}}`

33
pages.zh/common/kill.md Normal file
View file

@ -0,0 +1,33 @@
# kill
> 向进程发送信号,通常用于停止进程。
> 除了 SIGKILL 和 SIGSTOP,所有信号都可以被进程拦截,以便进行正常退出。
> 更多信息:<https://manned.org/kill.1posix>.
- 使用默认的 SIGTERM(终止)信号来结束一个程序:
`kill {{进程ID}}`
- 列出可用的信号名称(使用时无需加 `SIG` 前缀):
`kill -l`
- 使用 SIGHUP(挂起)信号终止一个程序。许多守护进程接收到此信号后会重新加载而不是终止:
`kill -{{1|HUP}} {{进程ID}}`
- 使用 SIGINT(中断)信号终止一个程序。通常由用户按下 `Ctrl + C` 发起:
`kill -{{2|INT}} {{进程ID}}`
- 向操作系统发送信号,立即终止一个程序(程序无机会捕获信号):
`kill -{{9|KILL}} {{进程ID}}`
- 向操作系统发送信号,暂停一个程序,直到收到 SIGCONT(继续)信号:
`kill -{{17|STOP}} {{进程ID}}`
- 向所有具有指定 GID(组ID)的进程发送 `SIGUSR1` 信号:
`kill -{{SIGUSR1}} -{{组ID}}`

View file

@ -0,0 +1,25 @@
# killall
> 根据进程名称向所有实例发送终止信号(必须是精确的进程名称)。
> 除了 SIGKILL 和 SIGSTOP,所有信号都可以被进程拦截,从而实现正常退出。
> 更多信息:<https://manned.org/killall>.
- 使用默认的 SIGTERM(终止)信号结束进程:
`killall {{进程名称}}`
- 列出可用的信号名称(使用时无需加 `SIG` 前缀):
`killall -l`
- 交互式地询问确认后再终止进程:
`killall -i {{进程名称}}`
- 使用 SIGINT(中断)信号终止进程,与按下 `Ctrl + C` 发送的信号相同:
`killall -INT {{进程名称}}`
- 强制杀死一个进程:
`killall -KILL {{进程名称}}`

32
pages.zh/common/nano.md Normal file
View file

@ -0,0 +1,32 @@
# nano
> 命令行文本编辑器。一个功能更强的 `Pico` 克隆版。
> 更多信息:<https://nano-editor.org>.
- 启动编辑器:
`nano`
- 启动编辑器且不使用配置文件:
`nano --ignorercfiles`
- 打开指定文件,在关闭前一个文件后移动到下一个文件:
`nano {{路径/到/文件1 路径/到/文件2 ...}}`
- 打开文件并将光标定位到指定行和列:
`nano +{{行号}},{{列号}} {{路径/到/文件}}`
- 打开文件并启用软换行:
`nano --softwrap {{路径/到/文件}}`
- 打开文件并使新行缩进对齐到上一行:
`nano --autoindent {{路径/到/文件}}`
- 打开文件并在保存时创建备份文件(如 `路径/到/文件~`):
`nano --backup {{路径/到/文件}}`

View file

@ -0,0 +1,20 @@
# neofetch
> 命令行系统信息工具,以美观的方式显示系统信息。
> 更多信息:<https://github.com/dylanaraps/neofetch>.
- 显示系统信息:
`neofetch`
- 在输出中显示或隐藏指定的信息行,'信息名称'是配置文件中的函数名称,例如 memory:
`neofetch --{{enable|disable}} {{信息名称}}`
- 隐藏或显示操作系统架构信息:
`neofetch --os_arch {{on|off}}`
- 启用或禁用输出中的 CPU 品牌信息:
`neofetch --cpu_brand {{on|off}}`

33
pages.zh/common/pm2.md Normal file
View file

@ -0,0 +1,33 @@
# pm2
> Node.js 的进程管理工具。
> 用于日志管理、监控和配置进程。
> 更多信息:<https://pm2.keymetrics.io>.
- 启动一个进程并指定名称,以便后续操作使用:
`pm2 start {{app.js}} --name {{应用名称}}`
- 列出所有进程:
`pm2 list`
- 监控所有进程:
`pm2 monit`
- 停止一个进程:
`pm2 stop {{应用名称}}`
- 重启一个进程:
`pm2 restart {{应用名称}}`
- 保存当前所有进程,便于稍后恢复:
`pm2 save`
- 恢复之前保存的进程:
`pm2 resurrect`

37
pages.zh/common/screen.md Normal file
View file

@ -0,0 +1,37 @@
# screen
> 在远程服务器上保持会话打开。通过单个 SSH 连接管理多个窗口。
> 类似工具请参阅 `tmux``zellij`
> 更多信息:<https://manned.org/screen>.
- 启动一个新的 screen 会话:
`screen`
- 启动一个指定名称的新 screen 会话:
`screen -S {{会话名称}}`
- 启动一个后台会话,指定会话名称并执行指定命令并将日志输出到 screenlog.x:
`screen -dmLS {{会话名称}} {{命令}}`
- 显示所有打开的 screen 会话:
`screen -ls`
- 重新连接到一个打开的 screen 会话:
`screen -r {{会话名称}}`
- 从当前 screen 会话中分离(先按 `Ctrl + A` 然后按 `D` 分离会话):
`<Ctrl> + A, D`
- 关闭当前 screen 会话:
`<Ctrl> + A, K`
- 关闭一个已经分离的 screen 会话:
`screen -X -S {{会话名称}} quit`