Some useful Linux scripts for the desktop Linux user who likes the command line.

There are many useful Linux tips that make the life of a Linux user much easier. One is for the VI or VIM editor. To open a file at a specific line; use this command.

homer@deusexmachina ~/Documents/yadex-1.7.901 $ vim src/x11.h +33

This will open the file x11.h at line 33.

How to ssh into a machine and open a specific directory.

homer@deusexmachina ~ $ ssh -t homer@localhost -p 443 'cd /tmp && exec $SHELL'
homer@localhost's password:
[email protected] /tmp $

That is one very useful trick.

Copying files from one machine to another using the sftp command:

Remove unnecessary packages using the apt command.

sudo apt autoremove

Get information about any non-free packages installed on your system. Type sudo apt-get install vrms and then run it.

homer@deusexmachina ~ $ vrms
           Non-free packages installed on deusexmachina
atmel-firmware                      Firmware for Atmel at76c50x wireless networking chips.
bluez-firmware                      Firmware for Bluetooth devices
doom-wad-shareware                  Shareware game files for the 3D game Doom
fglrx-control                       control panel for the non-free ATI/AMD RadeonHD displa
fglrx-driver                        non-free ATI/AMD RadeonHD display driver
fglrx-modules-dkms                  dkms module source for the non-free ATI/AMD RadeonHD d
fglrx-source                        kernel module source for the non-free ATI/AMD RadeonHD
firmware-atheros                    Binary firmware for Atheros wireless cards
firmware-bnx2                       Binary firmware for Broadcom NetXtremeII
firmware-bnx2x                      Binary firmware for Broadcom NetXtreme II 10Gb
firmware-brcm80211                  Binary firmware for Broadcom 802.11 wireless cards
firmware-intelwimax                 Binary firmware for Intel WiMAX Connection
firmware-ipw2x00                    Binary firmware for Intel Pro Wireless 2100, 2200 and
firmware-ivtv                       Binary firmware for iTVC15-family MPEG codecs (ivtv an
firmware-iwlwifi                    Binary firmware for Intel Wireless cards
firmware-libertas                   Binary firmware for Marvell Libertas 8xxx wireless car
firmware-linux                      Binary firmware for various drivers in the Linux kerne
firmware-linux-nonfree              Binary firmware for various drivers in the Linux kerne
firmware-qlogic                     Binary firmware for QLogic IBA7220, QLA1xxx, ISP2xxx a
firmware-ralink                     Binary firmware for Ralink wireless cards
firmware-realtek                    Binary firmware for Realtek wired and wireless network
libfglrx                            non-free ATI/AMD RadeonHD display driver (runtime libr
nikto                               web server security scanner
unrar                               Unarchiver for .rar files (non-free version)
w64codecs                           win64 binary codecs
zd1211-firmware                     Firmware images for the zd1211rw wireless driver
            Contrib packages installed on deusexmachina
dosemu                              DOS Emulator for Linux
game-data-packager                  Installer for game data files
glx-alternative-fglrx               allows the selection of FGLRX as GLX provider
glx-alternative-mesa                allows the selection of MESA as GLX provider
glx-diversions                      prepare for using accelerated GLX implementations from
nvidia-installer-cleanup            cleanup after driver installation with the nvidia-inst
virtualbox-guest-dkms               x86 virtualization solution - guest addition module so
virtualbox-guest-utils              x86 virtualization solution - non-X11 guest utilities
virtualbox-guest-x11                x86 virtualization solution - X11 guest utilities
  26 non-free packages, 1.3% of 2035 installed packages.
  9 contrib packages, 0.4% of 2035 installed packages.

Have a Cow say something in your terminal. Type sudo apt-get install cowsay and then execute it to see something cool.

homer@deusexmachina ~ $ cowsay `/bin/date`
< Tuesday 15 July 23:01:47 EST 2014 >
        \   ^__^
         \  (oo)\_______
            (__)\       )\/\
                ||----w |
                ||     ||

Even more awesome Linux shell tricks.

No comments have been made. Use this form to start the conversation :)

Leave a Reply