Here is the video version, if you prefer it:
chown command is used to change the owner and/or the group of the file. (Shotts, 2019) You need superuser permissions to do this. To change only the owner, its syntax is as follows:
chown newOwner file
If you want to change both the owner and the group, use:
chown newOwner:newGroup file
If you want to change just the group:
chown :newGroup file
As I said in the post where we talked about file permissions, I never needed to mangle with groups.
Hope you learned something new!
Shotts, W. (2019). The Linux Command Line, Fifth Internet Edition. Retrieved from http://linuxcommand.org/tlcl.php. Pages 128-129
Subscribe to my newsletter to keep abreast of the interesting things I'm doing. I will send you the newsletter only when there is something interesting. This means 0% spam, 100% interesting content.