Skip to content

Instantly share code, notes, and snippets.

View vladikoff's full-sized avatar
🚀
🧇

Vlad Filippov vladikoff

🚀
🧇
View GitHub Profile
@tbranyen
tbranyen / jscs.json
Created February 10, 2014 19:43
My JSCS style configuration.
{
"maximumLineLength": 80,
"validateJSDoc": {
"checkParamNames": true,
"checkRedundantParams": true,
"requireParamTypes": true
},
@k2cCreations
k2cCreations / Red to White
Last active August 29, 2015 13:57
Lights will cycle from one side to the other, fading red to white, then back to red
First enter "shell" without (")
Second enter "sudo su" Without (")
ectool lightbar seq stop
ectool lightbar 4 00 00 00
while :
do
ectool lightbar 0 ff 00 00
@avolochenko
avolochenko / 00-pyspark-setup.py
Last active September 22, 2015 05:26
ipython spark 1.4.1 bootstrap (OSX)
import os
import sys
spark_home = os.environ.get('SPARK_HOME', None)
#if not spark_home:
# raise ValueError('SPARK_HOME environment variable is not set')
sys.path.insert(0, os.path.join(spark_home, 'python'))
sys.path.insert(0, os.path.join(spark_home, 'python/lib/py4j-0.8.2.1-src.zip'))
execfile(os.path.join(spark_home, 'python/pyspark/shell.py'))
@miketaylr
miketaylr / package.sh
Created October 29, 2010 18:14
Handy script for developing Opera extensions
#!/bin/bash
# zip up all the files in the current directory
if [ $1 ]; then
echo "Creating $1.oex"
zip -r $1.zip .
# rename the .zip file to an .oex file
mv $1.zip $1.oex
@lvbreda
lvbreda / client.js
Created July 31, 2012 22:16
Hacky routing
if (Meteor.is_client) {
var Router = Backbone.Router.extend({
routes: {
"" : "main",
":page": "main" //this will be http://your_domain/
},
main: function(page) {
document.body.innerHTML = "";
page = page?page:"index";
var frag = Meteor.ui.render(function () {
@deholic
deholic / meteor_twitter_auth.js
Created October 23, 2012 02:53
Prepare twitter oauth in Meteor 0.5.0
Meteor.startup(function() {
// check twitter authorize
var config = Accounts.loginServiceConfiguration.findOne({service: "twitter"});
if(!config) {
Accounts.loginServiceConfiguration.insert({
service: "twitter",
consumerKey: "YOUR_APP_CONSUMER_KEY",
secret: "YOUR_APP_CONSUMER_SECRET"
});
};
@max-mapper
max-mapper / readme.md
Last active October 30, 2015 03:05
node.js release questions

As a maintainer of native node add-on modules I have some questions about when and why NODE_MODULE_VERSION changes:

(@rvagg has anwered these in the comments below)

const windowUtils = require("window-utils");
const NS_XUL = "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul";
exports.Menuitem = function Menuitem(options) {
new windowUtils.WindowTracker({
onTrack: function (window) {
if ("chrome://browser/content/browser.xul" != window.location) return;
@techieBrandon
techieBrandon / gist:6190945
Created August 9, 2013 03:25
Working solution for local dev CI issue
tr-tz-mbp-2:guiMbb brandonwilburn$ cat Gruntfile.coffee
module.exports = (grunt) ->
path = require('path')
gruntConfig =
pkg: grunt.file.readJSON('package.json')
exec:
generateAppResourcesJson:
@brianloveswords
brianloveswords / eff-you-region-lock.md
Last active December 22, 2015 15:08
Defeating region lock

Prerequisites

  • Somewhat modern version of OpenSSH
  • Server you have SSH access to in the region you want to stream from.

Bummed about region lock? Start up your terminal and do this:

$ ssh -N -D 9999 yourserver.com