Skip to content

Instantly share code, notes, and snippets.

View bracke's full-sized avatar
🎯
Focusing

Bent Bracke bracke

🎯
Focusing
View GitHub Profile
@bracke
bracke / HideMousepointer.css
Created November 17, 2012 17:08
Hide mouse pointer
*{ cursor : url("/images/blank.cur"), none; }
@bracke
bracke / .bashrc
Created August 8, 2013 11:03
.bashrc
[ -n "$PS1" ] && source ~/.bash_profile
@bracke
bracke / .bash_profile
Last active December 20, 2015 19:29
.bash_profile
# Add `~/bin` to the `$PATH`
export PATH="$HOME/bin:$PATH"
export PATH="/usr/local/bin:$PATH"
export PATH="/usr/local/sbin:$PATH"
# Load the shell dotfiles, and then some:
# * ~/.path can be used to extend `$PATH`.
# * ~/.extra can be used for other settings you don’t want to commit.
for file in ~/.{path,bash_prompt,exports,aliases,functions,extra}; do
[ -r "$file" ] && source "$file"
@bracke
bracke / .bash_prompt
Last active December 20, 2015 19:29
.bash_prompt
# @gf3’s Sexy Bash Prompt, inspired by “Extravagant Zsh Prompt”
# Shamelessly copied from https://github.com/gf3/dotfiles
# Screenshot: http://i.imgur.com/s0Blh.png
if [[ $COLORTERM = gnome-* && $TERM = xterm ]] && infocmp gnome-256color >/dev/null 2>&1; then
export TERM=gnome-256color
elif infocmp xterm-256color >/dev/null 2>&1; then
export TERM=xterm-256color
fi
@bracke
bracke / .ackrc
Last active March 30, 2020 18:21
.ackrc
#ack is a tool like grep, designed for programmers with large trees of heterogeneous source code
#to install ack, see http://betterthangrep.com/
#to use ack, launch terminal (mac osx) and type 'ack <some_keywords>'
#ack will search all files in the current directory & sub-directories
#here's how I have my config file setup. this file is located on mac osx here
# ~/.ackrc
# Always sort the files
@bracke
bracke / prepare-commit-msg
Last active December 20, 2015 20:19
Git hook: prepare-commit-msg
#!/bin/sh
#
# Based on http://blog.bartoszmajsak.com/blog/2012/11/07/lazy-developers-toolbox-number-1-prepend-git-commit-messages/
#
BRANCH_NAME=$(git branch 2>/dev/null | grep -e ^* | tr -d ' *')
if [ -n "$BRANCH_NAME" ] && [ "$BRANCH_NAME" != "master" ]; then
echo "[$BRANCH_NAME] $(cat $1)" > $1
fi
@bracke
bracke / pre-commit
Created August 8, 2013 23:02
Git hook: pre-commit
#!/bin/sh
red='\x1B[0;31m'
green='\x1B[0;32m'
NC='\x1B[0m' # No Color
underline='\033[4m'
git stash -q --keep-index
# Test
# Make some possibly destructive commands more interactive.
alias rm='rm -i'
alias mv='mv -i'
alias cp='cp -i'
# Add some easy shortcuts for formatted directory listings and add a touch of color.
alias ll='ls -lF'
alias la='ls -alF'
alias ls='ls -F'
net.inet.tcp.rfc1323=1
kern.ipc.maxsockbuf=16777216
net.inet.tcp.sendspace=1048576
net.inet.tcp.recvspace=1048576
net.inet.tcp.slowstart_flightsize=4
@bracke
bracke / 0_reuse_code.js
Last active August 29, 2015 14:16
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console