- Create a
Cartfile
with needed dependencies - Create a
Cartfile.private
with internal/test dependencies carthage update - Launch Xcode and create a new workspace: File → New → Workspace
- Create a Library project: File → New → Project → Cocoa Touch Framework Be sure to add it to the recently created Workspace and group to the Workspace
- Create an App project: File → New → Project → Single View App
- Add it to the recently created Workspace and group to the Workspace
- Enable your library project to provide a shared schema: (Target selector) → Manage Schemas…
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def out = new StringBuilder() | |
def err = new StringBuilder() | |
def proc = 'ls -lrt'.execute() | |
proc.consumeProcessOutput(out, err) | |
proc.waitForProcessOutput() | |
println "$out" | |
println "$err" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const toCamelCaseProps = (obj: any) => { | |
return Object.keys(obj).reduce((renamed, key) => { | |
let value = obj[key]; | |
if (typeof value === 'object' && value) { | |
value = toCamelCaseProps(value); | |
} | |
const camelCasedKey = key.charAt(0).toLowerCase() + key.slice(1); | |
renamed[camelCasedKey] = value; | |
return renamed; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Injectable } from '@angular/core'; | |
import { Observable, Observer, BehaviorSubject, ReplaySubject } from 'rxjs/Rx'; | |
import * as SockJS from 'sockjs-client'; | |
import { Client, Frame, Stomp } from 'stompjs'; | |
const DEFAULT_CACHE_SIZE: number = 100; | |
class TopicSubscription { | |
public subscription: any = null; | |
public subject: ReplaySubject<any>; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Injectable } from '@angular/core'; | |
import StorageService from './storage.service'; | |
@Injectable() | |
export class LocalStorageService extends StorageService { | |
private _storage = localStorage; | |
constructor() { | |
super(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
let gulp = require('gulp'); | |
let sass = require('gulp-sass'); | |
let buildStyles = (src, dest) => { | |
let themes = `${__dirname}/sass/themes`; // convention is _some-theme.scss => @import 'some-theme'; | |
let components = `${__dirname}/sass/components`; | |
return new Promise((resolve, reject) => { | |
gulp.src(src) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
setw -g mode-keys vi | |
set -g mouse on | |
set -g base-index 1 | |
set -g default-terminal "screen-256color" | |
# Panes | |
setw -g pane-base-index 1 | |
set -g pane-border-fg colour236 | |
set -g pane-active-border-fg colour030 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- ref: http://media.admob.com/api/v1/docs/ --> | |
<script type="text/javascript" src="http://media.admob.com/api/v1/google_mobile_app_ads.js"></script> | |
<a href="[%DEST_URL_ESC_ESC%]" onclick="admob.opener.openUrl('[%DEST_URL_ESC_ESC%]', false); return false;"> | |
<img border="0" src="[%IMAGESRC%]" width="[%WIDTH%]" height="[%HEIGHT%]"> | |
</a> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
After=network.target | |
[Service] | |
ExecStart=/usr/bin/node /var/node/my-service/app.js | |
#Type=forking | |
Restart=always | |
StandardOutput=syslog | |
TimeoutSec=90 | |
SyslogIdentifier=my-service |
NewerOlder