Skip to content

Instantly share code, notes, and snippets.

View ricardogarfe's full-sized avatar
enjoy

Ricardo García Fernández ricardogarfe

enjoy
View GitHub Profile
@alexschwartz
alexschwartz / gist:912787
Created April 10, 2011 22:14
Ask Jenkins via json using jquery
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Seitenr?nder - marginwidth, marginheight, topmargin, leftmargin</title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready(function(){
var baseUrl;
@iamkristian
iamkristian / deploy.sh
Created June 16, 2011 07:12
How to deploy to oc4j with continuous integration tools - like hudson
#!/bin/bash
ROOTDIR=.
if [[ $1 = "hudson" ]] ; then
ROOTDIR="`pwd`/<ear-project-dir>"
else
ROOTDIR="."
fi
TARGET="$ROOTDIR/target"
ID="$ROOTDIR/src/main/cert/id_dsa"
USER=<username>@<hostname>
@dnagir
dnagir / import.rb
Created February 8, 2012 04:41 — forked from baldowl/import.rb
Import a blogger archive to jekyll (octopress version, allows quotes in titles)
require 'rubygems'
require 'nokogiri'
require 'fileutils'
require 'date'
require 'uri'
# usage: ruby import.rb my-blog.xml
# my-blog.xml is a file from Settings -> Basic -> Export in blogger.
data = File.read ARGV[0]
@justincampbell
justincampbell / after.sh
Created March 1, 2013 17:45
Jenkins + GitHub Commit Status API
if [[ $BUILD_STATUS == "success" ]]
then
export STATUS="success"
else
export STATUS="failure"
fi
curl "https://api.github.com/repos/justincampbell/my_repo/statuses/$GIT_COMMIT?access_token=abc123" \
-H "Content-Type: application/json" \
-X POST \
@prwhite
prwhite / Makefile
Last active October 2, 2024 03:13
Add a help target to a Makefile that will allow all targets to be self documenting
# Add the following 'help' target to your Makefile
# And add help text after each target name starting with '\#\#'
help: ## Show this help.
@fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//'
# Everything below is an example
target00: ## This message will show up when typing 'make help'
@echo does nothing
@thestonefox
thestonefox / thestonefox-vimrc
Last active May 29, 2019 07:02
Basic .vimrc with pathogen, solarized theme, nerdtree
execute pathogen#infect()
syntax on
set number
set expandtab
set tabstop=2
set background=dark
set t_Co=256
let g:solarized_termcolors=256
let g:solarized_termtrans=1
@staltz
staltz / introrx.md
Last active November 14, 2024 11:27
The introduction to Reactive Programming you've been missing
@rinze
rinze / build_dataset.py
Last active January 15, 2019 10:51
Parser para los archivos .DAT del Ministerio del Interior y el archivo de códigos de municipios del INE y código en R para gráficas simples.
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import csv
import codecs
import cStringIO
import os
from collections import namedtuple
def getParties(parties_file):
@Jaza
Jaza / Private-pypi-howto
Last active July 2, 2023 16:24
Guide for how to create a (minimal) private PyPI repo, just using Apache with directory autoindex, and pip with an extra index URL.
*
@ricardogarfe
ricardogarfe / git-move-commits-to-a-branch.md
Last active October 14, 2019 11:37
Move git commmits to a new branch

Move commmits between branches

From this:

master A - B - C - D - E

Move C - D - E to a new branch: