Skip to content

Instantly share code, notes, and snippets.

@ClementGautier
ClementGautier / package.json
Last active January 8, 2019 12:24
Simple publish / subscribe Google Cloud Functions
{
"name": "nodejs-functions-pubsub",
"version": "0.0.1",
"dependencies": {
"@google-cloud/pubsub": "0.22.2",
"@google-cloud/logging": "^4.2.0"
}
}
PS1='[\[\033[1;32m\]\u@\h\[\033[0m\]][\[\033[1;33m\]\w\[\033[0m\]]$(__git_ps1 "[\[\033[1;31m\]%s\[\033[0m\]]")\$ '
@ClementGautier
ClementGautier / bash_aliases
Created February 3, 2012 09:34
My Bash Aliases
alias ls="ls --color"
alias ll="ls -lh"
alias df="df -h"
alias grep='grep --color=auto'
alias grep='grep --exclude-dir ".svn" --exclude tags'
alias untar="tar xvf"
alias ungz="gunzip"
alias unzip2="bzip2 -d"
@ClementGautier
ClementGautier / SVN Aliases
Created February 3, 2012 09:31
Aliases for svn for people who like Git
alias svnste="svn st --ignore-externals | grep -v '^X' | cut -d: -f2"
alias svnsti="svn status --ignore-externals | grep \"^? \""
alias svnst="echo \"Staged :\" && echo \"-\" && svnste && echo && echo \"Unstaged :\" && echo
\"--\" && svnsti"
@ClementGautier
ClementGautier / geo_barycentre.php
Created May 20, 2011 12:59
Trying to build a function that find the center of a Polygon defined by geo coordinates
<?php
$coords = array(
array('lat' => 2.125397, 'long' => 48.98255900000001),
array('lat' => 2.205048, 'long' => 48.620747),
array('lat' => 2.759857, 'long' => 48.769405),
array('lat' => 2.457733, 'long' => 49.171471),
);
// premier test