Skip to content

Instantly share code, notes, and snippets.

@v-thomp4
v-thomp4 / gist:27daf37632a220cf9043
Last active August 29, 2015 14:22
eos freya install
# Install elementary Tweaks
sudo add-apt-repository ppa:mpstark/elementary-tweaks-daily
sudo apt-get update
sudo apt-get install elementary-tweaks
# Install numix-circle icon
sudo apt-add-repository ppa:numix/ppa
sudo apt-get update
sudo apt-get install numix-icon-theme-circle
# user web web;
worker_processes auto;
pid /var/run/nginx.pid;
events {
worker_connections 8192;
multi_accept on;
}
@v-thomp4
v-thomp4 / gist:39aa8e5c14a669d4df6d
Last active August 29, 2015 14:21
Install vim ubuntu 14.04
##
## Setup VIM
##
sudo apt-get install -y vim-gnome ruby-dev
git clone --recursive https://github.com/ravishi/dotvim "$HOME/.vim"
cd "$HOME/.vim/bundle/command-t/ruby/command-t"
ruby extconf.rb && make
@v-thomp4
v-thomp4 / gist:cf4e893b559c7ce7b599
Created March 27, 2015 07:12
Run a cron job every minute only on specific hours
*/1 11,16,21 * * * COMMAND

Traditional (inherited from Unix) cron format consists of five fields separated by white spaces:

*    *    *    *    *  command to be executed
┬    ┬    ┬    ┬    ┬
│ │ │ │ │
@v-thomp4
v-thomp4 / gist:04da40931d4dd4868e85
Created March 19, 2015 16:31
Disable Warning Screen Appears When Pasting Sudo Commands in elementary OS Freya Terminal
turned off through gsettings or dconf at
org.pantheon.terminal.settings.unsafe-paste-alert.
sudo ln -s /usr/lib64/cups/backend/ccp /usr/lib/cups/backend
sudo ln -s /usr/lib64/cups/filter/pstocapt /usr/lib/cups/filter
sudo ln -s /usr/lib64/cups/filter/pstocapt2 /usr/lib/cups/filter
sudo ln -s /usr/lib64/cups/filter/pstocapt3 /usr/lib/cups/filter
#!/bin/bash
function f() {
sleep "$1"
echo "$1"
}
while [ -n "$1" ]
do
f "$1" &
shift
done
@v-thomp4
v-thomp4 / gist:61249c1f3c8483a2965b
Last active August 29, 2015 14:10
Installing Broadcom Wireless Drivers
Uninstall the bcmwl-kernel-source package by issuing the following command on a terminal:
sudo apt-get remove bcmwl-kernel-source
Make sure that the firmware-b43-installer and the b43-fwcutter packages are installed (of course you will need internet by others means):
sudo apt-get install firmware-b43-installer b43-fwcutter
Type into a terminal:
sudo sed -i -r 's/(\[.+\])$/\1\nStartupWMClass=Google-chrome-stable/g' /usr/share/applications/google-chrome.desktop
@v-thomp4
v-thomp4 / maintenance.html
Last active November 1, 2015 10:53 — forked from pitch-gist/gist:2999707
maintenance page
<!doctype html>
<title>Site Maintenance</title>
<style>
body { text-align: center; padding: 150px; }
h1 { font-size: 50px; }
body { font: 20px Helvetica, sans-serif; color: #333; }
article { display: block; text-align: left; width: 650px; margin: 0 auto; }
a { color: #dc8100; text-decoration: none; }
a:hover { color: #333; text-decoration: none; }
</style>