Skip to content

Instantly share code, notes, and snippets.

View mingderwang's full-sized avatar
:bowtie:
On chain, building AA wallet

Ming-der Wang mingderwang

:bowtie:
On chain, building AA wallet
View GitHub Profile
@mingderwang
mingderwang / gist:2533726
Created April 29, 2012 05:33
my first trial for mongodb
ming@ming-laptop:~/mongodb-linux-x86_64-2.0.2/bin$ ./mongo
MongoDB shell version: 2.0.2
connecting to: test
Mon Jan 9 13:17:10 Error: couldn't connect to server 127.0.0.1 shell/mongo.js:84
exception: connect failed
ming@ming-laptop:~/mongodb-linux-x86_64-2.0.2/bin$ ./mongo
MongoDB shell version: 2.0.2
connecting to: test
> db
test
@mingderwang
mingderwang / gist:4618005
Created January 24, 2013 05:51
make key for ssh
1. make a new public on local host (generate public key under ~/.ssh)
cd
ssh-keygen -t rsa -b 1024
2. copy the output of the following cat.
cat ~/.ssh/id_rsa.pub
3. ssh to your aws ec2 and paste it to ~/.ssh/authorized_keys2 (a new file)
@mingderwang
mingderwang / gist:4654899
Created January 28, 2013 11:46
get Clojurescript One running and deploy to heroku.
511 chmod 755 ~/bin/lein
512 cd
513 cd git
514 cd one
515 ls
516 lein bootstrap
517 lein bootstrap
518 lein repl
519 lein run -m script.build
520 git status
@mingderwang
mingderwang / gist:5298767
Created April 3, 2013 05:55
first thing you need to do after install Windows 8
@powershell -NoProfile -ExecutionPolicy unrestricted -Command "iex ((new-object net.webclient).DownloadString('http://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%systemdrive%\chocolatey\bin
Wangs-MacBook-Air:repo ming$ script/boxen
Boxen has a dirty tree, won't auto-update!
Password for sudo:
Notice: /Stage[main]/Boxen::Config/File[/Users/ming/src]/ensure: created
Notice: /Stage[main]/Boxen::Config/File[/opt/boxen/bin]/ensure: created
Notice: /Stage[main]/Boxen::Config/File[/opt/boxen/data]/ensure: created
Notice: /Stage[main]/Boxen::Config/File[/opt/boxen/data/project-sockets]/ensure: created
Notice: /Stage[main]/Boxen::Config/File[/opt/boxen/data/puppet]/ensure: created
Notice: /Stage[main]/Boxen::Config/File[/opt/boxen/log]/ensure: created
Notice: /Stage[main]/Boxen::Config/File[/opt/boxen/env.d]/ensure: created
@mingderwang
mingderwang / gist:5379167
Last active December 16, 2015 04:39
test boxen-webnstalling json (1.7.7) with native extensions
Wangs-MacBook-Air:git ming$ git clone https://github.com/boxen/boxen-web.git
Cloning into 'boxen-web'...
remote: Counting objects: 403, done.
remote: Compressing objects: 100% (298/298), done.
remote: Total 403 (delta 109), reused 373 (delta 85)
Receiving objects: 100% (403/403), 18.59 MiB | 313 KiB/s, done.
Resolving deltas: 100% (109/109), done.
Wangs-MacBook-Air:git ming$ pwd
/Users/ming/git
Wangs-MacBook-Air:git ming$ ls
@mingderwang
mingderwang / gist:5381043
Created April 14, 2013 02:00
Your Ruby version is 1.8.7, but your Gemfile specified 1.9.3
ming$ script/tests
Your Ruby version is 1.8.7, but your Gemfile specified 1.9.3
Wangs-MacBook-Air:boxen-web ming$ rvm use 1.9.3
-bash: rvm: command not found
Wangs-MacBook-Air:boxen-web ming$ ruby -v
ruby 1.8.7 (2012-02-08 patchlevel 358) [universal-darwin12.0]
Wangs-MacBook-Air:boxen-web ming$ \curl -#L https://get.rvm.io | bash -s stable --autolibs=3 --ruby
######################################################################## 100.0%
Please read and follow further instructions.
Press ENTER to continue.
@mingderwang
mingderwang / gist:5381496
Last active December 16, 2015 04:59
script/tests again.
Wangs-MacBook-Air:boxen-web ming$ script/tests
Missing from ENV: REPOSITORY, GITHUB_CLIENT_ID, GITHUB_CLIENT_SECRET
Wangs-MacBook-Air:boxen-web ming$ script/tests
Could not find rake-10.0.3 in any of the sources
Run `bundle install` to install missing gems.
Wangs-MacBook-Air:boxen-web ming$ bundle install
Fetching gem metadata from https://rubygems.org/.........
Fetching gem metadata from https://rubygems.org/..
@mingderwang
mingderwang / gist:5381696
Last active December 16, 2015 04:59
still not working boxen-web
Wangs-MacBook-Air:boxen-web ming$ script/bootstrap
Wangs-MacBook-Air:boxen-web ming$ script/tests
/Users/ming/git/boxen-web/.bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `require': Please install the postgresql adapter: `gem install activerecord-postgresql-adapter` (dlopen(/Users/ming/git/boxen-web/.bundle/ruby/1.9.1/gems/pg-0.14.1/lib/pg_ext.bundle, 9): Library not loaded: /Users/ming/.rvm/rubies/ruby-1.9.3-p392/lib/libruby.1.9.1.dylib (LoadError)
Referenced from: /Users/ming/git/boxen-web/.bundle/ruby/1.9.1/gems/pg-0.14.1/lib/pg_ext.bundle
Reason: image not found - /Users/ming/git/boxen-web/.bundle/ruby/1.9.1/gems/pg-0.14.1/lib/pg_ext.bundle)
from /Users/ming/git/boxen-web/.bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `block in require'
from /Users/ming/git/boxen-web/.bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:236:in `load_dependency'
from /Users/ming/git/boxen-web/.bundle/ruby/1.9.1
@mingderwang
mingderwang / gist:5381735
Created April 14, 2013 06:56
Can't find the PostgreSQL client library (libpq) solution.
$sudo gem install activerecord-postgresql-adapter
Password:
Building native extensions. This could take a while...
ERROR: Error installing activerecord-postgresql-adapter:
ERROR: Failed to build gem native extension.
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby extconf.rb
checking for pg_config... yes
Using config values from /usr/bin/pg_config
checking for libpq-fe.h... yes