Skip to content

Instantly share code, notes, and snippets.

View cameronehrlich's full-sized avatar
💭
Swifting

Cameron Ehrlich cameronehrlich

💭
Swifting
View GitHub Profile
Run this command to install MG-CLI:
sudo apt-get update && wget https://minergate.com/download/deb-cli -O minergate-cli.deb && sudo dpkg -i minergate-cli.deb
to start miner (4 cores for BCN) use this command:
minergate-cli -user <[email protected]> -bcn 4
Feel free to send some of your earnings to me:
BTC (Don't attempt to send other coins to this address!): 17f77AYHsQbdsB1Q6BbqPahJ8ZrjFLYH2j
- (void)pushViewController:(UIViewController *)viewController animated:(BOOL)animated
{
[super pushViewController:viewController animated:animated];
self.interactivePopGestureRecognizer.delegate = viewController;
self.interactivePopGestureRecognizer.enabled = YES;
}
- (void)popViewController:(UIViewController *)viewController animated:(BOOL)animated
{
[super popViewController:viewController animated:animated];
@cameronehrlich
cameronehrlich / ComminCrypto.h
Created November 14, 2016 10:13
PHP's M_CRYPT in C Environment
/////////////////////////
// Base64.h
#ifndef BASE64_H
#define BASE64_H
#include <string>
#include <vector>
class Base64

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

// google_search.js
var webdriver = require('selenium-webdriver'),
By = webdriver.By,
until = webdriver.until;
var driver = new webdriver.Builder()
.forBrowser('firefox')
.build();
driver.get('http://www.google.com/ncr');
@cameronehrlich
cameronehrlich / AVCaptureSessionSetup.m
Last active February 20, 2017 07:24
Gives an example of how to initialize an video capture session
// MEModel.h
@interface MEModel : NSObject
@property (nonatomic, strong) AVCaptureSession *session;
@property (nonatomic, strong) AVCaptureDevice *frontCamera;
@property (nonatomic, strong) AVCaptureDevice *backCamera;
@property (nonatomic, strong) AVCaptureDeviceInput *inputDevice;
@property (nonatomic, strong) AVCaptureMovieFileOutput *videoFileOutput;
@property (nonatomic, strong) AVCaptureVideoPreviewLayer *previewLayer; // Once the session is setup, this can just easily be added to any view. i.e. [self.view.layer addSublayer:[[MEModel sharedInstance] previewLayer];
@cameronehrlich
cameronehrlich / MobileSafariUserAgentSwapExample.m
Last active March 25, 2018 12:08
An example of how to get a UIWebView to display a non-mobile version of a GitHub repository by spoofing the UserAgent.
@interface PLViewController ()
@property (strong, nonatomic) IBOutlet UIWebView *webView;
@end
@implementation PLViewController
- (void)viewDidLoad
{