Use sudoedit in examples instead of "sudo vi"

This commit is contained in:
Todd C. Miller
2016-11-02 17:07:25 -06:00
parent f6ce83ea76
commit a9715211a8
3 changed files with 10 additions and 10 deletions

View File

@@ -549,15 +549,15 @@ EEXXAAMMPPLLEESS
To edit the _i_n_d_e_x_._h_t_m_l file as user www:
$ sudo -u www vi ~www/htdocs/index.html
$ sudoedit -u www ~www/htdocs/index.html
To view system logs only accessible to root and users in the adm group:
$ sudo -g adm view /var/log/syslog
$ sudo -g adm more /var/log/syslog
To run an editor as jim with a different primary group:
$ sudo -u jim -g audio vi ~jim/sound.txt
$ sudoedit -u jim -g audio ~jim/sound.txt
To shut down a machine:
@@ -621,4 +621,4 @@ DDIISSCCLLAAIIMMEERR
file distributed with ssuuddoo or https://www.sudo.ws/license.html for
complete details.
Sudo 1.8.18 January 19, 2016 Sudo 1.8.18
Sudo 1.8.19 January 19, 2016 Sudo 1.8.19

View File

@@ -1096,7 +1096,7 @@ file as user www:
.nf
.sp
.RS 6n
$ sudo -u www vi ~www/htdocs/index.html
$ sudoedit -u www ~www/htdocs/index.html
.RE
.fi
.PP
@@ -1105,7 +1105,7 @@ group:
.nf
.sp
.RS 6n
$ sudo -g adm view /var/log/syslog
$ sudo -g adm more /var/log/syslog
.RE
.fi
.PP
@@ -1113,7 +1113,7 @@ To run an editor as jim with a different primary group:
.nf
.sp
.RS 6n
$ sudo -u jim -g audio vi ~jim/sound.txt
$ sudoedit -u jim -g audio ~jim/sound.txt
.RE
.fi
.PP

View File

@@ -1003,18 +1003,18 @@ To edit the
.Pa index.html
file as user www:
.Bd -literal -offset indent
$ sudo -u www vi ~www/htdocs/index.html
$ sudoedit -u www ~www/htdocs/index.html
.Ed
.Pp
To view system logs only accessible to root and users in the adm
group:
.Bd -literal -offset indent
$ sudo -g adm view /var/log/syslog
$ sudo -g adm more /var/log/syslog
.Ed
.Pp
To run an editor as jim with a different primary group:
.Bd -literal -offset indent
$ sudo -u jim -g audio vi ~jim/sound.txt
$ sudoedit -u jim -g audio ~jim/sound.txt
.Ed
.Pp
To shut down a machine: