Skip to content

Instantly share code, notes, and snippets.

View noahcse's full-sized avatar
🏠
Everyone wants to be found...

Noah noahcse

🏠
Everyone wants to be found...
View GitHub Profile
@noahcse
noahcse / uninstall-vs-for-mac.sh
Created November 26, 2017 05:38 — forked from junian/uninstall-vs-for-mac.sh
Uninstall Visual Studio for Mac
#!/bin/sh
# based on guide from Microsoft https://docs.microsoft.com/en-us/visualstudio/mac/uninstall
# Uninstall Visual Studio for Mac
echo "Uninstalling Visual Studio for Mac ..."
sudo rm -rf "/Applications/Visual Studio.app"
rm -rf ~/Library/Caches/VisualStudio
rm -rf ~/Library/Preferences/VisualStudio
# Reference:
https://www.cloudgear.net/blog/2015/5-minutes-kubernetes-setup/
# install homebrew and cask
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
# install virtualbox
brew cask install virtualbox
# install dockertoolbox
@noahcse
noahcse / README.md
Created August 3, 2017 19:51 — forked from Ins1ne/README.md
My ZSH Theme — Agnoster Mod

My modified fork of agnoster.zsh-theme

A ZSH theme optimized for people who use:

  • Solarized
  • Git
  • Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)

Compatibility

@noahcse
noahcse / Nielsen2012Python_case.py
Created August 1, 2017 10:23 — forked from fnielsen/Nielsen2012Python_case.py
Text mining example in Python
# $Id: Nielsen2012Python_case.py,v 1.2 2012/09/02 16:55:25 fn Exp $
# Define a url as a Python string (note we are only getting 100 documents)
url = "http://wikilit.referata.com/" + \
"wiki/Special:Ask/" + \
"-5B-5BCategory:Publications-5D-5D/" + \
"-3FHas-20author%3DAuthor(s)/-3FYear/" + \
"-3FPublished-20in/-3FAbstract/-3FHas-20topic%3DTopic(s)/" + \
"-3FHas-20domain%3DDomain(s)/" + \
"format%3D-20csv/limit%3D-20100/offset%3D0"
@noahcse
noahcse / sound_recorder.py
Created July 22, 2017 21:06 — forked from mabdrabo/sound_recorder.py
Simple script to record sound from the microphone, dependencies: easy_install pyaudio
import pyaudio
import wave
FORMAT = pyaudio.paInt16
CHANNELS = 2
RATE = 44100
CHUNK = 1024
RECORD_SECONDS = 5
WAVE_OUTPUT_FILENAME = "file.wav"
@noahcse
noahcse / sound_recorder.py
Created July 22, 2017 21:06 — forked from mabdrabo/sound_recorder.py
Simple script to record sound from the microphone, dependencies: easy_install pyaudio
import pyaudio
import wave
FORMAT = pyaudio.paInt16
CHANNELS = 2
RATE = 44100
CHUNK = 1024
RECORD_SECONDS = 5
WAVE_OUTPUT_FILENAME = "file.wav"
@noahcse
noahcse / speech.js
Created July 22, 2017 11:49 — forked from lukehoban/speech.js
Project Oxford Speech APIs Node.js Sample
var fs = require('fs');
var util = require('util');
var request = require('request');
var clientId = 'test-app'; // Can be anything
var clientSecret = 'f6f0bfec08274b8790520a9079b808af'; // API key from Azure marketplace
var str = 'This is a cool demo to call Microsoft text to speach service in Node.js.';
console.log('Converting from text -> speech -> text.');
@noahcse
noahcse / github_flask_oauth2.py
Created July 15, 2017 01:34 — forked from ib-lundgren/github_flask_oauth2.py
Example of how to use Flask with requests-oauthlib to fetch a GitHub user profile using an OAuth 2 token.
from requests_oauthlib import OAuth2Session
from flask import Flask, request, redirect, session, url_for
from flask.json import jsonify
import os
app = Flask(__name__)
# This information is obtained upon registration of a new GitHub
client_id = "<your client key>"
@noahcse
noahcse / 0_reuse_code.js
Created July 3, 2017 18:15
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console