- Setup
- Swapfile
- NGINX
- ElasticSearch
- RVM
- Rails
- Postgres
- Capistrano
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // Run this file from terminal "php ./import-post-wp.php PATH-TO-JSON" | |
| // Make sure you change permissions on the file so you can run it | |
| echo "\n"; | |
| // use this to stop the script from actually saving anything | |
| $debug = false; | |
| // load WP to get all it's fancy functions |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| UPDATE wp_options SET option_value = replace(option_value, 'http://www.oldurl', 'http://www.newurl') WHERE option_name = 'home' OR option_name = 'siteurl'; | |
| UPDATE wp_posts SET guid = replace(guid, 'http://www.oldurl', 'http://www.newurl'); | |
| UPDATE wp_posts SET post_content = replace(post_content, 'http://www.oldurl', 'http://www.newurl'); | |
| UPDATE wp_postmeta SET meta_value = replace(meta_value, 'http://www.oldurl', 'http://www.newurl'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env ruby | |
| require 'rubygems' | |
| require 'nokogiri' | |
| require 'open-uri' | |
| require 'uri' | |
| require 'net/http' | |
| require 'rainbow' | |
| require 'awesome_print' | |
| class Crawl |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| rails new ProjectName -d mysql |
http://technobytz.com/install-postgresql-9-3-ubuntu.html
sudo apt-get update
sudo apt-get -y install python-software-properties
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| export CLICOLOR=1 | |
| export TERM=xterm-256color | |
| export BASH_SILENCE_DEPRECATION_WARNING=1 | |
| # PS1 | |
| export PS1="________________________________________________________________________________\n| \w \n| => " | |
| export PS2="| => " | |
| # Set default editor |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env ruby | |
| require 'awesome_print' | |
| require 'json' | |
| PROXY_NAME = 'proxy' | |
| ACCESS_TOKEN = 'XXXXXXXX' | |
| # DESTROY | |
| def destroy_all_servers |
- Enabled Tap to Click
- Enable Trackpad Dragging (found in accessibility settings)
- Add my
.bash_profilehttps://gist.github.com/yosukehasumi/fb5c97f661ee3d4e1b41049707606fb5 - Add item word jump hotkeys for iTerm (Preferences > Profiles > Keys > Presets: 'Natural Text Editing')
- Hide Dock (
defaults write com.apple.Dock autohide-delay -float 5 && killall Dock) - Hide icons on Desktop (
defaults write com.apple.finder CreateDesktop false; killall Finder;) - Generate SSH keys `ssh-keygen -t rsa -b 4096 -C "your@email.com"
- Chrome