Skip to content

Instantly share code, notes, and snippets.

View andrewzeneski's full-sized avatar

Andrew Zeneski andrewzeneski

  • Null Pointer, Inc.
  • New York, NY
View GitHub Profile
@sdebnath
sdebnath / gist:36c235e042cb35db7d1f
Last active July 13, 2018 09:39
Add field to Riak YZ Schema with CRDTs
This gist captures what needs to be done to add a new field to Riak's Yokozuna
search index.
Sources:
- https://github.com/basho/yokozuna/issues/130
- http://riak-users.197444.n3.nabble.com/How-to-update-existed-schema-td4032143.html
The code below is for illustration purposes only. Use at your own risk.
1. Create/Update new schema file
@xpe
xpe / start-riak
Created October 24, 2014 03:42
Adjusts ulimit, as needed, and starts Riak on Mac OS X. Tested on Yosemite.
#!/usr/bin/env bash
MAXFILES=$(launchctl limit maxfiles | sed -e 's/[[:space:]]+/ /g' | xargs)
if [ "$MAXFILES" != "maxfiles 65536 65536" ]; then
set -x
sudo launchctl limit maxfiles 65536 65536
fi
set -x
ulimit -n 65536
riak start
@jedi4ever
jedi4ever / README.md
Last active January 2, 2016 14:18
Notes on auto crashlytics and cordova integration

After adding crashlytics code (crashlytics.sh) & Patching the xcodeproject file (crashlytics.rb)

  • It will work in xcode but not in cordova anymore.

  • This is because xcoder writes the .xcodeproj file in a format that node-xcode doesn't understand.

  • you need to 'beautify/sanitize' the file again.

    • brew install xcproj
    • and run xcproj -P <path to your xcodeproj file> touch
  • now you are ready to go in cordova

@cridenour
cridenour / gist:74e7635275331d5afa6b
Last active August 7, 2023 13:52
Setting up Vim as your Go IDE

Setting up Vim as your Go IDE

The final IDE

Intro

I've been wanting to do a serious project in Go. One thing holding me back has been a my working environment. As a huge PyCharm user, I was hoping the Go IDE plugin for IntelliJ IDEA would fit my needs. However, it never felt quite right. After a previous experiment a few years ago using Vim, I knew how powerful it could be if I put in the time to make it so. Luckily there are plugins for almost anything you need to do with Go or what you would expect form and IDE. While this is no where near comprehensive, it will get you writing code, building and testing with the power you would expect from Vim.

Getting Started

I'm assuming you're coming with a clean slate. For me this was OSX so I used MacVim. There is nothing in my config files that assumes this is the case.

@joedevivo
joedevivo / gist:7305410
Created November 4, 2013 16:42
Mapping of riak configuration values from app.config to riak.conf current as of November 4, 2013
app.config field riak.conf variable
-------------------------------------------------------------------------------------------
yokozuna.enabled yokozuna
yokozuna.solr_port yokozuna.solr_port
yokozuna.solr_jmx_port yokozuna.solr_jmx_port
yokozuna.solr_jvm_args yokozuna.solr_jvm_args
yokozuna.yz_dir yokozuna.data_dir
riak_repl.data_root mdc.data_root
riak_core.cluster_mgr mdc.cluster_manager
riak_repl.max_fssource_cluster mdc.max_fssource_cluster
@sanatgersappa
sanatgersappa / gist:4030649
Created November 7, 2012 10:10
Querying Sharepoint on Office365 with Go
package main
import (
"fmt"
"io/ioutil"
"net/http"
"log"
"regexp"
"strings"
)
@jrmoran
jrmoran / app.js
Created October 27, 2012 21:58
AngularJS - Charting with Flot
var App = angular.module('App', []);
@rzezeski
rzezeski / gist:3250870
Created August 3, 2012 19:53
detect bad merge index files
#!/usr/bin/env escript
%% -*- erlang -*-
-include_lib("kernel/include/file.hrl").
-compile(export_all).
-define(LOG(S), io:format(S)).
-define(LOG(S,A), io:format(S,A)).
main(Dirs) ->
CodePath = case os:getenv("RIAK_LIB") of
@mrbrutti
mrbrutti / luhn.go
Created June 24, 2012 05:40
Luhn Algorith in go Lang
package gocard
import (
"fmt"
"io"
"crypto/md5"
"crypto/sha1"
"crypto/sha256"
"crypto/sha512"
)
@saetia
saetia / gist:1623487
Last active July 16, 2024 05:56
Clean Install – OS X 10.11 El Capitan

OS X Preferences


most of these require logout/restart to take effect

# Enable character repeat on keydown
defaults write -g ApplePressAndHoldEnabled -bool false

# Set a shorter Delay until key repeat