This guide is based on the very informative discussion in this article: Using node_sqlite3 with Electron
Install sqlite3
npm install sqlite3 --save
| // ---------------------------------------------------------------------------- // | |
| // GNOSIS SAFE DEPLOYMENT SCRIPT // | |
| // ---------------------------------------------------------------------------- // | |
| import { ethers } from 'ethers' | |
| import EthersAdapter from '@gnosis.pm/safe-ethers-lib' | |
| import SafeServiceClient from '@gnosis.pm/safe-service-client' | |
| import Safe, { SafeFactory, EthSignSignature } from '@gnosis.pm/safe-core-sdk' | |
| import * as dotenv from 'dotenv' |
| #!/usr/bin/env python3 | |
| """ | |
| This script recovers the RSA public key that was used to make signatures, given | |
| any two such signatures in X.509 certificates. Python 3 is required, along with | |
| recent versions of pyasn1, pyasn1-modules, and pyprimes. Runtime is nearly | |
| instantaneous when the public key uses e=3, and 3+ hours when the public key | |
| uses e=65537. (This could be vastly improved by using a more efficient GCD | |
| library function) To recover a public key, run this script with the file names | |
| of two certificates as command line arguments. Certificates can be in PEM or | |
| DER format. |
This guide is based on the very informative discussion in this article: Using node_sqlite3 with Electron
Install sqlite3
npm install sqlite3 --save
| # Merge Script | |
| # http://code.hootsuite.com/an-introduction-to-creating-and-distributing-embedded-frameworks-in-ios/ | |
| # 1 | |
| # Set bash script to exit immediately if any commands fail. | |
| set -e | |
| # 2 | |
| # Setup some constants for use later on. |
| +(void)uploadUserPhoto:(UIImage *)image | |
| success:(void (^)(void))success | |
| failure:(FailureBlock)failure | |
| { | |
| GTSessionManager * manager = [GTSessionManager manager]; | |
| NSString* tmpFilename = [NSString stringWithFormat:@"%f", [NSDate timeIntervalSinceReferenceDate]]; | |
| NSURL* tmpFileUrl = [NSURL fileURLWithPath:[NSTemporaryDirectory() stringByAppendingPathComponent:tmpFilename]]; | |
| NSString * query = [NSString stringWithFormat:@"%@user?auth_token=%@",[manager.baseURL absoluteString],[[UserManager shared] authToken]]; |
| // | |
| // ViewController.m | |
| // AVPlayerCaching | |
| // | |
| // Created by Anurag Mishra on 5/19/14. | |
| // Sample code to demonstrate how to cache a remote audio file while streaming it with AVPlayer | |
| // | |
| #import "ViewController.h" | |
| #import <AVFoundation/AVFoundation.h> |
| # xcode-build-bump.sh | |
| # @desc Auto-increment the build number every time the project is run. | |
| # @usage | |
| # 1. Select: your Target in Xcode | |
| # 2. Select: Build Phases Tab | |
| # 3. Select: Add Build Phase -> Add Run Script | |
| # 4. Paste code below in to new "Run Script" section | |
| # 5. Drag the "Run Script" below "Link Binaries With Libraries" | |
| # 6. Insure that your starting build number is set to a whole integer and not a float (e.g. 1, not 1.0) |
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
| <plist version="1.0"> | |
| <dict> | |
| <key>items</key> | |
| <array> | |
| <dict> | |
| <key>assets</key> | |
| <array> | |
| <dict> |