I hereby claim:
- I am briangershon on github.
- I am brianfive (https://keybase.io/brianfive) on keybase.
- I have a public key whose fingerprint is FACB 3AA6 562C A75C 1708 D187 0B22 B8EE 9244 656E
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
| buf, bodyErr := ioutil.ReadAll(r.Body) | |
| if bodyErr != nil { | |
| log.Print("bodyErr ", bodyErr.Error()) | |
| http.Error(w, bodyErr.Error(), http.StatusInternalServerError) | |
| return | |
| } | |
| rdr1 := ioutil.NopCloser(bytes.NewBuffer(buf)) | |
| rdr2 := ioutil.NopCloser(bytes.NewBuffer(buf)) | |
| log.Printf("BODY: %q", rdr1) |
My notes on creating a Rails 4.2 app for hosting on Heroku. With RSpec and Postgresql.
# Install RVM, Ruby and Bundler
...
# Install Rails
gem install rails --no-ri --no-rdoc
# Create new app without Test::Unit, and for Postgresql (for Heroku)
rails new MYAPP --skip-test-unit --database=postgresql
| # various Yeoman generators (generator-webapp) are failing due to using npm 2.x beta with errors | |
| # like "grunt 1.4.x" peer dependency not met (when in fact the dependency is met). | |
| # fix for me was to upgrade node, but install npm separately, since upgrading node automatically installs latest npm which is 2.x | |
| # to install latest node | |
| brew update | |
| brew install node --without-npm | |
| # to install latest 1.x branch of npm |
Download latest Raspbian and write to SD card
# identify the disk (not partition) of your SD card. e.g. disk4 (not disk4s1)
diskutil list
diskutil unmountDisk /dev/<disk# from diskutil> # e.g. diskutil unmountDisk /dev/disk4
sudo dd bs=1m if=<your image file>.img of=/dev/<disk# from diskutil>
# e.g. sudo dd bs=1m if=2012-12-16-wheezy-raspbian.img of=/dev/disk4
(This will take a few minutes)
Boot Raspberry PI and install a Bonjour client
| /*globals Parse*/ | |
| /** | |
| * Playing with using the Q promise library with Parse.com | |
| * to ease offline development and testing. | |
| * | |
| * http://documentup.com/kriskowal/q/ | |
| * | |
| * Was tricky to mock-up Parse's promise implementation. | |
| * |
Here's an experiment to work locally on a Mac using Git and my editor of choice -- while integrating well with Microsoft TFS which houses company-wide code.
If you want to work completely in Windows see: