Skip to content

Instantly share code, notes, and snippets.

@raging
Last active May 29, 2016 14:31
Show Gist options
  • Save raging/3859031 to your computer and use it in GitHub Desktop.
Save raging/3859031 to your computer and use it in GitHub Desktop.
My personal linux setup preferences
https://github.com/marten-cz/casperjs-deb --
sudo add-apt-repository ppa:martin.malek/testing && sudo apt-get update && sudo apt-get install casperjs
tep 1: Installing PhantomJS
- Download the latest source
wget http://phantomjs.googlecode.com/files/phantomjs-1.8.2-linux-x86_64.tar.bz2
- Extract the archive
tar -xvf phantomjs-1.8.2-linux-x86_64.tar.bz2
- Move the extracted folder to a proper location:
sudo mv phantomjs-1.8.2-linux-x86_64 /usr/local/src/phantomjs
- Create a symbolic link so we can just type “phantomjs” when we want to use “the phantom”
sudo ln -sf /usr/local/src/phantomjs/bin/phantomjs /usr/local/bin/phantomjs
- Check if it’s working
phantomjs --version
If you see the current PhantomJS version you can proceed with installing CasperJS.
Step 2: Installing CasperJS
- Enter a proper location to avoid moving the extracted files:
cd /usr/local/src/
- Get the source from the official git repository:
sudo git clone git://github.com/n1k0/casperjs.git
- Create symbolic link
sudo ln -sf /usr/local/src/casperjs/bin/casperjs /usr/local/bin/casperjs
- Check if it’s working
casperjs --version
curl -sS https://getcomposer.org/installer | php
mv composer.phar /usr/local/bin/composer
sudo apt-add-repository -y ppa:teejee2008/ppa
sudo apt-get update
sudo apt-get install conky conky-manager
sudo add-apt-repository ppa:finalterm/daily
sudo apt-get update
sudo apt-get install finalterm
Ubuntu Theme
To install Ming theme on Ubuntu/Linux Mint open Terminal (Press Ctrl+Alt+T) and copy the following commands in the Terminal:
Terminal Commands:
sudo add-apt-repository ppa:noobslab/themes
sudo apt-get update
sudo apt-get install ming-theme
sudo add-apt-repository ppa:gencfsm && sudo apt-get update && sudo apt-get install gnome-encfs-manager
sudo npm install -g grunt-cli
grunt
sudo apt-get install python-software-properties
sudo add-apt-repository ppa:chris-lea/node.js
sudo apt-get update
sudo apt-get install nodejs
Node Version Manager-
curl https://raw.github.com/creationix/nvm/master/install.sh | sh
To download, compile, and install the latest v0.10.x release of node, do this:
nvm install 0.10
And then in any new shell just use the installed version:
nvm use 0.10
Or you can just run it:
nvm run 0.10
If you want to see what versions are installed:
nvm ls
If you want to see what versions are available to install:
nvm ls-remote
To restore your PATH, you can deactivate it.
nvm deactivate
To set a default Node version to be used in any new shell, use the alias 'default':
nvm alias default 0.10
sudo apt-get install build-essential openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev automake libtool bison subversion pkg-config libgdbm-dev libffi-dev libreadline-dev
#******#
Edit .zshrc - PATH=/some/path -> PATH=$PATH:/some/path
#******#
curl -L https://get.rvm.io | bash -s stable
echo 'source ~/.rvm/scripts/rvm' >> ~/.bash_aliases && bash
rvm install 1.9.3
rvm use 1.9.3 --default
rvm rubygems current

###Making a script run from shell shortcut

  • First ensure the shell script is executable. -- chmod u+x,g+x script.sh
  • Then, edit your .zshrc file like following: -- alias commandtorun='/home/user/script.sh'
  • restart terminal
