usermod
Modifies a user account.
See also: `users`, `useradd`, `userdel`.
sudo usermod --login {new_username} {username}
sudo usermod --uid {id} {username}
sudo usermod --shell {path/to/shell} {username}
- Add a user to supplementary groups (mind the lack of whitespace):
sudo usermod --append --groups {group1,group2,...} {username}
- Change a user home directory:
sudo usermod --move-home --home {path/to/new_home} {username}
Copyright © 2014—present the tldr-pages team and contributors.
This work is licensed under the Creative Commons Attribution 4.0 International License (CC-BY).