Permissions play an important role in Termux because they control how files and scripts are accessed and executed. If permissions are not set correctly, you may face errors while running programs. These commands help you manage access and keep your system organized.
Permissions & User Commands List
| Command | Use | Example |
|---|---|---|
| chmod | Change file permission | chmod 755 file.sh |
| chmod +x | Make file executable | chmod +x script.sh |
| chown | Change file owner | chown user file.txt |
| ls -l | Show file permissions | ls -l |
| id | Show user ID | id |
| whoami | Show current user | whoami |
| groups | Show user groups | groups |
| passwd | Change password | passwd |
These commands help you control file permissions and access in Termux. They are important when working with scripts, tools, and files.
Quick Examples
Make a script executable:
chmod +x script.shCheck file permissions:
ls -lCheck current user:
whoamiShow user ID:
id