Skip to content

Instantly share code, notes, and snippets.

View jorgemario's full-sized avatar

Jorge M. Gómez jorgemario

View GitHub Profile
var Col = require('react-bootstrap/lib/Col')
var PageHeader = require('react-bootstrap/lib/PageHeader')
var React = require('react')
var Row = require('react-bootstrap/lib/Row')
var {connect} = require('react-redux')
var {reduxForm} = require('redux-form')
var DateInput = require('./DateInput')
var FormField = require('./FormField')
var LoadingButton = require('./LoadingButton')
@jorgemario
jorgemario / 0_reuse_code.js
Last active August 29, 2015 14:26
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@jorgemario
jorgemario / ubuntu-hibernate
Created December 4, 2014 21:34
Ubuntu enable Hibernate
sudo vim /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla
[Re-enable hibernate by default]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=yes
Save and restart.
#!/bin/bash
function msg {
# Description:
# This function echoes-with-colors the arguments passed in
# Usage:
# msg 'whatever you want to print :)'
echo -e '\033[33m\033[44m'$@'\033[0m'
}
@jorgemario
jorgemario / gist:de5d7740eb2fa81017f7
Last active August 29, 2015 14:07
mac setup with brew
http://lapwinglabs.com/blog/hacker-guide-to-setting-up-your-mac
binaries=(
rename
sshfs
trash
node
tree
ack
hub
@jorgemario
jorgemario / dump.sh
Created October 3, 2014 14:44
Dum postgres database
pg_dump --file=/usr/local/pgbackups/imsprod.20140910.pgdump --no-tablespaces --format=c --verbose --schema=ims imsproddb
@jorgemario
jorgemario / mac_ntfs.bash
Last active August 29, 2015 14:02
Mount ntfs volumes in mac with write support
# from:
# http://osxdaily.com/2013/10/02/enable-ntfs-write-support-mac-os-x/
$ diskutil info /Volumes/DRIVENAME | grep UUID
# use UUID to reference the drive
$ sudo echo "UUID=ENTER_UUID_HERE none ntfs rw,auto,nobrowse" >> /etc/fstab
# or, use the label
$ sudo echo "LABEL=WINDOWS8 none ntfs rw,auto,nobrowse" >> /etc/fstab
@jorgemario
jorgemario / clam_install.bash
Created May 28, 2014 16:37
ClamAV install on Ubuntu
$ sudo apt-get install clamav-daemon
$ freshclam
$ /etc/init.d/clamav-daemon start
@jorgemario
jorgemario / .gitconfig
Last active August 29, 2015 14:01
git config
[user]
name = Jorge M Gomez C
email = jorgemario@gmail.com
[core]
excludesfile = /home/jorge/.gitignore_global
[color]
branch = auto
diff = auto
interactive = auto
status = auto
# http://gitready.com/beginner/2009/03/09/remote-tracking-branches.html
git config branch.autosetupmerge true
git checkout -b branch_name origin/branch_name
# sample
git fetch origin hotfix/576
> * branch hotfix/576 -> FETCH_HEAD
> * [new branch] hotfix/576 -> origin/hotfix/576
# setup the remote branch as a local branch