diff --git a/LICENSE.md b/LICENSE.md index cc3a9f5e99b436..9b4ebcb9a886af 100644 --- a/LICENSE.md +++ b/LICENSE.md @@ -3,7 +3,7 @@ Copyright © 2014—present the [tldr-pages team](https://github.com/orgs/tldr-p and [contributors](https://github.com/tldr-pages/tldr/graphs/contributors). **This work is licensed under the -[Creative Commons Attribution 4.0 International License](http://creativecommons.org/licenses/by/4.0/) +[Creative Commons Attribution 4.0 International License](https://creativecommons.org/licenses/by/4.0/) (CC-BY).** ---- diff --git a/README.md b/README.md index 2b8dd2ab17c257..319fc48f090ab7 100644 --- a/README.md +++ b/README.md @@ -91,7 +91,7 @@ If you don't want to install any software, check out the [PDF version](https://g There are also **various other clients** provided by the community, both for the command-line and for other platforms. -For a comprehensive list of clients, head over to our [Wiki](https://github.com/tldr-pages/tldr/wiki/tldr-pages-clients). +For a comprehensive list of clients, head over to our [Wiki](https://github.com/tldr-pages/tldr/wiki/Clients). ## How do I contribute to tldr-pages? diff --git a/contributing-guides/maintainers-guide.md b/contributing-guides/maintainers-guide.md index 45b521be5a8aef..ad7d34e1deacf5 100644 --- a/contributing-guides/maintainers-guide.md +++ b/contributing-guides/maintainers-guide.md @@ -60,13 +60,17 @@ for the behavior expected of tldr-pages maintainers. (2) have the **review comments addressed**, (3) get **approved reviews by two maintainers** (the second maintainer can merge immediately after approving). -- It is suggested to wait for a few hours before merging a pull request with new additions to English pages. This is to allow other maintainers to review the changes and provide feedback. +- It is suggested to wait for a few hours before merging a PR with new additions to English pages. This is to allow other maintainers to review the changes and provide feedback. + +- If a PR is non-English and there are automatic reviewers added via [CODEOWNERS](https://github.com/tldr-pages/tldr/blob/main/.github/CODEOWNERS), the PR at least needs one approval from one of the CODEOWNERS. + - If a PR fails to get a review from one of the CODEOWNERS after a few days, the first maintainer should ping the CODEOWNERS for review. + - If it still lingers around for **over 10 days upto 2 weeks without a approval from one of the CODEOWNERS**, the PR can be merged if it has two approvals. + - If it only has one approval, please read the next point. - If a PR fails to get a review from a second maintainer after a few days, - the first maintainer should ping others for review. If it still lingers around - for **over a week without a second maintainer’s approval**, - the first maintainer (if Owner) can go ahead and merge it. Otherwise, a message - can be sent in the chatroom asking other maintainers to review the PR. + the first maintainer should ping others for review. + - If it still lingers around for **over a week without a second maintainer’s approval**, the first maintainer (if Owner) can go ahead and merge it. + Otherwise, a message can be sent in the chatroom asking other maintainers to review the PR. - If the only issues holding up a merge are **trivial fixes** (typos, syntax errors, etc.), and the author doesn't respond in a day or two, diff --git a/contributing-guides/style-guide.md b/contributing-guides/style-guide.md index 059be5817e4d38..4a055dd47c1b15 100644 --- a/contributing-guides/style-guide.md +++ b/contributing-guides/style-guide.md @@ -112,7 +112,7 @@ Thus, if the command or its options are unavailable or contain different behavio ### Platform differences If you are afraid the commands may differ between platforms or operating systems (e.g. Windows vs macOS), -most [tldr pages clients](https://github.com/tldr-pages/tldr/wiki/tldr-pages-clients) will choose the most suitable version of the command to be displayed to the end user. +most [tldr pages clients](https://github.com/tldr-pages/tldr/wiki/Clients) will choose the most suitable version of the command to be displayed to the end user. In this case, the information of the Windows version of `cd` (stored in `pages/windows/cd.md`) will be displayed by default to Windows users, and a generic/common version (stored in `pages/common/cd.md`) will be displayed for Linux, macOS, and other platform users. diff --git a/contributing-guides/style-guide.zh.md b/contributing-guides/style-guide.zh.md index 39d801a43bcf11..42e4ff15dca89a 100644 --- a/contributing-guides/style-guide.zh.md +++ b/contributing-guides/style-guide.zh.md @@ -255,7 +255,7 @@ Display the current license's e[xp]i[r]ation date and time: - **所有描述必须以祈使句表达。** -如果你担心命令在不同平台或操作系统之间可能不同(例如 Windows 对比 macOS),大多数 [tldr 页面客户端](https://github.com/tldr-pages/tldr/wiki/tldr-pages-clients) 将选择最适合的命令版本。 +如果你担心命令在不同平台或操作系统之间可能不同(例如 Windows 对比 macOS),大多数 [tldr 页面客户端](https://github.com/tldr-pages/tldr/wiki/Clients) 将选择最适合的命令版本。 在这种情况下,默认将显示 Windows 版本的 `cd` 信息(存储在 `pages/windows/cd.md` 中)给 Windows 用户,并为 Linux、macOS 和其他平台显示一个通用版本(存储在 `pages/common/cd.md` 中)。 diff --git a/pages.fr/common/ghdl.md b/pages.fr/common/ghdl.md index b1f4fa12744911..3b3f9062226ed2 100644 --- a/pages.fr/common/ghdl.md +++ b/pages.fr/common/ghdl.md @@ -1,7 +1,7 @@ # ghdl > Simulateur à source ouvert pour le langage VHDL. -> Plus d'informations : . +> Plus d'informations : . - Analyse un fichier de source VHDL et génère un fichier objet : diff --git a/pages/common/$.md b/pages/common/$.md new file mode 100644 index 00000000000000..d193e4237be5c3 --- /dev/null +++ b/pages/common/$.md @@ -0,0 +1,24 @@ +# Dollar sign + +> Expand a bash variable. +> More information: . + +- Print a variable: + +`echo ${{VARIABLE}}` + +- Print the exit status of the previous command: + +`echo $?` + +- Print a random number between 0 and 32767: + +`echo $RANDOM` + +- Print one of the prompt strings: + +`echo ${{PS1|PS2|PS3|PS4}}` + +- Expand with the output of `command` and run it. Same as enclosing `command` in backtics: + +`$({{command}})` diff --git a/pages/common/ghdl.md b/pages/common/ghdl.md index a17f51dd1450d6..53ff3734176134 100644 --- a/pages/common/ghdl.md +++ b/pages/common/ghdl.md @@ -1,7 +1,7 @@ # ghdl > Open-source simulator for the VHDL language. -> More information: . +> More information: . - Analyze a VHDL source file and produce an object file: diff --git a/pages/common/greater-than.md b/pages/common/greater-than.md new file mode 100644 index 00000000000000..93c6e537d8bd09 --- /dev/null +++ b/pages/common/greater-than.md @@ -0,0 +1,20 @@ +# Greater than + +> Redirect output to a file. +> More information: . + +- Redirect `stdout` to a file: + +`{{command}} > {{path/to/file}}` + +- Append to a file: + +`{{command}} >> {{path/to/file}}` + +- Redirect both `stdout` and `stderr` to a file: + +`{{command}} &> {{path/to/file}}` + +- Redirect both `stdout` and `stderr` to `/dev/null` to keep the terminal output clean: + +`{{command}} &> /dev/null` diff --git a/pages/common/less-than.md b/pages/common/less-than.md new file mode 100644 index 00000000000000..e1fdfbe7a79ee2 --- /dev/null +++ b/pages/common/less-than.md @@ -0,0 +1,9 @@ +# Less than + +> Redirect a file to `stdin`. +> Achieves the same effect as `cat file.txt |`. +> More information: . + +- Redirect a file to `stdin`: + +`{{command}} < {{path/to/file.txt}}` diff --git a/pages/common/vertical-bar.md b/pages/common/vertical-bar.md new file mode 100644 index 00000000000000..153cda597aa0f6 --- /dev/null +++ b/pages/common/vertical-bar.md @@ -0,0 +1,12 @@ +# Vertical bar + +> Pipe data between programs. +> More information: . + +- Pipe `stdout` to `stdin`: + +`{{command}} | {{command}}` + +- Pipe both `stdout` and `stderr` to `stdin`: + +`{{command}} |& {{command}}` diff --git a/pages/linux/apt-clone.md b/pages/linux/apt-clone.md new file mode 100644 index 00000000000000..9e9fea9bb143aa --- /dev/null +++ b/pages/linux/apt-clone.md @@ -0,0 +1,24 @@ +# apt-clone + +> Clone/backup/restore the package state of a Debian-based system. +> More information: . + +- Clone the package state of the current system into a specified directory: + +`apt-clone clone {{path/to/directory}}` + +- Create a clone file (`tar.gz`) for backup purposes: + +`apt-clone clone --destination {{path/to/backup.tar.gz}}` + +- Restore the package state from a clone file: + +`apt-clone restore {{path/to/backup.tar.gz}}` + +- Show information about a clone file (e.g., the release, architecture): + +`apt-clone info {{path/to/backup.tar.gz}}` + +- Check if the clone file can be restored on the current system: + +`apt-clone restore {{path/to/backup.tar.gz}} --destination {{path/to/restore}}`