This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# requires https://bitbucket.org/zhemao/bitbucket-cli | |
for folder in `ls -1` | |
do | |
[[ -d $folder ]] && cd $folder && git init && git add . && git commit -am "Initial Commit" && bitbucket create_from_local && cd .. | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
___ ___ | |
/ /\ /__/\ | |
/ /::\ \ \:\ | |
/ /:/\:\ \__\:\ | |
/ /:/ \:\ ___ / /::\ | |
/__/:/ \__\:\ /__/\ /:/\:\ | |
\ \:\ / /:/ \ \:\/:/__\/ | |
\ \:\ /:/ \ \::/ | |
\ \:\/:/ \ \:\ | |
\ \::/ \ \:\ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
** llist.c for tools in /home/diallo_e/src/projets/zappy/src/tools | |
** | |
** Made by aliou diallo | |
** Login <[email protected]> | |
** | |
** Started on Sun May 05 09:12:36 2013 aliou diallo | |
** Last update Sun May 05 09:29:49 2013 aliou diallo | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
while true | |
do | |
eject | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# https://github.com/Goles/Battery | |
# https://github.com/erikw/tmux-powerline/blob/master/segments/battery.sh | |
linux_get_bat () | |
{ | |
bf=$(cat $BAT_FULL) | |
bn=$(cat $BAT_NOW) | |
BAT=`echo "100 * $bn / $bf" | bc` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if has("win32") | |
if filereadable("_vimrc.win.vim") | |
source _vimrc.win.vim | |
endif | |
endif | |
if has("unix") | |
if system('uname')=~'Darwin' | |
if filereadable("vimrc.mac.vim") | |
source vimrc.mac.vim | |
endif |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(* val map_reduce : int list -> int list list = <fun> *) | |
let map_reduce lst = | |
let rec partition acc = function | |
| 0 -> acc | |
| x -> partition ((x mod 10) :: acc) (x / 10) | |
in let rec map acc = function | |
| [] -> List.rev acc | |
| h :: tl -> | |
if h > 10 then map ((partition [] h) :: acc) tl | |
else map ((h :: [] ) :: acc) tl |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# curl -fsSL https://raw.github.com/gist/5309124 | sh | |
echo "Renaming current vim files." | |
mv ~/.vim ~/.vim-bkp 2>/dev/null | |
mv ~/.vimrc ~/.vimrc-bkp 2>/dev/null | |
mv ~/.gvimrc ~/.gvimrc-bkp 2>/dev/null | |
mv ~/.dotvim ~/.dotvim-bkp 2>/dev/null | |
echo "Downloading files. (The part where you ask Aliou to come)" | |
git clone https://github.com/aliou/dotvim.git ~/.dotvim |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[alias] | |
boom = !"git push origin master && git push heroku master" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// http://unwieldy.net | |
var bday = new Date(1992, 11, 17, 07, 27), | |
ones = ['', 'one', 'two', 'three', 'four', 'five', | |
'six', 'seven', 'eight', 'nine'], | |
tens = ['', '', 'twenty', 'thirty', 'forty', 'fifty', 'sixty', | |
'seventy', 'eighty', 'ninety']; | |
var days = (new Date() - bday) / 1000 / 60 / 60 / 24, | |
hours = days % 24 % 365.25; |