- Install required tools
- Latest Git Client
- gpg tools
brew install gpg
- Generate a new gpg key
| #Download and install XCode | |
| #Install homebrew (package manager) IF INSTALLED: just update it | |
| ruby -e "$(curl -fsSL https://gist.github.com/raw/323731/install_homebrew.rb)" | |
| #Install git | |
| brew install git | |
| #IF LION | |
| sudo vi /etc/paths and move /usr/local/bin to the top, cuz LION comes with a specific osx restricted PG. |
| diff --git a/common.mk b/common.mk | |
| index ea244cc..4f22609 100644 | |
| --- a/common.mk | |
| +++ b/common.mk | |
| @@ -629,7 +629,8 @@ file.$(OBJEXT): {$(VPATH)}file.c $(RUBY_H_INCLUDES) {$(VPATH)}io.h \ | |
| gc.$(OBJEXT): {$(VPATH)}gc.c $(RUBY_H_INCLUDES) {$(VPATH)}re.h \ | |
| {$(VPATH)}regex.h $(ENCODING_H_INCLUDES) $(VM_CORE_H_INCLUDES) \ | |
| {$(VPATH)}gc.h {$(VPATH)}io.h {$(VPATH)}eval_intern.h {$(VPATH)}util.h \ | |
| - {$(VPATH)}debug.h {$(VPATH)}internal.h {$(VPATH)}constant.h | |
| + {$(VPATH)}debug.h {$(VPATH)}internal.h {$(VPATH)}constant.h \ |
| # Run this file with `RAILS_ENV=production rackup -p 3000 -s thin` | |
| # Be sure to have rails and thin installed. | |
| require "rubygems" | |
| # We are not loading Active Record, nor the Assets Pipeline, etc. | |
| # This could also be in your Gemfile. | |
| gem "actionpack", "~> 3.2" | |
| gem "railties", "~> 3.2" | |
| require "rails" |
| # By default ReGex will match the bigest occurrence: | |
| ruby-1.9.2-p180 > "_one_ two _three_".scan(/_(.+)_/) | |
| => [["one_ two _three"]] | |
| # But we can tell it to match all the smallest ones: | |
| ruby-1.9.2-p180 > "_one_ two _three_".scan(/_(.+?)_/) | |
| => [["one"], ["three"]] |
| class ActionDispatch::Routing::Mapper | |
| def draw(routes_name) | |
| instance_eval(File.read(Rails.root.join("config/routes/#{routes_name}.rb"))) | |
| end | |
| end | |
| BCX::Application.routes.draw do | |
| draw :api | |
| draw :account | |
| draw :session |
| #!/usr/bin/env bash | |
| apt-get -y update | |
| apt-get -y install build-essential zlib1g-dev libssl-dev libreadline6-dev libyaml-dev git-core | |
| cd /tmp | |
| wget http://cache.ruby-lang.org/pub/ruby/2.0/ruby-2.0.0-p247.tar.gz | |
| tar -xvzf ruby-2.0.0-p247.tar.gz | |
| cd ruby-2.0.0-p247/ | |
| ./configure --prefix=/usr/local | |
| make | |
| make install |
| # Tweaked from http://tomislavsantek.iz.hr/2011/03/moving-mysql-databases-to-ramdisk-in-ubuntu-linux | |
| # Log in as root | |
| # Mount ramdisk folder in RAM | |
| mkdir /tmp/ramdisk | |
| mount -t tmpfs -o size=128M tmpfs /tmp/ramdisk/ | |
| # Move MySQL data | |
| mv /var/lib/mysql /tmp/ramdisk/mysql | |
| ln -s /tmp/ramdisk/mysql/ /var/lib/mysql |
brew install gpg
ℹ️ Enable iCloud end-to-end encryption:
System settings → Apple ID → iCloud → Set Advanced Data Protection to On.System settings → Apple ID → iCloud → Disable Access iCloud Data on the Web.Mouse:
ℹ️ Enable iCloud end-to-end encryption:
System settings → Apple ID → iCloud → Set Advanced Data Protection to On.System settings → Apple ID → iCloud → Disable Access iCloud Data on the Web.Mouse: