Skip to content

Instantly share code, notes, and snippets.

View ah-cog's full-sized avatar

Ashley Hayes ah-cog

  • San Francisco, California
View GitHub Profile
@ah-cog
ah-cog / framework-electron-react.md
Last active August 31, 2017 10:48 — forked from matthewjberger/notes.md
How to make an electron app using Create-React-App and Electron with Electron-Builder.

This note describes how I assembled an application framework with:

  • Electron: for cross platform application frame
  • React: for UI
    • Node
  • (maybe) Postgres in Docker (with persistence via shared volume)
  • (maybe) SQLite
  • (maybe) Sequelize (in Node/React to interface with DB)
  • (maybe) Docker

Prerequisites

Keybase proof

I hereby claim:

  • I am mgub on github.
  • I am mgub (https://keybase.io/mgub) on keybase.
  • I have a public key ASAWJFi9l6cUuqPkgJrAx9INUxoQcN3ACublIWXiMflpUwo

To claim this, I am signing this object:

@ah-cog
ah-cog / install-pip-for-babun.md
Last active July 29, 2017 08:30 — forked from dragon788/gist:69295688c66f25ae3a97
Install pip for Babun

When developing with Python in on Windows, I use the Babun shell. Here, I describe how to set up a Python environment for use in Babun.

Install easy_setup:

wget https://bootstrap.pypa.io/ez_setup.py -O - | python

Use easy_setup to install pip:

@ah-cog
ah-cog / curl.md
Created July 19, 2017 03:40 — forked from btoone/curl.md
A curl tutorial using GitHub's API

Introduction

An introduction to curl using GitHub's API.

The Basics

Makes a basic GET request to the specifed URI

curl https://api.github.com/users/caspyin
@ah-cog
ah-cog / iterm2-solarized.md
Created January 31, 2017 19:21 — forked from kevin-smets/iterm2-solarized.md
iTerm2 + Oh My Zsh + Solarized color scheme + Meslo powerline font + [Powerlevel9k] - (macOS)

Default

Default

Powerlevel9k

Powerlevel9k

@ah-cog
ah-cog / single-syllable-words.txt
Last active August 5, 2016 09:28
Single Syllable Words
lab
form
toy
clock
ground
kit
shell
loop
path
line
@ah-cog
ah-cog / unique_id_generator.c
Last active May 7, 2016 22:49 — forked from shabinesh/id.c
unique id generator
#include<stdio.h>
#include<sys/time.h>
int main()
{
int i;
for(i =0;i < 32; i++)
func(i);
return 0;
}
@ah-cog
ah-cog / git Usage Patterns.md
Last active July 18, 2016 12:39 — forked from hofmannsven/README.md
git Usage Patterns

Using Git

Top commands

Commit changes, create pull request, and update branch

First, commit your changes:

git commit -m "Descriptive commit message."

@ah-cog
ah-cog / ESP8266 AT Commands for Creating a UDP Server.md
Last active March 16, 2024 15:19
ESP8266 AT command sequence to start a UDP server with Espressif AT firmware v0.22.

Create a UDP Server to Listen for Incoming Broadcasts

The following sequence of commands will (1) start a TCP server listening for traffic on port 80 and (2) start a UDP server and listen for incoming UDP packets from all addresses.

AT

OK
AT+CWMODE_CUR=3

OK

@ah-cog
ah-cog / Using the Terminal to Upload an Arduino Sketch to the Teensy 3.1.md
Last active April 16, 2020 01:00
Upload to the Teensy 3.1 from Terminal on OS X with Arduino 1.6.1 and Teensyduino 1.21.

Uploading Arduino Sketches to the Teensy 3.1 from the Terminal

First, install Arduino 1.6.1 from http://arduino.cc/en/Main/Software. I followed the Mac OS X for Java 6 link to download arduino-1.6.1-macosx.zip. Install Arduino by unzipping the Arduino file and moving it to /Applications/Arduino. Open Arduino to make sure it works and so it can finish setting up the environment for use. Next, install Teensyduino 1.21 from https://www.pjrc.com/teensy/td_download.html. I followed Macintosh OS-X Installer to download teensyduino.dmg. Open and proceed through the Teensyduino installer, and when prompted to locate Arduino, select /Applications/Arduino, then continue to the next step in the installer.

At this point, you should be ready to upload a sketch. Follow the instructions below.

To upload from the terminal, enter the following command:

/Applications/Arduino.app/Contents/MacOS/JavaApplicationStub --board teensy:avr:teensy31 --port /dev/tty.usbmodem573061 --upload /Users/mokogobo/Checkout