I hereby claim:
- I am skylineproject on github.
- I am brandon_mn (https://keybase.io/brandon_mn) on keybase.
- I have a public key ASDrbMBmaLAJrk4PSMKarjIQAuko3bnt5Owwwv-u1hb5MAo
To claim this, I am signing this object:
import { useState, useCallback } from "react"; | |
type AsyncStatus = 'notasked' | 'loading' | 'success' | 'error'; | |
// from https://usehooks.com/useAsync/ | |
export const useAsync = <T, E = string>( | |
asyncFunction: (...args: any[]) => Promise<T>, | |
) => { | |
const [status, setStatus] = useState<AsyncStatus>('notasked'); | |
const [value, setValue] = useState<T | null>(null); |
const { spawn } = require("child_process"); | |
const COMMAND = "ls" | |
const ALLOWED_REBOOTS = 10 | |
async function main() { | |
console.log("Starting process"); | |
let counter = 0; | |
let failed = false; | |
let handle; |
alias clean-rn="watchman watch-del-all && rm -fr $TMPDIR/npm* && rm -rf $TMPDIR/react-* && rm -rf node_modules/ && yarn cache clean && rm -rf ios/build && rm -rf ios/Pods && rm -rf android/.gradle && rm -rf android/.idea && rm -rf android/build && rm -rf android/app/build && rm -rf android/app/app.iml && yarn" |
I hereby claim:
To claim this, I am signing this object:
nginx: | |
build: ./loadbalancer | |
links: | |
- api | |
- messenger | |
ports: | |
- "80:80" | |
- "443:443" | |
api: | |
build: ./api |
var shipit = require('shipit'); | |
var Twit = require ('twit'); | |
var thingToTrack = 'YOUR TRACKING NUMBER HERE'; | |
var ups = new shipit.UpsClient({ | |
licenseNumber: 'LICENSE', | |
userId: 'USERNAME', | |
password: 'PASSWORD' | |
}); |
My friend was stuck without an internet connection during this year's State of the Union. I wanted to make sure we could all share our hot takes and direct quotes with them, so I made this 'lil distribution channel in the ten minutes before the speech.
I wrote these docs, and this script, in a total of ten minutes. It may be a bit rough. I'll be making updates to simplify and clarify in a few minutes. If you have any questions, leave a comment on the Gist, or get at me on Twitter -- I'm glad to help!
For SMS messaging, I used the awesome Twilio SMS APIs. To post to Twitter, I used the one, the only Twitter API.
function getKhan() { | |
for i in *; do | |
if [ -d $i ]; then | |
echo "$i" | |
(cd $i; getKhan) | |
fi | |
if [[ $i =~ \.7z$ ]]; then | |
7z x $i | |
fi | |
if [[ $i =~ \.flv$ ]]; then |