Skip to content

Instantly share code, notes, and snippets.

View xeBuz's full-sized avatar
🧉
Converting mate into technical debts

Jesús Roldán xeBuz

🧉
Converting mate into technical debts
View GitHub Profile
@helderco
helderco / db-open
Created October 6, 2015 14:51
Script to open a mysql database in Sequel Pro from a service in docker-compose.
#!/bin/bash
set -e
show_help() {
cat << EOF
Usage: ${0##*/} [-u USER] [-p PASS] [-P PORT] [-H HOST] [DATABASE]
${0##*/} -h
Open a standard connection in Sequel PRO.

Command Name

Description of the command.

Usage

Choose your flavor:

$ php bin/Hermes.php --execute CommandName [--option1="..."] [--option2="..."] [--optionN]
@eguneys
eguneys / gesture.js
Created August 31, 2014 11:37
A Gesture Manager for Phaser.
'use strict';
define(['phaser'], function(Phaser) {
function Gesture(game) {
this.game = game;
this.swipeDispatched = false;
this.holdDispatched = false;
this.isTouching = false;
@brenopolanski
brenopolanski / install-firefox-nightly.md
Created July 30, 2014 00:34
Install Firefox Nightly in Ubuntu via PPA

via: http://www.webupd8.org/2011/05/install-firefox-nightly-from-ubuntu-ppa.html

Add the Mozilla Daily PPA (available for Ubuntu 11.04, 10.10 and 10.04) and install Firefox Nightly using the commands below:

$ [sudo] add-apt-repository ppa:ubuntu-mozilla-daily/ppa
$ [sudo] apt-get update
$ [sudo] apt-get install firefox-trunk

Since this is a daily builds PPA, it's nowhere near stable so use it at your own risk!

@havencruise
havencruise / setup_ec2_py27_mod_wsgi.sh
Last active June 9, 2018 01:55
Django + Python2.7 + Apache setup for AWS EC2 with mod_wsgi A how-to on setting up Python 2.7, Django and mod_wsgi, and using Python 2.7 with virtual_env(which is the right thing to do) on Amazon EC2 instances. .. .. .. Why? - Because Amazon EC2 instances usually come with Python 2.6 by default.
# You will need to run these with superuser permissions.
# Either prefix `sudo` to all commands, or switch user
# Be very careful when you switch user
sudo su - root
# Update all the packages
yum update
# Install the basics - python27, gcc, svn, git, httpd, make, uuid
@chids
chids / 256kb.json
Last active March 18, 2024 16:07
Roughly 256kb of indented JSON i.e. AWS SNS and AWS SQS message limit and a hint not to publish pretty printed JSON ;)
[
{
"id": 0,
"guid": "1b8c3019-c0b6-44f9-b35c-5b1b2729551a",
"isActive": true,
"balance": "$3,163.00",
"picture": "http://placehold.it/32x32",
"age": 32,
"name": "Saunders Sosa",
"gender": "male",
@gnarf
gnarf / ..git-pr.md
Last active April 12, 2024 22:00
git pr - Global .gitconfig aliases for Pull Request Managment

Install

Either copy the aliases from the .gitconfig or run the commands in add-pr-alias.sh

Usage

Easily checkout local copies of pull requests from remotes:

  • git pr 4 - creates local branch pr/4 from the github upstream(if it exists) or origin remote and checks it out
  • git pr 4 someremote - creates local branch pr/4 from someremote remote and checks it out
@jofralogo
jofralogo / responsiveMixinsF4.sass
Last active December 15, 2015 21:18
Useful responsive SCSS mixins for Foundation 4.
/*
_______
These simple SCSS/SASS mixins for Foundation 4 are made by me to deal with media-queries and have a clean code at the same time! ;)
****IMPORTANT****
Due to Foundation 4 uses mobile-first methodology, every $phone-"X" variable in these mixins defines the value for every screen size.
$desktop-"X" values overrides $phone-"X" values when the width of the window is 768px and above.
@iros
iros / API.md
Created August 22, 2012 14:42
Documenting your REST API

Title

<Additional information about your API call. Try to use verbs that match both request type (fetching vs modifying) and plurality (one vs multiple).>

  • URL

    <The URL Structure (path only, no root url)>

  • Method:

@jeremyworboys
jeremyworboys / media-fix.py
Created May 6, 2012 04:05
Python: Media fix is designed to re-factor media queries within the CSS outputted by SASS.
#!/usr/bin/python
"""
Media fix is designed to re-factor media queries within the CSS outputted by
SASS.
Usage: python media-fix.py style.css, ...
"""
import sys
import re