Skip to content

Instantly share code, notes, and snippets.

View gooderist's full-sized avatar

Will Wong gooderist

  • Tokyo
View GitHub Profile
@gooderist
gooderist / webpack.config.js
Last active November 27, 2015 08:06
webpack + babel + react hot loader config file
'use strict';
const webpack = require('webpack');
module.exports = {
entry: [
'webpack-dev-server/client?http://0.0.0.0:8080', // WDS host
'webpack/hot/only-dev-server', // not sure what this does
'./entry.js'
],
@gooderist
gooderist / proc.js
Created September 16, 2017 14:23
Convert a bunch of ppts to txt files
const fs = require('fs')
const ppt = require('ppt')
const path = require('path')
let inDir = 'raw-ppts'
let outDir = 'out'
fs.readdirSync(inDir).forEach(n=>{
if(n.endsWith('.ppt')) {
@gooderist
gooderist / gist:ddd1f7049852931d1f491b7b7f35668a
Created September 17, 2017 13:05
Simple English detection
const unicode = {
basic_latin: /[\u0020-\u007F]/g
}
console.log('賛美歌い続ける'.search(unicode.basic_latin)) // -1
console.log('Sanbi utaitsuzukeru'.search(unicode.basic_latin)) // 0
console.log('10,000 Reasons'.search(unicode.basic_latin)) // 0
console.log('Bless the Lord oh my soul'.search(unicode.basic_latin)) // 0
@gooderist
gooderist / LevelHelper2-API_cocos2d-x_setup.md
Last active February 20, 2018 05:45
How to start a new win32 cocos2d-x / box2d / LevelHelper2-API project

Steps to setup a new win32 cocos2d-x project with LevelHelper2-API and Box2D support

Things you will need

Preliminary Setup

  • Install Visual Studio
@gooderist
gooderist / ogl_osx.md
Created March 24, 2018 13:22 — forked from v3n/ogl_osx.md
GLFW on OS X starting guide

OpenGL Development on OS X

While it's possible to download packages and install them manually, it's such a hassle. Fortunately for us, OS X has an unofficial package manager called http://brew.sh Let's install it. Open you Terminal and paste the following code:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

Great. Homebrew will automatically install packages to /usr/local. Conveniently, that directory is already in your include and link paths.

@gooderist
gooderist / Pro6 RTFData Spec.md
Last active May 12, 2020 17:44
Pro6 RTFData Spec

(Unofficial) Pro6 RTFData Spec

Notes regarding the RTF format used in ProPresenter6. All slide text data (RTFData) is rich text formatted and base64 encoded. I had to figure this out so I could create tools to generate slides outside of ProPresenter. There are a few additional rtf codes in the Propresenter version of RTF. The following are notes taken from inspecting the Windows version of RTFData. Mac has a different set of RTF codes (that will work on Windows). It is my goal to find the minimal subset that will work on both platforms while minimizing the amount of boilerplate we have to generate.

References:

Header

Prolog

\rtf1 - standard rtf header code

@gooderist
gooderist / Pro6 File Spec.md
Last active January 15, 2022 22:32
Pro6 File Spec

(Unofficial) Pro6 File Specification

This is a reverse-engineered description of the Pro6 file format used in ProPresenter6. This work is in no way affiliated with or authorized by RenewedVision(c) with the exception that we all serve the same Lord, Jesus Christ.

last updated 2019/10/14

General

The file is an xml file with base64 encoded strings. Slide text is mainly expressed as RTF strings. More details below under section [todo: NSString] The file begins with tag <?xml version="1.0" encoding="utf-8"?>