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
routes = [ | |
['/profile/', 'my_profile'] | |
['/login/', 'login'] | |
['/logout/', ['User', 'logout']] | |
['/upload/', 'show_upload'] | |
['/docs/', 'my_docs'] | |
] |
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
define ['router', 'text!templates/document.html'], (routerjs, template_doc) -> | |
class Document extends routerjs.SyncModel | |
url: '/document/' # API end point | |
template: template_doc # HTML Template to render when fetching data with @get | |
Document.mine = (callback) -> | |
@req 'mine/', 'GET', {}, callback |
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
# -~- coding: utf-8 -~- | |
## not working write | |
import serial | |
import sys | |
import StringIO | |
def fp81_write(s, payload): |
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
//..... | |
min: { // for production | |
vendor: { | |
src: ['public/js/vendor/*.js'], | |
dest: 'public_build/js/vendor.js', | |
separator: ';' | |
}, | |
app: { | |
src: ['public/js/*.js'], | |
destDir: 'public_build/js/', |
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
/*global Storage:false */ | |
/*jshint eqnull:true */ | |
/* | |
* Extends Storage object to support storing JSON-encoded objects. | |
* (c) 2012 PlasticPanda.com | |
* License: MIT | |
*/ | |
(function (Storage) { |
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
# add this line: | |
[receive] | |
denyCurrentBranch = warn |
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
BATTAHOME=/home/battaglia | |
ENVFILE=$BATTAHOME/env.sh | |
userdata=`curl http://169.254.169.254/2007-08-29/user-data` | |
repourl=`echo "$userdata" | head -n 1` | |
envurl=`echo "$userdata" | tail -n 1` | |
echo -e "\n===> Downloading env from $envurl" | |
wget "$envurl" -O $ENVFILE |
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 | |
if [ "$(whoami)" != "root" ] | |
then | |
echo "Please run as root" | |
exit 1 | |
fi | |
echo -en "Application name => " |
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 | |
set -e | |
STAGE=$1 | |
if [ ! "$STAGE" ]; then | |
echo "Usage: $0 <stage>" | |
exit 1 | |
fi |
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
<html> | |
<head> | |
<style type="text/css"> | |
.box { | |
width: 200px; | |
height: 200px; | |
background-color: white; | |
border: 1px solid red; | |
position: absolute; | |
top: 100px; |