Skip to content

Instantly share code, notes, and snippets.

@luc0
Last active October 30, 2017 13:05
Show Gist options
  • Save luc0/7b3573040e4ca0cbd2d5f501e6ccdc04 to your computer and use it in GitHub Desktop.
Save luc0/7b3573040e4ca0cbd2d5f501e6ccdc04 to your computer and use it in GitHub Desktop.
Ubuntu command line basics

Install app (.run)

chmod +x some-app.run ( is used to set the file as executable )

sudo ./some-app.run

Install package (.deb)

sudo dpkg -i DEB_PACKAGE or multiple: sudo dpkg -i *.deb

( Once installed programs are usually found in /usr/bin, named after what was depackaged )

If dpkg reports an error due to dependency problems, you can run: sudo apt-get install -f (to download the missing dependencies and configure everything.) If that reports an error, you'll have to sort out the dependencies yourself by following for example https://askubuntu.com/questions/140246/how-do-i-resolve-unmet-dependencies-after-adding-a-ppa

tar.gz

sudo tar -xzf postman.tar.gz -C /opt
rm postman.tar.gz 
// now, create simbolic link
sudo ln -s /opt/Postman/Postman /usr/bin/postman
// lo abris con
postman

tar.xz

sudo apt-get install xz-utils
unxz tsetup.1.1.23.tar.xz

Remove package (.deb)

sudo dpkg -r PACKAGE_NAME

Install dependencies

sudo apt-get install

Get permissions info

stat -c "%a %n" FILENAME

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment