Skip to content

Instantly share code, notes, and snippets.

View juliengrimault's full-sized avatar

Julien Grimault juliengrimault

View GitHub Profile

Keybase proof

I hereby claim:

  • I am juliengrimault on github.
  • I am juliengrimault (https://keybase.io/juliengrimault) on keybase.
  • I have a public key ASAJr3Bwr0jvjisKY-bpuuNHSBB38m7sVWxa7HYn85_5pgo

To claim this, I am signing this object:

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

@juliengrimault
juliengrimault / gist:6050846
Last active August 30, 2019 06:20
Unfuck Parallels Dekstop on Mavericks
Terminal - go to
cd /Applications/Parallels\ Desktop.app/Contents/Library/Extensions/10.6
sudo kextutil prl_hypervisor.kext/
sudo kextutil prl_vnic.kext/
sudo kextutil prl_hid_hook.kext/
sudo kextutil -d ./prl_hypervisor.kext prl_netbridge.kext/
sudo kextutil prl_usb_connect.kext
@juliengrimault
juliengrimault / RSOAuthEngine.podspec
Last active December 19, 2015 11:19
TH RSOAuthEngine spec
Pod::Spec.new do |s|
s.name = 'RSOAuthEngine'
s.version ='1.3.1'
s.license = 'MIT'
s.summary = 'ARC based OAuth engine for MKNetworkKit.'
s.homepage = 'https://github.com/rsieiro/RSOAuthEngine'
s.authors = { 'Rodrigo Sieiro' => '[email protected]' }
s.source = {:git => 'https://github.com/rsieiro/RSOAuthEngine.git', :tag => '1.3.1'}
s.source_files = 'RSOAuthEngine/*.{h,m}'
@juliengrimault
juliengrimault / TH-MKNetworkKit.podspec
Last active December 17, 2015 16:49
TradeHero MKnetworkKit podspec
Pod::Spec.new do |s|
s.name = 'MKNetworkKit'
s.version = '0.87'
s.summary = 'ARC ready Networking Framework with built in authentication and HTTP 1.1 caching standards support for iOS 5+ devices.'
s.homepage = 'https://github.com/MugunthKumar/MKNetworkKit'
s.author = { 'Mugunth Kumar' => '[email protected]' }
s.source = { :git => 'https://github.com/juliengrimault/MKNetworkKit.git' }
s.source_files = 'MKNetworkKit/*.{h,m}', 'MKNetworkKit/Categories/*.{h,m}'
s.ios.exclude_files = '**/*NSAlert*'
@juliengrimault
juliengrimault / gist:5523508
Created May 6, 2013 05:28
serialize form to json
(function ($) {
$.fn.serializeJSON = function () {
var json = {}
var form = $(this);
form.find('input, select').each(function () {
var val
if (!this.name) return;
if ('radio' === this.type) {
@juliengrimault
juliengrimault / CrashlyticsLogger.h
Created March 30, 2013 10:39
CocoaLumberjack logger that works with crashlytics
//
// CrashlyticsLogger.h
//
// Created by Julien Grimault on 4/1/13.
//
//
#import "DDLog.h"
@interface CrashlyticsLogger : DDAbstractLogger
@juliengrimault
juliengrimault / gist:4953436
Created February 14, 2013 15:11
I am trying to build a subclass of an AFHttpClient that uses ReactiveCocoa to access a paginated/cursored API endpoint. I want to create a signal that will fetch each page in turn and feed the received ids to its subscribers. this is my current implementation, I was wondering if this is the right way to do such thing or is there a more 'Reactive…
- (RACSignal*)friendsId
{
RACReplaySubject* subject = [RACReplaySubject subject];
[self enqueueWithSubject:subject cursor:-1];
return subject;
}
- (void)enqueueWithSubject:(RACSubject*)subject cursor:(NSInteger)cursor
{
RACSignal* json = [self friendsIdAtCursor:cursor];
#!/bin/bash
_base_dir="${1:-.}"
echo "Building assets bundle in $_base_dir"
_dirContentBundle="$_base_dir/*.bundle"
for f in $_dirContentBundle;
do
echo "removing old bundle $f"
rm -rf "$f"
@juliengrimault
juliengrimault / gist:2692793
Created May 14, 2012 08:48
Retain cycle in MKNetworkOperation completion handler
@interface Engine
+ (id)sharedEngine;
- (MKNetworkOperation*)someOperation:(CompletionBlock)block onError:(ErrorBlock)errorBlock;
@end
@interface MyViewController : UITableViewController
@property (nonatomic, strong) MKNetworkOperation* operation;
@end