Popular Linux OS

  • Debian -> Ubuntu -> Linux MINT
  • RedHat -> Fedora -> (opensuse)
  • Arch -> (Manjero)

Shell Command notes

##pwd Print current directory

##cd

  • . ->
  • .. -> go back
  • - -> go previous
  • ~ -> home ##ls
  • ls -a show with hidden folders
  • ls -t sort by date modification ls -r sort in reverse
  • ls -R recursivily list directory
  • ls -l show details of each file

    touch

    Create a new file or update the timestamps on existing file

    file

    See file informatin incuding the file type

    cat

    see whats inside the file

    less

    see whats inside the file with navigation feature j for up k for down g for top G for bottom and q for quit

    ctrl + R

    search in command history

    !!

    run previous command

    history

    show all commands history

    cp

  • cp -r copy recursively
  • cp -i copy with warning prompts

    mv

  • mv -i move with warning prompts
  • mv -b make a backup while moving

    mkdir

    mkdir -p dir/mydir also creates sub directories

  • rm -f force remvoe
  • rm -i remove with warning prompts
  • rm -r remove recursively

    find

  • find PATH -name NAME search file in specific path with the name
  • find PATH -type TYPE -name NAME finds file of specific type with the given name in the given path

    whatis

    Learn about a command