Skip to content

Instantly share code, notes, and snippets.

Avatar
🕸️

Alejandro Fernández Gómez afgomez

🕸️
View GitHub Profile
@afgomez
afgomez / colors.json
Last active Dec 9, 2018
Pizarra color palette
View colors.json
{
"black": "#040506",
// UI BGs
"grey1": "#08090b",
"grey2": "#101216",
"grey3": "#1c1f25",
// UI subtle
"grey4": "#3e424b",
View git-checkout-branch-fuzzy
#!/bin/bash
branch=`git branch -a | sed 's/^\*//; s/^[ \t]*//; /HEAD.*/d; /^remotes\/origin\/$/d' | fzf --height 40% --border --reverse --preview 'git log --color=always {} -10' | sed 's/remotes\/origin\///'`
if [[ $branch ]]; then
git checkout $branch
fi
View sth.js
/**
* @file Some description of the file
* @author Me
*/
import something from 'somewhere';
const SOMETHING = {
some: 'thing'
}
View virtualenv-auto-activate.sh
#!/bin/bash
# virtualenv-auto-activate.sh
#
# Adapted from https://gist.github.com/codysoyland/2198913
#
# Installation:
# Add this line to your .bashrc or .bash-profile:
#
# source /path/to/virtualenv-auto-activate.sh
#
@afgomez
afgomez / webpack3.config.js
Created May 19, 2018
Webpack 3 & 4 config equivalents
View webpack3.config.js
const path = require('path');
const webpack = require('webpack');
module.exports = {
entry: {
one: './src/one.js',
two: './src/two.js',
three: './src/three.js',
},
output: {
View keybase.md

Keybase proof

I hereby claim:

  • I am afgomez on github.
  • I am afgomez (https://keybase.io/afgomez) on keybase.
  • I have a public key ASCjWNVip-MxWrKQiDaldwKy0lni4ExvYmZSlv51veTG4Qo

To claim this, I am signing this object:

@afgomez
afgomez / ios7bottom.js
Last active Jan 1, 2016
jQuery plugin to ensure the bottom toolbars are always visible in iOS7
View ios7bottom.js
/**
* ios7bottom
*
* Listen to changes in safari window size to ensure the position:fixed
* elements are always visible.
*
* Usage
*
* $('#toolbar').ios7bottom();
*/
View gist:6282247
diff --git a/SublimeLinter.py b/SublimeLinter.py
index 1e4e670..529b5f0 100644
--- a/SublimeLinter.py
+++ b/SublimeLinter.py
@@ -39,7 +39,7 @@ DELAYS = (
# "alpha", "bright", "dark", "hard" and "simple"
MARK_THEMES = ('alpha', 'bright', 'dark', 'hard', 'simple')
# The path to the built-in gutter mark themes
-MARK_THEMES_PATH = os.path.join('..', 'SublimeLinter', 'gutter_mark_themes')
+MARK_THEMES_PATH = os.path.join('Packages', 'SublimeLinter', 'gutter_mark_themes')
@afgomez
afgomez / iterm_profile.sh
Created Jun 25, 2013
function to change iTerm2 color profile from the terminal
View iterm_profile.sh
#!/bin/bash
# Change the iterm2 profile programatically
function iterm_profile {
if [[ -z $1 ]]; then
profile="Default"
else
profile=$1
fi
@afgomez
afgomez / jquery.fn.js
Created Jun 11, 2013
quick template for jQuery plugins
View jquery.fn.js
(function($) {
$.fn.plugin = function() {
return this.each(function() {
var $this = $( this );
if ( !$this.data('plugin') ) {
$this.data( 'plugin', new Plugin(this) );
}
});
}