Understanding Linux Basics In Termux
Learn basic Linux commands in Termux to navigate files, manage folders, and use the terminal confidently.
Why Learn Linux Commands?
Termux works like a Linux terminal on Android.
Learning a few basic Linux commands will help you:
- Navigate files - Manage folders - Install tools - Run scripts - Use Termux efficiently
You do not need to memorize everything. Start with the basics.
---
Check Your Current Folder
Use:
bash
pwd
This shows your current directory path.
---
List Files and Folders
bash
ls
Show hidden files:
bash
ls -a
Detailed view:
bash
ls -l
---
Change Directory
Move into a folder:
bash
cd folder-name
Go back one folder:
bash
cd ..
Go to home directory:
bash
cd
---
Create a Folder
bash
mkdir myfolder
Create multiple folders:
bash
mkdir folder1 folder2
---
Create a File
bash
touch file.txt
---
Delete Files and Folders
Delete a file:
bash
rm file.txt
Delete a folder:
bash
rm -r folder-name
> Be careful with rm commands. Deleted files usually cannot be recovered.
---
Copy Files
bash
cp file.txt backup.txt
Copy a folder:
bash
cp -r myfolder backup-folder
---
Move or Rename Files
Rename a file:
bash
mv old.txt new.txt
Move a file:
bash
mv file.txt /storage/emulated/0/
---
View File Content
Show file content:
bash
cat file.txt
Edit a file using Nano:
bash
nano file.txt
---
Clear the Terminal
bash
clear
---
Update Packages
Keep Termux updated:
bash
pkg update && pkg upgrade
---
Install Packages
Example:
bash
pkg install python
---
Useful Beginner Tip
Use the TAB key for auto-completion.
Example:
bash
cd Down
Termux will automatically complete folder names if possible.
---
Common Beginner Mistake
Command Not Found
If you see:
text
command not found
It usually means:
- The package is not installed - The command name is wrong - There is a typing mistake
Double-check spelling before retrying.
---
Final Thoughts
Learning a few Linux basics makes using Termux much easier.
Start practicing these commands daily, and you will quickly become comfortable using the terminal on Android.
Newsletter
Stay in the loop
Get new posts delivered straight to your inbox. No spam, unsubscribe anytime.
Related Posts
Best Termux Settings To Change First
Improve your Termux experience with these important settings every beginner should change after installation.
Best Termux Themes
Customize your terminal with the best Termux themes for a cleaner and more modern Linux experience on Android.
How To Install Termux Safely
Learn the safest way to install Termux on Android using trusted sources like F-Droid and GitHub.