Skip to content

Instantly share code, notes, and snippets.

View eroullit's full-sized avatar

Emmanuel Roullit eroullit

  • GitHub Staff
  • Germany
  • 18:38 (UTC +01:00)
View GitHub Profile
@eroullit
eroullit / gist:1250603
Created September 29, 2011 11:58
git pre-commit indent hook
#!/bin/sh
#
# Hook used to indent all source files before commiting
#
INDENT="$(git config hooks.indent)"
if test ! -x "$INDENT"
then
echo "Unable to find indent executable on the configuration."
echo
@eroullit
eroullit / csv2gnuplot.sh
Created October 25, 2011 11:13
CSV -> GNUplot conversion script
#!/bin/bash
#
# This transforms a CSV file into a gnuplot file.
# use option '-h' to display a help screen for all options.
#
# FracPete
# the usage of this script
function usage()
{
@eroullit
eroullit / pdfmerge
Created January 8, 2013 21:21
merge multiple pdf into one
$ gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=merged.pdf source1.pdf source2.pdf
set nocompatible
set cindent
set guioptions-=T
set ruler
set nohls
set incsearch
set number
set nopaste
set autoindent
set copyindent
@eroullit
eroullit / git-push-chunk.sh
Created July 4, 2023 14:18
Git Push chunk by chunk
#!/bin/bash
set -eu
# Name of the remote (usually origin)
REMOTE=origin
# Find the name of the current branch
BRANCH=$(git rev-parse --abbrev-ref HEAD)
# Push commit in batches of size.
# The larger the batch size, the larger the amount of data will