Skip to content

Instantly share code, notes, and snippets.

View paulmelnikow's full-sized avatar

Paul Melnikow paulmelnikow

View GitHub Profile
@paulmelnikow
paulmelnikow / excel_to_json.py
Last active June 1, 2022 07:25
Convert Excel to JSON using pandas
#!/usr/bin/env python3
'''
MIT License
Copyright (c) 2018 Paul Melnikow
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell

Keybase proof

I hereby claim:

  • I am paulmelnikow on github.
  • I am paulmelnikow (https://keybase.io/paulmelnikow) on keybase.
  • I have a public key ASCJPkmwjjeBjcxc5j9MlZJEx5MSsi7148quFbfwTWgYXgo

To claim this, I am signing this object:

@paulmelnikow
paulmelnikow / gist:17632c2df8943d4dedc2
Created March 6, 2015 03:12
ObjCMongoDB build transcript
This file has been truncated, but you can view the full file.
Build target Pods-ObjCMongoDB-Expecta
Write auxiliary files
/bin/mkdir -p /Users/pnm/Library/Developer/Xcode/DerivedData/ObjCMongoDB-gxqwjmuevujtntazdogzfanhgknp/Build/Intermediates/Pods.build/Debug-iphonesimulator/Pods-ObjCMongoDB-Expecta.build
write-file /Users/pnm/Library/Developer/Xcode/DerivedData/ObjCMongoDB-gxqwjmuevujtntazdogzfanhgknp/Build/Intermediates/Pods.build/Debug-iphonesimulator/Pods-ObjCMongoDB-Expecta.build/Pods-ObjCMongoDB-Expecta-own-target-headers.hmap
write-file /Users/pnm/Library/Developer/Xcode/DerivedData/ObjCMongoDB-gxqwjmuevujtntazdogzfanhgknp/Build/Intermediates/Pods.build/Debug-iphonesimulator/Pods-ObjCMongoDB-Expecta.build/Pods-ObjCMongoDB-Expecta-all-non-framework-target-headers.hmap
write-file /Users/pnm/Library/Developer/Xcode/DerivedData/ObjCMongoDB-gxqwjmuevujtntazdogzfanhgknp/Build/Intermediates/Pods.build/Debug-iphonesimulator/Pods-ObjCMongoDB-Expecta.build/Pods-ObjCMongoDB-Expecta.hmap
write-file /Users/pnm/Library/Developer/Xcode/DerivedData/ObjCMongoDB-gxqwjmuevujtnt
var bar = function () {
console.log('yoyoyo');
};
module.exports = bar;
@paulmelnikow
paulmelnikow / heroku.rake
Last active August 29, 2015 14:11
Rake task to set up secure logging from from Heroku to Papertrail
namespace :heroku do
task :create_logger, [:name, :dst] do |t, args|
# To use this:
#
# 1. Add a new system. Choose "Alternative". Or go to
# https://papertrailapp.com/systems/new
# 2. Choose "I use Heroku"
# 3. Type the name of the app and click Save. You'll see a path like
@paulmelnikow
paulmelnikow / shadows.scss
Last active August 22, 2022 15:35
Sass Mixin: Google Material Design Shadow
/**
* A mixin which helps you to add depth to elements according to the Google Material Design spec:
* http://www.google.com/design/spec/layout/layout-principles.html#layout-principles-dimensionality
*
* Please note that the values given in the specification cannot be used as is. To create the same visual experience
* the blur parameter has to be doubled.
*
* Adapted from a LESS version at https://medium.com/@Florian/freebie-google-material-design-shadow-helper-2a0501295a2d
*
* Original Author: Florian Kutschera (@gefangenimnetz), Conceptboard GmbH (@conceptboardapp)
@paulmelnikow
paulmelnikow / AppDelegate.m
Last active December 12, 2015 10:29
Simple XMPPFramework test project
#import "AppDelegate.h"
#import "XMPPFramework.h"
#import "DDASLLogger.h"
#import "DDTTYLogger.h"
#import "DDLog.h"
static const int ddLogLevel = LOG_LEVEL_VERBOSE;
NSString * const XMPPAuthenticationMethodPlain = @"Plain";
NSString * const XMPPAuthenticationMethodDigestMD5 = @"Digest-MD5";
@paulmelnikow
paulmelnikow / gist:4645764
Last active March 27, 2021 23:31
Working Objective-C keychain library
NSString *const kKeychainErrorDomain = @"kKeychainErrorDomain"
NSString * ServiceName = @"My Service";
+ (NSError *) errorWithStatus:(OSStatus) status {
if (errSecSuccess == status) return nil;
#if __has_feature(objc_arc)
NSString *message = (__bridge_transfer NSString *)SecCopyErrorMessageString(status, NULL);
#else
NSString *message = [(id) SecCopyErrorMessageString(status, NULL) autorelease];