Skip to content

Instantly share code, notes, and snippets.

Ian Spence ecnepsnai

Block or report user

Report or block ecnepsnai

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
ecnepsnai /
Last active Nov 15, 2019
Windows 10 New PC Setup

Windows 10 New PC Setup

The Basics

Local account only

Don't link a local workstation account with an online account.


ecnepsnai /
Created Apr 9, 2019
Script to manage go versions easily
set -e
VERSION=${1:?Version Required}
if [[ ! -d ${INSTALL_DIR} ]]; then
mkdir -p ${INSTALL_DIR}
View settings.json
"workbench.colorTheme": "One Dark Pro",
"workbench.iconTheme": "material-icon-theme",
"editor.fontSize": 13,
"editor.fontFamily": "Fira Code",
"window.zoomLevel": -1,
"go.testOnSave": false,
"go.liveErrors": {
"enabled": true,
"delay": 500
ecnepsnai /
Created Jan 5, 2019
Install Go Report Card
go get
go get
go get
go get
go get
ecnepsnai / ocsp.c
Created Feb 24, 2018
Get OCSP URI from Certificate
View ocsp.c
X509 * cert;
AUTHORITY_INFO_ACCESS * info = X509_get_ext_d2i(cert, NID_info_access, NULL, NULL);
int len = sk_ACCESS_DESCRIPTION_num(info);
for (int i = 0; i < len; i++) {
// Look for the OCSP entry
ACCESS_DESCRIPTION * description = sk_ACCESS_DESCRIPTION_value(info, i);
if (OBJ_obj2nid(description->method) == NID_ad_OCSP) {
if (description->location->type == GEN_URI) {
char * ocspurlchar = i2s_ASN1_IA5STRING(NULL, description->location->d.ia5);
ecnepsnai / guidelines.txt
Created Jun 6, 2017
App Store Review Guidelines
View guidelines.txt
App Store Review Guidelines
Apps are changing the world, enriching people’s lives, and enabling developers like you to innovate like never before. As a result, the App Store has grown into an exciting and vibrant ecosystem for millions of developers and more than a billion users. Whether you are a first time developer or a large team of experienced programmers, we are excited that you are creating apps for the App Store and want to help you understand our guidelines so you can be confident your app will get through the review process quickly.
The guiding principle of the App Store is simple - we want to provide a safe experience for users to get apps and a great opportunity for all developers to be successful. We have updated the App Review Guidelines with that principle in mind. The guidelines themselves haven’t changed, but they are better organized and provide more context. On the following pages you will find guidelines arranged into five clear sections: Safety, Performance, Business, Design,
ecnepsnai / csvhash.rb
Created Jan 10, 2017
Ruby CSV to/from Hash
View csvhash.rb
require 'csv'
class CSV
# Read the CSV file into an array of hashes
# @param path [String] The path to the CSV file to read
# @return [Array<Hash>] An array of hashes of each column mapped to the rows value
def self.readHash(path)
columns = {} # name mapped to index
return_hash = []
View obfuscate.js
var images = [
ecnepsnai / Prefix.pch
Created Feb 25, 2016
Handy Objective-C macros!
View Prefix.pch
#define SYSTEM_VERSION_EQUAL_TO(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedSame)
#define SYSTEM_VERSION_GREATER_THAN(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedDescending)
#define SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedAscending)
#define SYSTEM_VERSION_LESS_THAN(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedAscending)
#define SYSTEM_VERSION_LESS_THAN_OR_EQUAL_TO(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedDescending)
#define d(s, ...) NSLog(@"%@", [NSString stringWithFormat:(s), ##__VA_ARGS__ ?:@""])
ecnepsnai / Packages
Last active Oct 20, 2016
Sublime Settings
View Packages
You can’t perform that action at this time.