One Paragraph of project description goes here
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
"use strict"; | |
const Twitter = require("twitter"); | |
const openai = require("openai"); | |
module.exports.improveTweets = (event, context, callback) => { | |
// Authenticate with the Twitter API | |
const client = new Twitter({ | |
consumer_key: process.env.CONSUMER_KEY, | |
consumer_secret: process.env.CONSUMER_SECRET, |
{ | |
"name": "workshop-computer-validator", | |
"version": "1.0.0", | |
"description": "I use this to validate people's computers have the proper versions of node and npm installed for a workshop", | |
"bin": "./validate-system.js", | |
"dependencies": { | |
"semver": "7.1.3" | |
} | |
} |
{ | |
"name": "workshop-setup", | |
"version": "1.0.0", | |
"description": "This is the common setup script for most of my workshops", | |
"bin": "./setup.js" | |
} |
module.exports = { | |
/** | |
* When editing your questions pay attention to your punctuation. | |
* Make sure you use question marks. | |
* Make sure the first answer is the correct one. | |
* Set at least ANSWER_COUNT answers, any extras will be shuffled in. | |
*/ | |
QUESTIONS_EN_US: [ | |
{ | |
'What snack is traditionally left out for Santa Claus?': [ |
function flatten(intArr, flatArr) { | |
var results = flatArr || []; | |
if (intArr && intArr.length > 0) { | |
intArr.forEach(function(value) { | |
if (typeof value === 'number') { | |
results.push(value); | |
} else if (value instanceof Array) { | |
flatten(value, results); | |
} |
#!/bin/bash | |
# Include envs | |
. /opt/elasticbeanstalk/env.vars | |
function error_exit | |
{ | |
eventHelper.py --msg "$1" --severity ERROR | |
exit $2 | |
} |
#WDI Installfest (Mac)
Please check your OS X version before beginning. (Click the Apple menu and choose About this Mac.) This set of steps should work for Mavericks or Yosemite; if you're on another version, let an instructor know.
##XCode
Open up your App store and install XCode
#Writing Bash Shell Scripts
###Objectives
###What is a shell script?
A shell script is a little more than a list of command that are run in sequence. By convention, a shell script should begin with
#Data Structures: Stacks
Objectives
Variables in JavaScript (and most other programming languages) are stored in two places: stack and heap.