diff options
author | xengineering <me@xengineering.eu> | 2023-02-16 18:00:06 +0100 |
---|---|---|
committer | xengineering <me@xengineering.eu> | 2023-02-16 18:00:06 +0100 |
commit | abe23f79a1889d5b9eacf0710a5b2a7950dcafdb (patch) | |
tree | 988c4b9e9aa659583cc78b8b0a9b102db53f2181 | |
parent | 0cb3c9d8e176f030ec7f62f072562cc1fe3bd6ae (diff) | |
download | website-abe23f79a1889d5b9eacf0710a5b2a7950dcafdb.tar website-abe23f79a1889d5b9eacf0710a5b2a7950dcafdb.tar.zst website-abe23f79a1889d5b9eacf0710a5b2a7950dcafdb.zip |
Reduce complexity of pacman-essentials.md
This article is for new users. They do not need to know *why* something
works or how it could be more *convenient*. They just have to know *how*
it works.
-rw-r--r-- | content/articles/pacman-essentials.md | 51 |
1 files changed, 12 insertions, 39 deletions
diff --git a/content/articles/pacman-essentials.md b/content/articles/pacman-essentials.md index 1153ba1..ddc99ee 100644 --- a/content/articles/pacman-essentials.md +++ b/content/articles/pacman-essentials.md @@ -7,33 +7,15 @@ The program `pacman` is the package manager of the [Arch Linux][1] distribution. It should be exclusively used to install, update and remove -software to an Arch Linux system. - -As a terminal program it has no graphical user interface (GUI). This might be -uncommon for new users but has advantages like being simple, scriptable and -easily to document like on this page. +software on an Arch Linux system. With an open terminal and this guide you should be able to manage the software on your Arch Linux instance in most cases. -#### Getting necessary permissions - -A regular Linux user is allowed to use pacman to get information. This includes -for example the package search with `pacman -Ss <keyword>`. - -Only the user `root` is allowed to use pacman to update, install or remove -software packages. Other users are able to get temporary root permissions by -using a program like `sudo`. - -Thus a pacman call like `pacman -Syu` should be rewritten to `sudo pacman -Syu` -to run it with root permissions. It should be mentioned that using `sudo` is -not required if logged in as user `root` or could be substituted by another -program like `doas`. - #### Full system update -Every Arch Linux installation should be regularly updated. For this purpose -the following command is used: +Use the following command to update all the software on an Arch Linux system. +This includes the operating system aswell as applications: ``` sudo pacman -Syu @@ -43,11 +25,6 @@ It runs interactively which means that questions should be answered by the user with pressing `y` or `n` followed by the `Enter` key. The default option (the bigger letter in `[Y/n]` or `[y/N]`) is a good option in most cases. -Updating a system every week is a good rule of thumb. It is especially -convenient to update the system before poweroff because most of it can run -without interaction. The poweroff can also be automatically triggered after a -successful update with `sudo pacman -Syu && poweroff`. - #### Package search One can search for existing packages with this command: @@ -68,29 +45,25 @@ excellent place to search for needed programs by category. Installing a package is simple: ``` -sudo pacman -S <package-name> +sudo pacman -S <package> ``` -`<package-name>` should be replaced by the lower case package name found with -the package search (see above) like `firefox` or `gimp`. - -It is also possible to install multiple packages with a space-separated list of -packages like `sudo pacman -S firefox gimp` or together with a full system -update `sudo pacman -Syu firefox`. +`<package>` should be replaced by the lower case package name found with the +package search (see above) like `firefox` or `gimp`. #### Package removal The recommended command to remove one or multiple packages is: ``` -sudo pacman -Rs <package-1> <package-2> +sudo pacman -Rs <package> ``` -The options `-Rs` select removal with `R` and recursive with `s`. The latter -option removes dependencies of this package too. Dependencies are packages -which are needed for the selected package to work. They get installed -automatically. The `s` option will leave a dependency on the system if -installed explicitly by the user or needed by another package. +While `R` selects removal `s` is the recursive option. This additionally +removes packages which were needed for the selected package to work. + +The recursive option is smart enough to leave a dependency on the system if it +is needed by another explicitly installed package. #### Further documentation |