Show file listings in current directory
I used to just type ‘ls’ but you get much better info if you type out ‘ls -alh’. This should show you file sizes, dates and even hidden files. If its too much to type, try creating a shortcut/alias.
ls -alh
Creating a permanent alias
Useful for creating shortcuts to commands you do often. Here I setup an alias to run ‘ls -alh’ whenever I only type the letter ‘l’.
First start by editing the .bash_profile file (so you wont lose the alias when you relaunch the terminal)
nano ~/.bash_profile
Move your cursor to the end of the file and add:
alias l='ls -alh'
Press Ctrl O to save changes. Hit enter to agree to overwrite the existing file and then type Ctrl X to close the nano editor.
Create a new file
touch filename.ext
Show your current folder path
pwd