Trying Flow on my node.js code…Let’s see how this goes
- google flow
- click “getflow.com”
- was something else
- google flow javascript
- found flowtype.org
- Click “get started” and landed here https://flowtype.org/docs/getting-started.html#_
var A = Function.inherit(function () { | |
console.log('construct A'); | |
}, { | |
'aa': function () { | |
console.log('aa A'); | |
}, | |
}); | |
var B = A.inherit(function () { | |
console.log('construct B'); |
#!/usr/bin/env bash | |
pull_request() { | |
local to_branch="$1" | |
if [ -z $to_branch ]; then | |
to_branch="master" | |
fi | |
local access_token="[some access token with lots of characters]" |
Trying Flow on my node.js code…Let’s see how this goes
#!/usr/bin/env python | |
import os | |
import sys | |
import urllib2 | |
import json | |
''' | |
This script queries Github for source and target branches of a pull request | |
and updates environment variables at TeamCity CI to make these variable |
(function (triggerIntervalSeconds) { | |
triggerIntervalSeconds = triggerIntervalSeconds || (60 * 5); | |
var runInterval = triggerIntervalSeconds * 1000; | |
var runBuildTimeout = 300; | |
function runBuild(done) { | |
var runBtn = jQuery("button:contains(Run)")[0]; | |
console.log('opening build run dialog...'); |
#!/usr/bin/env bash | |
# example usage: | |
# | |
# json_response="$(curl --flag http://whatever.man)" # -> { "status": 22, "errors": [ { "message": "oh no!" } ] } | |
# errors="$(echo "$json_response" | json_get "errors")" | |
# [[ $errors ]] && { | |
# msg="$(echo "$errors" | json_get "0" | json_get "message")" | |
# } | |
json_get() { |
read -e IMAGE; | |
defaults write com.apple.desktop Background "{default = {ImageFilePath='$IMAGE'; };}" | |
killall Dock |
#!/usr/bin/env bash | |
main() { | |
log | |
log_ln "hi :)" | |
check_links $(cat -) | |
log_ln "bye bye!" | |
} |