Semper Phone

Effortless
LEARNING

  • Improve effortlessly – just by living your life
  • Learn while waiting for your apps to load
  • Recommended by 5 universities
  • Community of over 1,000,000 learners
  • 50,000+ expert-made packs, or create your own
"One of the best learning apps" - CNET
  • Apple Play Store
  • Install Semper from the Play Store
bash commands

bash commands

Last update 

This contains most of the commands you can use in a bash shell in a linux system. Commands that are marked with a "•" are bash built-ins. Adopted from: http://ss64.com/bash/

Items (251)

  • Create an alias •

    alias

  • Search Help manual pages (man -k)

    apropos

  • Search for and install software packages (Debian/Ubuntu)

    apt-get

  • Search for and install software packages (Debian/Ubuntu)

    aptitude

  • Spell Checker

    aspell

  • Find and Replace text, database sort/validate/index

    awk

  • Strip directory and suffix from filenames

    basename

  • GNU Bourne-Again SHell

    bash

  • Arbitrary precision calculator language

    bc

  • Send to background

    bg

  • Exit from a loop •

    break

  • Run a shell builtin

    builtin

  • Compress or decompress named file(s)

    bzip2

  • Display a calendar

    cal

  • Conditionally perform a command

    case

  • Concatenate and print (display) the content of files

    cat

  • Change Directory

    cd

  • Partition table manipulator for Linux

    cfdisk

  • Change group ownership

    chgrp

  • Change access permissions

    chmod

  • Change file owner and group

    chown

  • Run a command with a different root directory

    chroot

  • System services (runlevel)

    chkconfig

  • Print CRC checksum and byte counts

    cksum

  • Clear terminal screen

    clear

  • Compare two files

    cmp

  • Compare two sorted files line by line

    comm

  • Run a command - ignoring shell functions •

    command

  • Resume the next iteration of a loop •

    continue

  • Copy one or more files to another location

    cp

  • Daemon to execute scheduled commands

    cron

  • Schedule a command to run at a later time

    crontab

  • Split a file into context-determined pieces

    csplit

  • Divide a file into several parts

    cut

  • Display or change the date & time

    date

  • Desk Calculator

    dc

  • Convert and copy a file, write disk headers, boot records

    dd

  • Data recovery tool

    ddrescue

  • Declare variables and give them attributes •

    declare

  • Display free disk space

    df

  • Display the differences between two files

    diff

  • Show differences among three files

    diff3

  • DNS lookup

    dig

  • Briefly list directory contents

    dir

  • Colour setup for `ls'

    dircolors

  • Convert a full pathname to just a path

    dirname

  • Display list of remembered directories

    dirs

  • Print kernel & driver messages

    dmesg

  • Estimate file space usage

    du

  • Display message on screen •

    echo

  • Search file(s) for lines that match an extended expression

    egrep

  • Eject removable media

    eject

  • Enable and disable builtin shell commands •

    enable

  • Environment variables

    env

  • Ethernet card settings

    ethtool

  • Evaluate several commands/arguments

    eval

  • Execute a command

    exec

  • Exit the shell

    exit

  • Automate arbitrary applications accessed over a terminal

    expect

  • Convert tabs to spaces

    expand

  • Set an environment variable

    export

  • Evaluate expressions

    expr

  • Do nothing, unsuccessfully

    false

  • Low-level format a floppy disk

    fdformat

  • Partition table manipulator for Linux

    fdisk

  • Send job to foreground

    fg

  • Search file(s) for lines that match a fixed string

    fgrep

  • Determine file type

    file

  • Search for files that meet a desired criteria

    find

  • Reformat paragraph text

    fmt

  • Wrap text to fit a specified width.

    fold

  • Expand words, and execute commands

    for

  • Format disks or tapes

    format

  • Display memory usage

    free

  • File system consistency check and repair

    fsck

  • File Transfer Protocol

    ftp

  • Define Function Macros

    function

  • Identify/kill the process that is accessing a file

    fuser

  • Find and Replace text within file(s)

    gawk

  • Parse positional parameters

    getopts

  • Search file(s) for lines that match a given pattern

    grep

  • Add a user security group

    groupadd

  • Delete a group

    groupdel

  • Modify a group

    groupmod

  • Print group names a user is in

    groups

  • Compress or decompress named file(s)

    gzip

  • Remember the full pathname of a name argument

    hash

  • Output the first part of file(s)

    head

  • Display help for a built-in command •

    help

  • Command History

    history

  • Print or set system name

    hostname

  • Convert the character set of a file

    iconv

  • Print user and group id's

    id

  • Conditionally perform a command

    if

  • Configure a network interface

    ifconfig

  • Stop a network interface

    ifdown

  • Start a network interface up

    ifup

  • Capture an X server screen and save the image to file

    import

  • Copy files and set attributes

    install

  • List active jobs •

    jobs

  • Join lines on a common field

    join

  • Stop a process from running

    kill

  • Kill processes by name

    killall

  • Display output one screen at a time

    less

  • Perform arithmetic on shell variables •

    let

  • Create a link to a file

    link

  • Create a symbolic link to a file

    ln

  • Create variables •

    local

  • Find files

    locate

  • Print current login name

    logname

  • Exit a login shell •

    logout

  • Display lines beginning with a given string

    look

  • Line printer control program

    lpc

  • Off line print

    lpr

  • Print a file

    lprint

  • Abort a print job

    lprintd

  • List the print queue

    lprintq

  • Remove jobs from the print queue

    lprm

  • List information about file(s)

    ls

  • List open files

    lsof

  • Recompile a group of programs

    make

  • Help manual

    man

  • Create new folder(s)

    mkdir

  • Make FIFOs (named pipes)

    mkfifo

  • Create an hybrid ISO9660/JOLIET/HFS filesystem

    mkisofs

  • Make block or character special files

    mknod

  • Display output one screen at a time

    more

  • Browse or page through a text file

    most

  • Mount a file system

    mount

  • Manipulate MS-DOS files

    mtools

  • Network diagnostics (traceroute/ping)

    mtr

  • Move or rename files or directories

    mv

  • Mass Move and rename (files)

    mmv

  • Networking information

    netstat

  • Set the priority of a command or job

    nice

  • Number lines and write files

    nl

  • Run a command immune to hangups

    nohup

  • ndSend desktop notifications

    notify-se

  • Query Internet name servers interactively

    nslookup

  • Open a file in its default application

    open

  • Operator access

    op

  • Modify a user password

    passwd

  • Merge lines of files

    paste

  • Check file name portability

    pathchk

  • Test a network connection

    ping

  • Stop processes from running

    pkill

  • Restore the previous value of the current directory

    popd

  • Prepare files for printing

    pr

  • Printer capability database

    printcap

  • Print environment variables

    printenv

  • Format and print data •

    printf

  • Process status

    ps

  • Save and then change the current directory

    pushd

  • Monitor the progress of data through a pipe

    pv

  • Print Working Directory

    pwd

  • Display disk usage and limits

    quota

  • k Scan a file system for disk usage

    quotachec

  • Set disk quotas

    quotactl

  • ram disk device

    ram

  • Copy files between two machines

    rcp

  • Read a line from standard input •

    read

  • Read from stdin into an array variable •

    readarray

  • Mark variables/functions as readonly

    readonly

  • Reboot the system

    reboot

  • Rename files

    rename

  • Alter priority of running processes

    renice

  • Synchronize remote files via email

    remsync

  • Exit a shell function

    return

  • Reverse lines of a file

    rev

  • Remove files

    rm

  • Remove folder(s)

    rmdir

  • Remote file copy (Synchronize file trees)

    rsync

  • Multiplex terminal, run remote shells via ssh

    screen

  • Secure copy (remote file copy)

    scp

  • Merge two files interactively

    sdiff

  • Stream Editor

    sed

  • Accept keyboard input

    select

  • Print numeric sequences

    seq

  • Manipulate shell variables and functions

    set

  • Secure File Transfer Program

    sftp

  • Shift positional parameters

    shift

  • Shell Options

    shopt

  • Shutdown or restart linux

    shutdown

  • Delay for a specified time

    sleep

  • Find files

    slocate

  • Sort text files

    sort

  • Run commands from a file '.'

    source

  • Split a file into fixed-size pieces

    split

  • Secure Shell client (remote login program)

    ssh

  • Display file or file system status

    stat

  • Trace system calls and signals

    strace

  • Substitute user identity

    su

  • Execute a command as another user

    sudo

  • Print a checksum for a file

    sum

  • Suspend execution of this shell •

    suspend

  • Synchronize data on disk with memory

    sync

  • Output the last part of file

    tail

  • Store, list or extract files in an archive

    tar

  • Redirect output to multiple files

    tee

  • Evaluate a conditional expression

    test

  • Measure Program running time

    time

  • Run a command with a time limit

    timeout

  • User and system times

    times

  • Change file timestamps

    touch

  • List processes running on the system

    top

  • e Trace Route to Host

    tracerout

  • Run a command when a signal is set(bourne)

    trap

  • Translate, squeeze, and/or delete characters

    tr

  • Do nothing, successfully

    true

  • Topological sort

    tsort

  • Print filename of terminal on stdin

    tty

  • Describe a command •

    type

  • Limit user resources •

    ulimit

  • Users file creation mask

    umask

  • Unmount a device

    umount

  • Remove an alias •

    unalias

  • Print system information

    uname

  • Convert spaces to tabs

    unexpand

  • Uniquify files

    uniq

  • Convert units from one scale to another

    units

  • Remove variable or function names

    unset

  • Unpack shell archive scripts

    unshar

  • Execute commands (until error)

    until

  • Show uptime

    uptime

  • Create new user account

    useradd

  • Delete a user account

    userdel

  • Modify user account

    usermod

  • List users currently logged in

    users

  • Encode a binary file

    uuencode

  • Decode a file created by uuencode

    uudecode

  • Verbosely list directory contents (`ls -l -b')

    v

  • Verbosely list directory contents (`ls -l -b')

    vdir

  • Text Editor

    vi

  • Report virtual memory statistics

    vmstat

  • Wait for a process to complete •

    wait

  • Execute/display a program periodically

    watch

  • Print byte, word, and line counts

    wc

  • Search the user's $path, man pages and source files for a program

    whereis

  • Search the user's $path for a program file

    which

  • Execute commands

    while

  • Print all usernames currently logged in

    who

  • Print the current user id and name (`id -un')

    whoami

  • Retrieve web pages or files via HTTP, HTTPS or FTP

    wget

  • Send a message to another user

    write

  • Execute utility, passing constructed argument list(s)

    xargs

  • Open a file or URL in the user's preferred application.

    xdg-open

  • Print a string until interrupted

    yes

  • Package and compress (archive) files.

    zip

  • Run a command script in the current shell

    .

  • Run the last command again

    !!

  • Comment / Remark

    ###