-
Install docker-manger.conf and docker-instance.conf in /etc/init
-
Create a containers file in /etc/docker/ with the following format
name: image cmd
The name must be unique.
-
sudo service docker-manager start
This file contains 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
var reverse = require('ascii-art-reverse') | |
// makes a visible HTML console | |
require('console-log').show(true) | |
var coolbear = | |
" ('-^-/') \n" + | |
" `o__o' ] \n" + | |
" (_Y_) _/ \n" + | |
" _..`--'-.`, \n" + |
This file contains 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
<!doctype html> | |
<input id="query" type="text"></input> | |
<button id="search">Search</button> | |
<p id="results"></p> | |
<script src="bundle.js"></script> |
This file contains 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
/** | |
* POST to create a new user. | |
*/ | |
exports.create = function *(){ | |
var body = yield parse(this); | |
// password | |
var pass = body.password; | |
assert(pass, 400, 'password is required'); |
This file contains 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
var push = function (value) { | |
return function (stack) { | |
var newStack = [value].concat(stack); | |
return { value:undefined, stack:newStack }; | |
}; | |
}; | |
var pop = function () { | |
return function (stack) { | |
var value = stack[0]; |
This file contains 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
function run(generator) { | |
var iterator = generator(resume); | |
var data = null, yielded = false; | |
iterator.next(); | |
yielded = true; | |
check(); | |
function check() { | |
while (data && yielded) { |
This file contains 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
tim@touchsmart:~/Code$ nvm use v0.11.2-generators | |
Now using node v0.11.2-generators | |
tim@touchsmart:~/Code$ node --harmony testgen.js | |
<Buffer 76 61 72 20 66 73 20 3d 20 72 65 71 75 69 72 65 28 27 66 73 27 29 3b 0a 66 75 6e 63 74 69 6f 6e 20 72 65 61 64 46 69 6c 65 28 70 61 74 68 2c 20 65 6e 63 ...> | |
Sleeping for 2000ms... | |
Done |
Converts an existing Cordova/Ionic project to a Crosswalk project. When the script is done running, you should have a fat 40MB APK file in platforms/android/ant-build
.
This assumes you have the following already installed: cordova
, ant
, android
, and that your ANDROID_HOME
is set to point to the Android SDK.
This will work on both x86 and ARM. If you want to build two separate APKs so that they're smaller, then modify the script; the script at least shows how it works.
Step 1: download the "Cordova Android" libraries from the Crosswalk downloads page. You don't need anything except for the "Cordova Android" ones.
This file contains 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
#!/bin/bash | |
PROJECT_NAME=MyApp | |
SCHEME_NAME=MyApp | |
STARTTIME=$(date +%s); | |
set -e | |
set -x | |
### Install dependencies | |
echo "--- Install dependencies [Time Elapsed $(($(date +%s) - $STARTTIME))s]" |
OlderNewer