View gist:da58d5254d061ebb7fafb5a887a1024a
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
#!/usr/bin/env node | |
require('./colorTheme.js'); | |
function stringify(obj) { | |
return JSON.stringify(obj, undefined, 4); | |
} | |
View App.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
import React from 'react'; | |
import { | |
StyleSheet, | |
TextInput, | |
TouchableOpacity, | |
Text, | |
KeyboardAvoidingView, | |
View, | |
} from 'react-native'; | |
import { Permissions, Notifications } from 'expo'; |
View sendPushNotification.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
sendPushNotification(token = this.state.token, title = this.state.title, body = this.state.body) { | |
return fetch('https://exp.host/--/api/v2/push/send', { | |
body: JSON.stringify({ | |
to: token, | |
title: title, | |
body: body, | |
data: { message: `${title} - ${body}` }, | |
}), | |
headers: { | |
'Content-Type': 'application/json', |
View registerForPushNotifications.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
async registerForPushNotifications() { | |
const { status } = await Permissions.getAsync(Permissions.NOTIFICATIONS); | |
if (status !== 'granted') { | |
const { status } = await Permissions.askAsync(Permissions.NOTIFICATIONS); | |
if (status !== 'granted') { | |
return; | |
} | |
} |
View gist:f3c16a41b448bda1b32ec0f8979c22ce
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
#ifndef SONG_H | |
#define SONG_H | |
#define Song const uint8_t PROGMEM | |
Song music[] = { | |
0x14, // Number of tracks | |
0x00, 0x00, // Address of track 0 | |
0x27, 0x00, // Address of track 1 | |
0x42, 0x00, // Address of track 2 |
View gist:79a2ec1a7c30e4aa72fb11c920b8a75a
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
#ifndef SONG2_H | |
#define SONG2_H | |
#include "atm_cmd_constants.h" | |
#ifndef ARRAY_SIZE | |
#define ARRAY_SIZE(a) (sizeof (a) / sizeof ((a)[0])) | |
#endif | |
#ifndef NUM_PATTERNS |
View gist:c1375907e744bfbf1fee00dd660c04ac
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
#ifndef SONG_H | |
#define SONG_H | |
#define Song const uint8_t PROGMEM | |
Song music[] = { | |
0x14, // Number of tracks | |
0x00, 0x00, // Address of track 0 | |
0x27, 0x00, // Address of track 1 | |
0x42, 0x00, // Address of track 2 |
View GameBoard.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
import React, { Component } from 'react'; | |
import { | |
AppRegistry, | |
StyleSheet, | |
Text, | |
View, | |
Image, | |
Dimensions, | |
PanResponder | |
} from 'react-native'; |
View evade_text_generator.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
// JAVASCRIPT To generate this stuff below: (Paste in JSFIddle.net) | |
var map = { | |
'A' : 0, | |
'B' : 1, | |
'C' : 2, | |
'D' : 3, | |
'E' : 4, | |
'F' : 5, | |
'G' : 6, | |
'H' : 7, |
View data_dump.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
{ | |
"timestamp": 1476970157974, // Let's use this to determine changes. | |
// Sourced from http://www.goruck.com/event-landing | |
"eventLocations" : { | |
"eventTypes": [ | |
{ | |
"eventTypeId": 1004, | |
"eventTypeName": "Ascent", | |
"eventCategoryId": 2, |
NewerOlder