Skip to content

Instantly share code, notes, and snippets.

@julionc
julionc / 00.howto_install_phantomjs.md
Last active March 24, 2025 17:27
How to install PhantomJS on Debian/Ubuntu

How to install PhantomJS on Ubuntu

Version: 1.9.8

Platform: x86_64

First, install or update to the latest system software.

sudo apt-get update
sudo apt-get install build-essential chrpath libssl-dev libxft-dev
@rxaviers
rxaviers / gist:7360908
Last active April 30, 2025 10:51
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
@plentz
plentz / nginx.conf
Last active April 30, 2025 08:40
Best nginx configuration for improved security(and performance)
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@robmiller
robmiller / .gitconfig
Created July 17, 2013 07:52
Some useful Git aliases that I use every day
#
# Working with branches
#
# Get the current branch name (not so useful in itself, but used in
# other aliases)
branch-name = "!git rev-parse --abbrev-ref HEAD"
# Push the current branch to the remote "origin", and set it to track
# the upstream branch
publish = "!git push -u origin $(git branch-name)"
@twalker
twalker / mixer.js
Last active December 17, 2015 23:09
utility for mixing methods into objects and backbone klasses.
/**
* Mixer of mixins.
* A utility to copy functionality from mixins to objects.
*/
define(['underscore'], function(lodash){
// Monkey patch a destination object (i.e. Model.prototype, View.prototype, etc.)
// by combining member values that are object literals (e.g. events, defaults),
// functions (e.g. initialize), or arrays (e.g.relations).
// Heavily inspired by: https://github.com/onsi/cocktail
@karlwestin
karlwestin / collectionandmodel.js
Created January 24, 2013 20:50
example with the parse method, for nesting a backbone collection inside a model
//example data format:
var data = {
"1": [ { data: 10 }, { data: 11}, { data: 12}],
"2": value,
"3": value2
};
var MyModel = Backbone.Model.extend({
constructor: function() {
arguments[1] = arguments[1] || {}; // ensure there's 'options'
arguments[1].parse = true; // this model should always be parsed on intialization
@twalker
twalker / sublimetext_useful_shortcuts_pc.md
Last active July 10, 2021 11:34
A fork of useful sublime text keyboard shortcuts. Using markdown and making more readable from github.

Sublime Text - Useful Shortcuts (linux)

Sublime Text 3 documentation
= Right Mouse Button
= Left Mouse Button
= Shift
= Delete
= Enter
←↑→↓ = Arrow keys

Editing

@dcunited001
dcunited001 / .Xmodmap
Created December 2, 2012 12:48
Configure Hyper Key in Linux with Xmodmap
! This sets Caps to Escape
! Then sets Escape to Hyper
! save this file to: /etc/X11/xinit/Xmodmaprc
! then call in: /etc/X11/xinit/xinitrc
! with: xmodmap /etc/X11/xinit/Xmodmaprc
! ASUS UL50V
clear Lock
@twalker
twalker / destroyable.js
Created October 31, 2012 18:52
zombie killer: a backbone view mixin
/**
* View mixin to properly cleanup dom, backbone, and custom event listeners.
* A view zombie killer.
* e.g. myView.destroy(); OR destroyable.destroy.call(myView);
*
* CAVEAT:
* Although custom events will stop triggering, custom event listeners
* are not automatically removed since the binding context is unknown. e.g.
* otherView.on('foo', thisView.doSomething, thisView);
*
@tbranyen
tbranyen / backbone.cacheit.js
Created October 25, 2012 02:31
Cache Backbone Model and Collection fetch calls with a deferred, simple and intuitive.
/*!
* backbone.cacheit.js v0.1.0
* Copyright 2012, Tim Branyen (@tbranyen)
* backbone.cacheit.js may be freely distributed under the MIT license.
*/
(function(window) {
"use strict";
// Localize global dependency references.