-> Chrome (Google.com/chrome)
-> Lightread
sudo add-apt-repository ppa:cooperjona/lightread
sudo apt-get update
sudo apt-get install lightread
-> Cairo (Software Center)
//ZSH
// https://github.com/robbyrussell/oh-my-zsh/blob/master/README.textile
sudo apt-get install zsh git git-core curl vim lsb-release scrot
curl -L https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh | sh
chsh -s /bin/zsh
//VIM spf13
//https://github.com/spf13/spf13-vim/blob/3.0/README.markdown
sudo apt-get install vim
curl http://j.mp/spf13-vim3 -L -o - | sh
//Solarized
//https://github.com/altercation/vim-colors-solarized
cd ~/.vim/bundle
git clone git://github.com/altercation/vim-colors-solarized.git
mv vim-colors-solarized ~/.vim/bundle/
//GIT
git config --global color.ui true
git config --global user.name "Raging"
git config --global user.email "myemailwastakenbysomeasshol@gmail.com"
ssh-keygen -t rsa -C "myemailwastakenbysomeasshol@gmail.com"
//Archey
sudo apt-get install lsb-release scrot
wget http://github.com/downloads/djmelik/archey/archey-0.2.8.deb
sudo dpkg -i archey-0.2.8.deb
||Edit .zshrc ADD** "archey"
//Sublime Text 2
sudo add-apt-repository ppa:webupd8team/sublime-text-2
sudo apt-get update
sudo apt-get install sublime-text
::Package Control::
//http://wbond.net/sublime_packages/package_control/installation
Installation is through the Sublime Text 2 console. This is accessed via the ctrl+` shortcut. Once open, paste the following command into the console:
import urllib2,os; pf='Package Control.sublime-package'; ipp=sublime.installed_packages_path(); os.makedirs(ipp) if not os.path.exists(ipp) else None; urllib2.install_opener(urllib2.build_opener(urllib2.ProxyHandler())); open(os.path.join(ipp,pf),'wb').write(urllib2.urlopen('http://sublime.wbond.net/'+pf.replace(' ','%20')).read()); print 'Please restart Sublime Text to finish installation'
To Use - ctrl+shift+p (Windows, Linux) or cmd+shift+p (OS X)
::Packages::
Fetch
-> Fetch Manage
-> Gist
-> Git
-> Node
-> Alignment
-> PHPBeautifier
-> Tag
//Java
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer
//Gimp
sudo add-apt-repository ppa:otto-kesselgulasch/gimp
sudo apt-get update
sudo apt-get install gimp
sudo apt-get install tasksel
sudo tasksel
ssh-keygen -t rsa -b 2048
ssh-copy-id id@server
//Fetch.Sublime-settings
{
"files":
{
"jquery": "http://code.jquery.com/jquery.min.js"
},
"packages":
{
"html5_boilerplate": "https://github.com/h5bp/html5-boilerplate/zipball/master",
"codeigniter": "http://codeigniter.com/download.php"
}
}
sudo add-apt-repository ppa:upubuntu-com/gtk3
sudo apt-get update
sudo apt-get install gnome-tweak-tool
sudo apt-get install clearnix renix delorean-dark-theme win2-7-remix-theme zukiwi gnomishgray-theme mediterranean-theme darkmint-theme malys-rough-theme delorean-varnam-theme
Objectives:
Install VirtualBox 4.2.2 in Ubuntu 12.10
Enjoy!
To get started, press Ctrl – Alt – T on your keyboard to open the terminal. When it opens, copy and paste the commands below to add its software repository’s key.
wget -q http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc -O- | sudo apt-key add -
Next, copy and paste the commands below to add its repository.
sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian $(lsb_release -sc) contrib" >> /etc/apt/sources.list'
Finally, run the commands below to update your system and install VirtualBox
sudo apt-get update && sudo apt-get install virtualbox-4.2
sudo apt-get install youtube-dl ffmpeg libavcodec-extra-53
gedit youtube2mp3
...and paste the following script:
x=~/.youtube-dl-$RANDOM-$RANDOM.flv
youtube-dl --output=$x --format=18 "$1"
ffmpeg -i $x -acodec libmp3lame -ac 2 -ab 128k -vn -y "$2"
rm $x
Save and close gedit. Now install the script somewhere easily accessible.
sudo install youtube2mp3 /usr/local/bin
Now you can convert youtube videos into mp3 files by using the following command (including the double quotes):
youtube2mp3 "youtube-link" "mp3-file.mp3"
youtube2mp3 "youtube-link" "mp3-file.mp3" > /dev/null
youtube2mp3 "youtube-link" "mp3-file.mp3" > /dev/null &
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment