Skip to content

Instantly share code, notes, and snippets.

Avatar

Lee Boonstra savelee

View GitHub Profile
@savelee
savelee / gist:ee2cf546493551d1448a
Created Jul 1, 2015
Start Sencha Webserver from the command-line
View gist:ee2cf546493551d1448a
sencha fs web -p 80 start -map /path/to/webroot/
@savelee
savelee / gist:5724e99ed51e79cf22c7
Created Jul 8, 2015
Show all hidden files on Mac OSX
View gist:5724e99ed51e79cf22c7
defaults write com.apple.finder AppleShowAllFiles TRUE && killall Finder
@savelee
savelee / gist:85d56cd290f755752b66
Created Jul 9, 2015
Dokku add environment variable
View gist:85d56cd290f755752b66
dokku config:set appname KEY=value
@savelee
savelee / gist:dc4d9917df453b068905
Created Jul 10, 2015
Restart Apache on Ubuntu
View gist:dc4d9917df453b068905
sudo service apache2 restart
@savelee
savelee / gist:662f58ebcee7889ade60
Last active Aug 29, 2015
Shutdown digital ocean ubuntu droplet
View gist:0e7023e53049bafd597d
https://www.digitalocean.com/community/tutorials/how-to-install-mongodb-on-ubuntu-14-04
//Check if mongo is running
service mongod status
//You can also stop, start, and restart MongoDB using the service command (e.g. service mongod stop, server mongod start).
View gist:304b861a1417f33fc669
yo nodejs
//install modules globally
npm install packagename -g
//install modules and save in package.json
npm install packagename --save
@savelee
savelee / gist:2be4dcadb7638b005365
Last active Aug 29, 2015
Unload & Reload discoveryd to Fix DNS & Wi-Fi Failures in OS X Yosemite
View gist:2be4dcadb7638b005365
This trick involves refreshing the discoveryd service by unloading and reloading it with the launchctl command.
This is a bit curious but apparently it works for some users, suggesting there could be an issue with discovery or resolving DNS on some Yosemite Macs.
It’s certainly worth a try if the above tricks failed to resolve your wi-fi connectivity problems in OS X 10.10, as there are a fair amount of positive reports with this one:
Open Terminal (found in /Applications/Utilities/ or with Spotlight) and enter the following command:
`sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.discoveryd.plist`
Hit return and enter an admin password to use the sudo command
Now run the following command to reload discoveryd (this used to be called mDNSResponder)
`sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.discoveryd.plist`
@savelee
savelee / gist:510e93bd6f499e6c66e5
Created Jul 29, 2015
Dokku listing containers
View gist:510e93bd6f499e6c66e5
Listing running containers: dokku ps
To kill a container:
dokku kill <id-container>
https://docs.docker.com/articles/basics/
@savelee
savelee / gist:545c18aaedfcb54ea7f3
Last active Sep 13, 2015
Mongo Local - everything you need to know
View gist:545c18aaedfcb54ea7f3
//1) start the mongo server from CLI:
//It will starts the mongoserver on http://127.0.0.1:27017
sudo mongod
//2) Open a new terminal window, run mongo shell:
mongo
//3) Open a new terminal window, go to:
//(this is actually a symlink to: ~/npm/lib/node_modules/mongoexpress
cd /Applications/XAMPP/htdocs/node/mongo-express
You can’t perform that action at this time.