LoginSignup
0
0

More than 1 year has passed since last update.

ubuntu22.04: `usermod`コマンドの日本語版マニュアルには"-a"オプションが記載されていない

Last updated at Posted at 2023-04-06

環境

  • Xubuntu 22.04
$ uname -a
Linux example 5.15.0-69-generic #76-Ubuntu SMP Fri Mar 17 17:19:29 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

$ cat /etc/os-release 
PRETTY_NAME="Ubuntu 22.04.2 LTS"
NAME="Ubuntu"
VERSION_ID="22.04"
VERSION="22.04.2 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=jammy

usermodコマンドのマニュアル

たとえばdockerグループにユーザーを追加する場合は、以下のコマンドで実現できます。

$ sudo usermod -aG docker $USER

-aオプションの説明を見るため、manコマンドでマニュアルを確認しましたが、-aオプションの説明は記載されていませんでした。

$ echo $LANG
ja_JP.UTF-8

$ man usermod | cat
USERMOD(8)                                                                                                               System Manager's Manual                                                                                                              USERMOD(8)

名前
       usermod - ユーザアカウントを修正する

書式
       usermod [-c comment] [-d home_dir [-m]]
       [-e expire_date] [-f inactive_time]
       [-g initial_group] [-G group [,...]]
       [-l login_name] [-p passwd]
       [-s shell] [-u uid [-o]] [-L|-U] login

英語版のマニュアルには-aオプションが記載されていました。
また-b-Zなど、日本語版マニュアルに記載されていないオプションがいくつかありました。

$ man --locale en usermod | cat
USERMOD(8)                                                                                                             System Management Commands                                                                                                             USERMOD(8)

NAME
       usermod - modify a user account

SYNOPSIS
       usermod [options] LOGIN

DESCRIPTION
       The usermod command modifies the system account files to reflect the changes that are specified on the command line.

OPTIONS
       The options which apply to the usermod command are:

       -a, --append
           Add the user to the supplementary group(s). Use only with the -G option.

       -b, --badnames
           Allow names that do not conform to standards.

       -c, --comment COMMENT
           The new value of the user's password file comment field. It is normally modified using the chfn(1) utility.

...

usermodコマンドのマニュアルはいつ更新されたのか?

以下は日本語版マニュアルの中身です。
先頭のコメント行を見る限り最終更新年は2002年なのでしょうか?

.\" $Id$
.\" SPDX-FileCopyrightText: 1991 - 1994, Julianne Frances Haugh
.\" SPDX-FileCopyrightText: 1997 Kazuyoshi Furutaka
.\" SPDX-License-Identifier: BSD-3-Clause
.\" Translated Fri Feb 14 23:06:00 JST 1997
.\"         by Kazuyoshi Furutaka <furutaka@Flux.tokai.jaeri.go.jp>
.\" Updated Tue Jan 23 17:21:08 JST 2001
.\"         by Kentaro Shirakata <argrath@ub32.org>
.\" Modified Sun 22 Sep 2002 by NAKANO Takeo <nakano@apm.seikei.ac.jp>
.\"
.\"WORD:        initial group           主グループ
.\"WORD:        supplementary group     補助グループ
.\"
.TH USERMOD 8
.SH 名前
usermod \- ユーザアカウントを修正する
.SH 書式
\fBusermod\fR [\fB\-c\fR \fIcomment\fR] [\fB\-d\fR \fIhome_dir\fR [\fB\-m\fR]]
.br
[\fB\-e\fR \fIexpire_date\fR] [\fB\-f\fR \fIinactive_time\fR]
.br
[\fB\-g\fR \fIinitial_group\fR] [\fB\-G\fR \fIgroup\fR [,...]]
.br
[\fB\-l\fR \fIlogin_name\fR] [\fB\-p\fR \fIpasswd\fR]
.br
[\fB\-s\fR \fIshell\fR] [\fB\-u\fR \fIuid\fR [\fB\-o\fR]] [\fB\-L\fR|\fB\-U\fR]
\fIlogin\fR
.SH 説明

英語版のマニュアルに-aオプションの説明が追加されたのは、2012年でした。

日本語版マニュアルは2014年以降も更新されていますが、-aオプションの説明は追加されていませんでした。

たぶん本家であるshadow-maint/shadowの日本語版マニュアルにも、-aオプションの説明は記載されていませんでした。
https://github.com/shadow-maint/shadow/blob/f93cf255d4d8e79a5e3996590145507ea3e3f896/man/ja/man8/usermod.8

感想

日本語版マニュアルは英語版マニュアルより古いことは理解していましたが、よく利用する-aオプションが記載されていないほど古いとは思っていませんでした。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0