From a3f2131eb69c57570a41d036f395df9252c39b8b Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Mon, 17 Jun 2019 13:25:50 +0200 Subject: doc: Use prompt more often --- nixos/doc/manual/configuration/ad-hoc-packages.xml | 10 +++++----- .../doc/manual/configuration/adding-custom-packages.xml | 8 ++++---- nixos/doc/manual/configuration/declarative-packages.xml | 2 +- nixos/doc/manual/configuration/matrix.xml | 16 ++++++++-------- nixos/doc/manual/configuration/modularity.xml | 10 +++++----- nixos/doc/manual/configuration/wireless.xml | 6 +++--- nixos/doc/manual/configuration/xfce.xml | 2 +- 7 files changed, 27 insertions(+), 27 deletions(-) (limited to 'nixos/doc/manual/configuration') diff --git a/nixos/doc/manual/configuration/ad-hoc-packages.xml b/nixos/doc/manual/configuration/ad-hoc-packages.xml index 19159d8db5b..c7e882d846f 100644 --- a/nixos/doc/manual/configuration/ad-hoc-packages.xml +++ b/nixos/doc/manual/configuration/ad-hoc-packages.xml @@ -9,7 +9,7 @@ With the command nix-env, you can install and uninstall packages from the command line. For instance, to install Mozilla Thunderbird: -$ nix-env -iA nixos.thunderbird +$ nix-env -iA nixos.thunderbird If you invoke this as root, the package is installed in the Nix profile /nix/var/nix/profiles/default and visible to all users of the system; otherwise, the package ends up in @@ -25,7 +25,7 @@ $ nix-env -iA nixos.thunderbird Packages come from the NixOS channel. You typically upgrade a package by updating to the latest version of the NixOS channel: -$ nix-channel --update nixos +$ nix-channel --update nixos and then running nix-env -i again. Other packages in the profile are not affected; this is the crucial difference @@ -34,21 +34,21 @@ $ nix-channel --update nixos their current versions in the NixOS channel. You can however upgrade all packages for which there is a newer version by doing: -$ nix-env -u '*' +$ nix-env -u '*' A package can be uninstalled using the flag: -$ nix-env -e thunderbird +$ nix-env -e thunderbird Finally, you can roll back an undesirable nix-env action: -$ nix-env --rollback +$ nix-env --rollback diff --git a/nixos/doc/manual/configuration/adding-custom-packages.xml b/nixos/doc/manual/configuration/adding-custom-packages.xml index cdcfa10b820..182641055e4 100644 --- a/nixos/doc/manual/configuration/adding-custom-packages.xml +++ b/nixos/doc/manual/configuration/adding-custom-packages.xml @@ -14,8 +14,8 @@ xlink:href="http://nixos.org/nixpkgs/manual">Nixpkgs manual. In short, you clone Nixpkgs: -$ git clone https://github.com/NixOS/nixpkgs -$ cd nixpkgs +$ git clone https://github.com/NixOS/nixpkgs +$ cd nixpkgs Then you write and test the package as described in the Nixpkgs manual. Finally, you add it to environment.systemPackages, e.g. @@ -65,8 +65,8 @@ stdenv.mkDerivation rec { This allows testing the package easily: -$ nix-build my-hello.nix -$ ./result/bin/hello +$ nix-build my-hello.nix +$ ./result/bin/hello Hello, world! diff --git a/nixos/doc/manual/configuration/declarative-packages.xml b/nixos/doc/manual/configuration/declarative-packages.xml index c9acbefea60..5fb3bcb9f8f 100644 --- a/nixos/doc/manual/configuration/declarative-packages.xml +++ b/nixos/doc/manual/configuration/declarative-packages.xml @@ -22,7 +22,7 @@ You can get a list of the available packages as follows: -$ nix-env -qaP '*' --description +$ nix-env -qaP '*' --description nixos.firefox firefox-23.0 Mozilla Firefox - the browser, reloaded ... diff --git a/nixos/doc/manual/configuration/matrix.xml b/nixos/doc/manual/configuration/matrix.xml index e43b70faf7a..4c559a71e81 100644 --- a/nixos/doc/manual/configuration/matrix.xml +++ b/nixos/doc/manual/configuration/matrix.xml @@ -141,15 +141,15 @@ in { . To create a new user or admin, run the following after you have set the secret and have rebuilt NixOS: - -$ nix run nixpkgs.matrix-synapse -$ register_new_matrix_user -k <your-registration-shared-secret> http://localhost:8008 -New user localpart: <your-username> -Password: -Confirm password: -Make admin [no]: + +$ nix run nixpkgs.matrix-synapse +$ register_new_matrix_user -k your-registration-shared-secret http://localhost:8008 +New user localpart: your-username +Password: +Confirm password: +Make admin [no]: Success! - + In the example, this would create a user with the Matrix Identifier @your-username:example.org. Note that the registration secret ends up in the nix store and therefore is world-readable by any user diff --git a/nixos/doc/manual/configuration/modularity.xml b/nixos/doc/manual/configuration/modularity.xml index 67bb5a47d72..7ad0ae80a48 100644 --- a/nixos/doc/manual/configuration/modularity.xml +++ b/nixos/doc/manual/configuration/modularity.xml @@ -106,21 +106,21 @@ The unique option `services.httpd.adminAddr' is defined multiple times, in `/etc configuration option is. The command allows you to find out: -$ nixos-option +$ nixos-option true -$ nixos-option +$ nixos-option [ "tun" "ipv6" "loop" ... ] Interactive exploration of the configuration is possible using nix repl, a read-eval-print loop for Nix expressions. A typical use: -$ nix repl '<nixpkgs/nixos>' +$ nix repl '<nixpkgs/nixos>' -nix-repl> config. +nix-repl> config. "mandark" -nix-repl> map (x: x.hostName) config. +nix-repl> map (x: x.hostName) config. [ "example.org" "example.gov" ] diff --git a/nixos/doc/manual/configuration/wireless.xml b/nixos/doc/manual/configuration/wireless.xml index 7c7b3b4a65a..9c0e3a8d7aa 100644 --- a/nixos/doc/manual/configuration/wireless.xml +++ b/nixos/doc/manual/configuration/wireless.xml @@ -37,7 +37,7 @@ If you are using WPA2 you can generate pskRaw key using wpa_passphrase: -$ wpa_passphrase ESSID PSK +$ wpa_passphrase ESSID PSK network={ ssid="echelon" #psk="abcdefgh" @@ -54,10 +54,10 @@ network={ or you can use it to directly generate the wpa_supplicant.conf: -# wpa_passphrase ESSID PSK > /etc/wpa_supplicant.conf +# wpa_passphrase ESSID PSK > /etc/wpa_supplicant.conf After you have edited the wpa_supplicant.conf, you need to restart the wpa_supplicant service. -# systemctl restart wpa_supplicant.service +# systemctl restart wpa_supplicant.service diff --git a/nixos/doc/manual/configuration/xfce.xml b/nixos/doc/manual/configuration/xfce.xml index f2967fa3b10..6ac99c6b2be 100644 --- a/nixos/doc/manual/configuration/xfce.xml +++ b/nixos/doc/manual/configuration/xfce.xml @@ -64,7 +64,7 @@ Thunar:2410): GVFS-RemoteVolumeMonitor-WARNING **: remote volume monitor with db Session and Startup settings panel. Alternatively, you can run this command to do the same thing. -$ xfconf-query -c xfce4-session -p /compat/LaunchGNOME -s true +$ xfconf-query -c xfce4-session -p /compat/LaunchGNOME -s true A log-out and re-log will be needed for this to take effect. -- cgit 1.4.1