From nobody Thu Jul 13 11:03:25 2023 X-Original-To: dev-commits-doc-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4R1sCx3Q5Jz4mhFk for ; Thu, 13 Jul 2023 11:03:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4R1sCx2wZvz3k2j; Thu, 13 Jul 2023 11:03:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1689246205; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Q9tlbtmRX96iuYh5BFdy+sMl7PKAt5HTM86X1iO3BQE=; b=N40gXLEylSgevOzipcRZ05Y92s4RGOYH/F0f81IWVpJcILOtl+Pl9B4Yp5tTS0rGZzfi9F RncZD0mSE2bvdMlyiAMCLCr/NU1CCGxqq7NfXgA/HcY+jQJLYjdRNmfR3yJ6TlIZ3Kqw1t aP/EDwGy5IzdJd99HyfRw/53mcXE7vd5loV9enBk6rETngQqBjqMwYUGgWmzbkMfzWj2ZN Ews/Ygnly5/A0cw8Kjp5jNkK0zKgxT/iCSPfzRHKT/NNiyY5Pu18PiVVSBx10RxOolszuK 4GerEJyQhoMvxstWzGZrNAOcOTFBH5py0OszhlpjkCg11szCqG6umDVY2onPzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1689246205; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Q9tlbtmRX96iuYh5BFdy+sMl7PKAt5HTM86X1iO3BQE=; b=erFQFwaQIp31drdJjMsVC2RNY19/jY9fT+1xl1Eqf+Buz7QObzgwXtqY+avW6NtuhJKW4C iiwROBEzIj6ZcR1tBnUKmQNXqteL1APX/hXsf5Obt811HmQisiL5XiAoaJoub4an4R46iC B+RlJxpiJn+RkXfOyQhgE57e6oPf5ukeqeFcSA1QZf8Mt22lQvYMvYCNhnkL7+3gKx38CG eVfOz8uEGYNyStaGjzjJOgka4RPkGlKh+G2eD8uAu5D7geeh4tO+X8H4Ud0t5hi1mm8KGG wL1NMMpJWh7+oZ3eI36K1tsNzH6YRCrBWOutlYBNsL/yXTCj8jW45paoucBabw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1689246205; a=rsa-sha256; cv=none; b=D+JsuyBAOI0FwIofIetOZQOAbjMueFiijQ4fRAhVa4w1Q254zVoPWwyE9HHJXZg2Nm61Eu 8v9xMJz0wOsQcvjY7rqc7N6VUHaRTudzHg3oSTk5FAYtC0i+IQv46JqI31EICiZCdblNLv vT1sVN1CfkItPhXQ4bGa8tPD6k+bmf5xTIHl/XCD5SNpDcy14fbops8zYaHeIeTE3iN1Uv Wqmp/VxJNyvPJFvDOwMy3nMLZe+OzSVmjFi1Ow0guL+qPHqroY+IgjQswFT6nzzrGOzjD5 BtrpuGctMFOMVJO+5VRB4Sr/KoHrCCOEn4SHqOVXp0t7wEysI18T9sJ5Ou26AA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4R1sCx1z89zplZ; Thu, 13 Jul 2023 11:03:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 36DB3PT0081858; Thu, 13 Jul 2023 11:03:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 36DB3P4p081857; Thu, 13 Jul 2023 11:03:25 GMT (envelope-from git) Date: Thu, 13 Jul 2023 11:03:25 GMT Message-Id: <202307131103.36DB3P4p081857@gitrepo.freebsd.org> To: doc-committers@FreeBSD.org, dev-commits-doc-all@FreeBSD.org From: Sergio Carlavilla Delgado Subject: git: bb920e6c2c - main - Improve some shell syntax highlighting in basics chapter List-Id: Commit messages for all branches of the doc repository List-Archive: https://lists.freebsd.org/archives/dev-commits-doc-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-doc-all@freebsd.org X-BeenThere: dev-commits-doc-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: carlavilla X-Git-Repository: doc X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bb920e6c2c674c98bc8090cb19d5580ba842716f Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by carlavilla: URL: https://cgit.FreeBSD.org/doc/commit/?id=bb920e6c2c674c98bc8090cb19d5580ba842716f commit bb920e6c2c674c98bc8090cb19d5580ba842716f Author: Sergio Carlavilla Delgado AuthorDate: 2023-07-13 11:02:04 +0000 Commit: Sergio Carlavilla Delgado CommitDate: 2023-07-13 11:02:04 +0000 Improve some shell syntax highlighting in basics chapter PR: 269243 Submitted by: CiarĂ¡n Ainsworth Sponsored by: Daifressh --- .../content/en/books/handbook/basics/_index.adoc | 78 +++++++++++++++++++++- 1 file changed, 76 insertions(+), 2 deletions(-) diff --git a/documentation/content/en/books/handbook/basics/_index.adoc b/documentation/content/en/books/handbook/basics/_index.adoc index 1950c1cdba..db51642d18 100644 --- a/documentation/content/en/books/handbook/basics/_index.adoc +++ b/documentation/content/en/books/handbook/basics/_index.adoc @@ -74,7 +74,7 @@ After reading this chapter, you will know: Unless FreeBSD has been configured to automatically start a graphical environment during startup, the system will boot into a command line login prompt, as seen in this example: -[source,shell] +[.programlisting] .... FreeBSD/amd64 (pc3.example.org) (ttyv0) @@ -393,6 +393,12 @@ When finished, the utility will prompt to either create another user or to exit. [source,shell] .... # adduser +.... + +The output should be similar to the following: + +[.programlisting] +.... Username: jru Full name: J. Random User Uid (Leave empty for default): @@ -458,6 +464,13 @@ By default, an interactive mode is used, as shown in the following example. [source,shell] .... # rmuser jru + +.... + +The output should be similar to the following: + +[.programlisting] +.... Matching password entry: jru:*:1001:1001::0:0:J. Random User:/home/jru:/usr/local/bin/zsh Is this the entry you wish to remove? y @@ -490,7 +503,14 @@ This is shown in <>. ==== [source,shell] .... -#Changing user database information for jru. +# chpass +.... + +The output should be similar to the following: + +[.programlisting] +.... +# Changing user database information for jru. Login: jru Password: * Uid [#]: 1001 @@ -543,6 +563,12 @@ To prevent accidental or unauthorized changes, this command will prompt for the [source,shell] .... % passwd +.... + +The output should be similar to the following: + +[.programlisting] +.... Changing local password for jru. Old password: New password: @@ -562,6 +588,12 @@ This allows the password to be changed when a user cannot remember the original [source,shell] .... # passwd jru +.... + +The output should be similar to the following: + +[.programlisting] +.... Changing local password for jru. New password: Retype new password: @@ -610,6 +642,12 @@ Care must be taken when using the operator group, as unintended superuser-like a .... # pw groupadd teamtwo # pw groupshow teamtwo +.... + +The output should be similar to the following: + +[.programlisting] +.... teamtwo:*:1100: .... ==== @@ -625,6 +663,12 @@ This command will add `jru` as a member of `teamtwo`. .... # pw groupmod teamtwo -M jru # pw groupshow teamtwo +.... + +The output should be similar to the following: + +[.programlisting] +.... teamtwo:*:1100:jru .... ==== @@ -641,6 +685,12 @@ When man:pw[8] is used to add a user to a group, it only manipulates `/etc/group .... # pw groupmod teamtwo -m db # pw groupshow teamtwo +.... + +The output should be similar to the following: + +[.programlisting] +.... teamtwo:*:1100:jru,db .... ==== @@ -654,6 +704,12 @@ Unlike the previous example, these users are appended to the group and do not re [source,shell] .... % id jru +.... + +The output should be similar to the following: + +[.programlisting] +.... uid=1001(jru) gid=1001(jru) groups=1001(jru), 1100(teamtwo) .... ==== @@ -726,6 +782,12 @@ For example, `ls -l` in an arbitrary directory may show: [source,shell] .... % ls -l +.... + +The output should be similar to the following: + +[.programlisting] +.... total 530 -rw-r--r-- 1 root wheel 512 Sep 5 12:31 myfile -rw-r--r-- 1 root wheel 512 Sep 5 12:31 otherfile @@ -1490,6 +1552,12 @@ For example: [source,shell] .... % ps +.... + +The output should be similar to the following: + +[.programlisting] +.... PID TT STAT TIME COMMAND 8203 0 Ss 0:00.59 /bin/csh 8895 0 R+ 0:00.00 ps @@ -1512,6 +1580,12 @@ The output from man:top[1] is similar: [source,shell] .... % top +.... + +The output should be similar to the following: + +[.programlisting] +.... last pid: 9609; load averages: 0.56, 0.45, 0.36 up 0+00:20:03 10:21:46 107 processes: 2 running, 104 sleeping, 1 zombie CPU: 6.2% user, 0.1% nice, 8.2% system, 0.4% interrupt, 85.1% idle