Skip to content

Instantly share code, notes, and snippets.

@pyrech
Last active October 15, 2015 11:46
Show Gist options
  • Save pyrech/484bb830da2fc4c1a8fe to your computer and use it in GitHub Desktop.
Save pyrech/484bb830da2fc4c1a8fe to your computer and use it in GitHub Desktop.
Ubuntu tweaks
[push]
default = current
[fetch]
prune = true
[core]
excludesfile = /home/loick/.gitignore_global
[rebase]
autosquash = true
[alias]
st = status
df = diff
co = checkout
ci = commit
br = branch
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative
[branch]
autosetuprebase = always

System

Swap

Change swap to be used later

http://doc.ubuntu-fr.org/swap#regler_le_declenchement_du_swap

Shell

oh-my-zsh

  • Install zsh: sudo apt-get install zsh

  • Instal git: sudo apt-get install git-core

  • Install oh-my-zsh and change default shell to zsh: wget --no-check-certificate https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O - | sh

  • Customize zsh by editing ~/.zshrc (here I just updated the enabled plugins)

...
plugins=(common-aliases composer debian git symfony2)
...
  • Your shell will use zsh after a logout/login your session

Privacy

Remove tracking in Dash (see fixubuntu.com)

wget -q -O - https://fixubuntu.com/fixubuntu.sh | bash

Tools

Enable multiple workspaces (2 * 2)

gsettings set org.compiz.core:/org/compiz/profiles/unity/plugins/core/ hsize 2
gsettings set org.compiz.core:/org/compiz/profiles/unity/plugins/core/ vsize 2

MacOS like touchpad gestures (couldn't make this working on Ubuntu 14.04 so probably not complete )': )

  • Install touchegg: sudo apt-get install touchegg

  • Install geis (formely named uTouch before 12.10) sudo apt-get install geis-tools

  • Run touchegg (it will create the default ~/.config/touchegg/touchegg.conf): touchegg

Git

  • Create a .gitignore_global file: touch ~/.gitignore_global

  • Add some patterns to exclude into it:

deps.lock
.idea
# OS X
.DS_Store
# Thumbnails
._*
# Files that might appear on external disk
.Spotlight-V100
.Trashes
.buildpath
.project
.settings

PHP

Custom conf for php:

sudo nano /etc/php5/my_conf.ini

date.timezone = Europe/Paris
phar.readonly = Off 
session.gc_maxlifetime = 72000;
xdebug.file_link_format=pstorm://%%f:%%l

sudo ln -s /etc/php5/my_conf.ini /etc/php5/apache2/conf.d/20-my_conf.ini

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