pivotal_workstation_cookbook 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +4 -0
- data/.gitmodules +3 -0
- data/.rvmrc +1 -0
- data/Gemfile +4 -0
- data/Rakefile +1 -0
- data/cookbooks/pivotal_workstation/.gitignore +2 -0
- data/cookbooks/pivotal_workstation/LICENSE.txt +21 -0
- data/cookbooks/pivotal_workstation/README.markdown +31 -0
- data/cookbooks/pivotal_workstation/attributes/chrome.rb +1 -0
- data/cookbooks/pivotal_workstation/attributes/firefox.rb +2 -0
- data/cookbooks/pivotal_workstation/attributes/fusion.rb +1 -0
- data/cookbooks/pivotal_workstation/attributes/git_pairs.rb +4 -0
- data/cookbooks/pivotal_workstation/attributes/git_projects.rb +3 -0
- data/cookbooks/pivotal_workstation/attributes/gitx.rb +2 -0
- data/cookbooks/pivotal_workstation/attributes/java.rb +1 -0
- data/cookbooks/pivotal_workstation/attributes/libreoffice.rb +3 -0
- data/cookbooks/pivotal_workstation/attributes/nginx.rb +11 -0
- data/cookbooks/pivotal_workstation/attributes/postgres.rb +3 -0
- data/cookbooks/pivotal_workstation/attributes/rubymine.rb +4 -0
- data/cookbooks/pivotal_workstation/attributes/rvm.rb +8 -0
- data/cookbooks/pivotal_workstation/attributes/skype.rb +1 -0
- data/cookbooks/pivotal_workstation/attributes/versions.rb +7 -0
- data/cookbooks/pivotal_workstation/libraries/bash_profile_include.rb +11 -0
- data/cookbooks/pivotal_workstation/libraries/brew.rb +31 -0
- data/cookbooks/pivotal_workstation/libraries/directories.rb +25 -0
- data/cookbooks/pivotal_workstation/libraries/marker.rb +42 -0
- data/cookbooks/pivotal_workstation/libraries/osx_app.rb +97 -0
- data/cookbooks/pivotal_workstation/libraries/rvm_ruby_install.rb +36 -0
- data/cookbooks/pivotal_workstation/libraries/user.rb +4 -0
- data/cookbooks/pivotal_workstation/libraries/version.rb +9 -0
- data/cookbooks/pivotal_workstation/recipes/ack.rb +1 -0
- data/cookbooks/pivotal_workstation/recipes/active_corners.rb +24 -0
- data/cookbooks/pivotal_workstation/recipes/bash_path_order.rb +13 -0
- data/cookbooks/pivotal_workstation/recipes/bash_profile-better_history.rb +3 -0
- data/cookbooks/pivotal_workstation/recipes/bash_profile-no_sudo_gem_install.rb +3 -0
- data/cookbooks/pivotal_workstation/recipes/bash_profile-ps1.rb +3 -0
- data/cookbooks/pivotal_workstation/recipes/bash_profile.rb +11 -0
- data/cookbooks/pivotal_workstation/recipes/chrome.rb +28 -0
- data/cookbooks/pivotal_workstation/recipes/defaults_fast_key_repeat_rate.rb +10 -0
- data/cookbooks/pivotal_workstation/recipes/disable_front_row.rb +4 -0
- data/cookbooks/pivotal_workstation/recipes/dock_preferences.rb +13 -0
- data/cookbooks/pivotal_workstation/recipes/ec2_api_tools.rb +3 -0
- data/cookbooks/pivotal_workstation/recipes/finder_display_full_path.rb +4 -0
- data/cookbooks/pivotal_workstation/recipes/firefox.rb +28 -0
- data/cookbooks/pivotal_workstation/recipes/fusion.rb +29 -0
- data/cookbooks/pivotal_workstation/recipes/gem_no_rdoc_no_ri.rb +7 -0
- data/cookbooks/pivotal_workstation/recipes/git.rb +8 -0
- data/cookbooks/pivotal_workstation/recipes/git_config_global_defaults.rb +71 -0
- data/cookbooks/pivotal_workstation/recipes/git_projects.rb +29 -0
- data/cookbooks/pivotal_workstation/recipes/git_scripts.rb +20 -0
- data/cookbooks/pivotal_workstation/recipes/gitx.rb +25 -0
- data/cookbooks/pivotal_workstation/recipes/global_environment_variables.rb +3 -0
- data/cookbooks/pivotal_workstation/recipes/homebrew.rb +27 -0
- data/cookbooks/pivotal_workstation/recipes/imagemagick.rb +3 -0
- data/cookbooks/pivotal_workstation/recipes/inputrc.rb +6 -0
- data/cookbooks/pivotal_workstation/recipes/iterm_set_defaults.rb +167 -0
- data/cookbooks/pivotal_workstation/recipes/java.rb +29 -0
- data/cookbooks/pivotal_workstation/recipes/joe.rb +3 -0
- data/cookbooks/pivotal_workstation/recipes/libreoffice.rb +28 -0
- data/cookbooks/pivotal_workstation/recipes/lion_basedev.rb +23 -0
- data/cookbooks/pivotal_workstation/recipes/mysql.rb +44 -0
- data/cookbooks/pivotal_workstation/recipes/nginx.rb +46 -0
- data/cookbooks/pivotal_workstation/recipes/osx_turn_on_locate.rb +8 -0
- data/cookbooks/pivotal_workstation/recipes/postgres.rb +71 -0
- data/cookbooks/pivotal_workstation/recipes/remove_garageband.rb +11 -0
- data/cookbooks/pivotal_workstation/recipes/rubymine.rb +30 -0
- data/cookbooks/pivotal_workstation/recipes/rubymine_preferences_pivotal.rb +36 -0
- data/cookbooks/pivotal_workstation/recipes/rvm.rb +58 -0
- data/cookbooks/pivotal_workstation/recipes/safari_preferences.rb +4 -0
- data/cookbooks/pivotal_workstation/recipes/screen_sharing_on.rb +16 -0
- data/cookbooks/pivotal_workstation/recipes/selenium_webdriver.rb +24 -0
- data/cookbooks/pivotal_workstation/recipes/set_finder_show_hd_on_desktop.rb +4 -0
- data/cookbooks/pivotal_workstation/recipes/set_multitouch_preferences.rb +9 -0
- data/cookbooks/pivotal_workstation/recipes/set_ntp_server.rb +3 -0
- data/cookbooks/pivotal_workstation/recipes/set_screensaver_preferences.rb +21 -0
- data/cookbooks/pivotal_workstation/recipes/size_up.rb +18 -0
- data/cookbooks/pivotal_workstation/recipes/skype.rb +28 -0
- data/cookbooks/pivotal_workstation/recipes/ssh_copy_id.rb +3 -0
- data/cookbooks/pivotal_workstation/recipes/sshd_on.rb +16 -0
- data/cookbooks/pivotal_workstation/recipes/ssl_certificate.rb +50 -0
- data/cookbooks/pivotal_workstation/recipes/terminal_preferences.rb +9 -0
- data/cookbooks/pivotal_workstation/recipes/textmate.rb +24 -0
- data/cookbooks/pivotal_workstation/recipes/textmate_plugins.rb +31 -0
- data/cookbooks/pivotal_workstation/recipes/textmate_set_defaults.rb +84 -0
- data/cookbooks/pivotal_workstation/recipes/user_owns_usr_local.rb +8 -0
- data/cookbooks/pivotal_workstation/recipes/vim.rb +35 -0
- data/cookbooks/pivotal_workstation/recipes/workspace_directory.rb +5 -0
- data/cookbooks/pivotal_workstation/templates/default/bash_profile-better_history.sh.erb +4 -0
- data/cookbooks/pivotal_workstation/templates/default/bash_profile-ec2_tools.sh.erb +5 -0
- data/cookbooks/pivotal_workstation/templates/default/bash_profile-no_sudo_gem_install.sh.erb +2 -0
- data/cookbooks/pivotal_workstation/templates/default/bash_profile-ps1.sh.erb +26 -0
- data/cookbooks/pivotal_workstation/templates/default/bash_profile-rvm.sh.erb +1 -0
- data/cookbooks/pivotal_workstation/templates/default/bash_profile.erb +6 -0
- data/cookbooks/pivotal_workstation/templates/default/git_scripts_pairs.erb +10 -0
- data/cookbooks/pivotal_workstation/templates/default/inputrc.erb +10 -0
- data/cookbooks/pivotal_workstation/templates/default/launchd.conf.erb +6 -0
- data/cookbooks/pivotal_workstation/templates/default/nginx.conf.erb +79 -0
- data/cookbooks/pivotal_workstation/templates/default/ntp.conf.erb +2 -0
- data/cookbooks/pivotal_workstation/templates/default/org.nginx.nginx.plist.erb +22 -0
- data/lib/pivotal_workstation_cookbook.rb +4 -0
- data/pivotal_workstation.gemspec +19 -0
- metadata +168 -0
@@ -0,0 +1,9 @@
|
|
1
|
+
execute "allow clicking by touch" do
|
2
|
+
command "defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Clicking 1"
|
3
|
+
user WS_USER
|
4
|
+
end
|
5
|
+
|
6
|
+
execute "allow dragging by touch" do
|
7
|
+
command "defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Dragging 1"
|
8
|
+
user WS_USER
|
9
|
+
end
|
@@ -0,0 +1,21 @@
|
|
1
|
+
execute "ask for password when screen is locked" do
|
2
|
+
command "defaults write com.apple.screensaver askForPassword -bool true"
|
3
|
+
user WS_USER
|
4
|
+
end
|
5
|
+
|
6
|
+
execute "wait 60 seconds between screensaver & lock" do
|
7
|
+
command "defaults write com.apple.screensaver askForPasswordDelay 60"
|
8
|
+
user WS_USER
|
9
|
+
end
|
10
|
+
|
11
|
+
plist_dir = ENV['HOME'] + "/Library/Preferences/ByHost"
|
12
|
+
Dir["#{plist_dir}/com.apple.screensaver.*.plist"].each do |file|
|
13
|
+
execute "set screensaver timeout" do
|
14
|
+
command "defaults write #{file.chomp(".plist")} idleTime 600"
|
15
|
+
user WS_USER
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
execute "set display, disk and computer sleep times" do
|
20
|
+
command "pmset -a displaysleep 20 disksleep 15 sleep 0"
|
21
|
+
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
run_unless_marker_file_exists("size_up") do
|
2
|
+
# The following doesn't work - it causes the checkbox to be enabled, but doesn't turn it on.
|
3
|
+
# other people want this feature, leaving this in to remind me or someone else
|
4
|
+
# to google for it in the future
|
5
|
+
# execute "turn on Access for Assistive Devices" do
|
6
|
+
# command "touch /private/var/db/.AccessibilityAPIEnabled"
|
7
|
+
# end
|
8
|
+
|
9
|
+
execute "download size_up" do
|
10
|
+
command "curl -o /tmp/sizeup.zip http://irradiatedsoftware.com/download/SizeUp.zip"
|
11
|
+
user WS_USER
|
12
|
+
end
|
13
|
+
|
14
|
+
execute "unzip sizeup" do
|
15
|
+
command "unzip /tmp/sizeup.zip SizeUp.app/* -d /Applications/"
|
16
|
+
user WS_USER
|
17
|
+
end
|
18
|
+
end
|
@@ -0,0 +1,28 @@
|
|
1
|
+
unless File.exists?("/Applications/Skype.app")
|
2
|
+
|
3
|
+
remote_file "/tmp/skype.dmg" do
|
4
|
+
source node["skype_download_uri"]
|
5
|
+
mode "0644"
|
6
|
+
end
|
7
|
+
|
8
|
+
execute "mount skype dmg" do
|
9
|
+
command "hdid /tmp/skype.dmg"
|
10
|
+
user WS_USER
|
11
|
+
end
|
12
|
+
|
13
|
+
execute "copy skype to /Applications" do
|
14
|
+
command "cp -rf /Volumes/Skype/Skype.app /Applications/"
|
15
|
+
user WS_USER
|
16
|
+
end
|
17
|
+
|
18
|
+
execute "unmount dmg" do
|
19
|
+
command "hdiutil detach /Volumes/Skype"
|
20
|
+
user WS_USER
|
21
|
+
end
|
22
|
+
|
23
|
+
ruby_block "test to see if Skype was installed" do
|
24
|
+
block do
|
25
|
+
raise "Skype install failed" unless File.exists?("/Applications/Skype.app")
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
@@ -0,0 +1,16 @@
|
|
1
|
+
execute "turn on ssh" do
|
2
|
+
command "systemsetup -setremotelogin on"
|
3
|
+
end
|
4
|
+
|
5
|
+
ruby_block "test to see if sshd is running" do
|
6
|
+
block do
|
7
|
+
require 'socket'
|
8
|
+
ssh_port = 22
|
9
|
+
begin
|
10
|
+
s = TCPSocket.open('localhost',ssh_port)
|
11
|
+
rescue => e
|
12
|
+
raise "sshd is not running: " << e
|
13
|
+
end
|
14
|
+
s.close
|
15
|
+
end
|
16
|
+
end
|
@@ -0,0 +1,50 @@
|
|
1
|
+
cert_path = node["ssl_settings"]["cert_path"]
|
2
|
+
ca_path = node["ssl_settings"]["ca_path"]
|
3
|
+
|
4
|
+
run_unless_marker_file_exists("ssl_certificate") do
|
5
|
+
["/usr/local", "/usr/local/etc", cert_path, "#{ca_path}", "#{ca_path}/keys", "#{ca_path}/requests", "#{ca_path}/certs", "#{ca_path}/newcerts"].each do |dir|
|
6
|
+
directory dir do
|
7
|
+
recursive true
|
8
|
+
owner WS_USER
|
9
|
+
end
|
10
|
+
end
|
11
|
+
|
12
|
+
execute "create database.txt" do
|
13
|
+
command "touch #{ca_path}/index.txt"
|
14
|
+
user WS_USER
|
15
|
+
end
|
16
|
+
|
17
|
+
execute "create serial" do
|
18
|
+
command "echo '01\n' > #{ca_path}/serial"
|
19
|
+
user WS_USER
|
20
|
+
end
|
21
|
+
|
22
|
+
execute "generate key" do
|
23
|
+
command "openssl genrsa -des3 -passout pass:password -out #{ca_path}/keys/ca.key 1024"
|
24
|
+
user WS_USER
|
25
|
+
end
|
26
|
+
|
27
|
+
execute "generate ca" do
|
28
|
+
command "cd #{ca_path} && openssl req -new -x509 -days 1001 -key #{ca_path}/keys/ca.key -passin pass:password -out #{ca_path}/certs/ca.cert -subj '/CN=mydomain.com/OU=Org Unit/O=My Org Pty Ltd/L=Sydney/ST=NSW/C=AU/emailAddr=someone@example.com'"
|
29
|
+
user WS_USER
|
30
|
+
end
|
31
|
+
|
32
|
+
execute "trust our CA" do
|
33
|
+
command "security add-trusted-cert -d -r trustRoot -k /Library/Keychains/System.keychain #{ca_path}/certs/ca.cert"
|
34
|
+
end
|
35
|
+
|
36
|
+
execute "generate server key" do
|
37
|
+
command "openssl genrsa 1024 > #{cert_path}/server.key"
|
38
|
+
user WS_USER
|
39
|
+
end
|
40
|
+
|
41
|
+
execute "generate request" do
|
42
|
+
command "openssl req -new -key #{cert_path}/server.key -out #{cert_path}/request.csr -subj '/CN=#{node["ssl_settings"]["common_name"]}/OU=Org Unit/O=My Org Pty Ltd/L=Sydney/ST=NSW/C=AU/emailAddr=someoneATexample.com'"
|
43
|
+
user WS_USER
|
44
|
+
end
|
45
|
+
|
46
|
+
execute "sign request with CA" do
|
47
|
+
command "cd #{cert_path} && openssl ca -policy policy_anything -cert #{ca_path}/certs/ca.cert -batch -in #{cert_path}/request.csr -passin pass:password -keyfile #{ca_path}/keys/ca.key -days 9999 -out #{cert_path}/signed.cert"
|
48
|
+
user WS_USER
|
49
|
+
end
|
50
|
+
end
|
@@ -0,0 +1,9 @@
|
|
1
|
+
execute "set terminal color scheme" do
|
2
|
+
command "defaults write com.apple.Terminal 'Default Window Settings' -string Homebrew"
|
3
|
+
user WS_USER
|
4
|
+
end
|
5
|
+
|
6
|
+
execute "set terminal color scheme" do
|
7
|
+
command "defaults write com.apple.Terminal 'Startup Window Settings' -string Homebrew"
|
8
|
+
user WS_USER
|
9
|
+
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
include_recipe "pivotal_workstation::user_owns_usr_local"
|
2
|
+
|
3
|
+
|
4
|
+
run_unless_marker_file_exists("text_mate_1_5_10") do
|
5
|
+
execute "download text mate to temp dir" do
|
6
|
+
command "curl -o /tmp/textmate.zip http://dl.macromates.com/TextMate_1.5.10_r1623.zip"
|
7
|
+
user WS_USER
|
8
|
+
end
|
9
|
+
|
10
|
+
execute "extract text mate to /Applications" do
|
11
|
+
command 'unzip -o /tmp/textmate.zip -x __MACOSX* -d /Applications/'
|
12
|
+
user WS_USER
|
13
|
+
end
|
14
|
+
|
15
|
+
execute "link textmate" do
|
16
|
+
command "ln -s /Applications/TextMate.app/Contents/Resources/mate /usr/local/bin/mate"
|
17
|
+
not_if "test -e /usr/local/bin/mate"
|
18
|
+
end
|
19
|
+
end
|
20
|
+
|
21
|
+
execute "link textmate" do
|
22
|
+
command "ln -s /Applications/TextMate.app/Contents/Resources/mate /usr/local/bin/mate"
|
23
|
+
not_if "test -e /usr/local/bin/mate"
|
24
|
+
end
|
@@ -0,0 +1,31 @@
|
|
1
|
+
run_unless_marker_file_exists("textmate_plugins_0") do
|
2
|
+
execute "download ProjectPlus to temp dir" do
|
3
|
+
command "curl -o /tmp/projectplus.dmg http://ciaranwal.sh/projectplus-files/ProjectPlus-1.3.dmg"
|
4
|
+
user WS_USER
|
5
|
+
end
|
6
|
+
|
7
|
+
execute "mount dmg" do
|
8
|
+
command "hdid /tmp/projectplus.dmg"
|
9
|
+
user WS_USER
|
10
|
+
end
|
11
|
+
|
12
|
+
execute "clear out the existing plugin if it's there" do
|
13
|
+
command "rm -rf '#{WS_HOME}/Library/Application Support/TextMate/PlugIns/ProjectPlus.tmplugin'"
|
14
|
+
end
|
15
|
+
|
16
|
+
execute "make textmate plugins directory" do
|
17
|
+
command "mkdir -p '#{WS_HOME}/Library/Application Support/TextMate/PlugIns'"
|
18
|
+
user WS_USER
|
19
|
+
not_if { File.exists?("#{WS_HOME}/Library/Application Support/TextMate/PlugIns") }
|
20
|
+
end
|
21
|
+
|
22
|
+
execute "copy to TextMate" do
|
23
|
+
command "cp -Rf /Volumes/ProjectPlus/ProjectPlus.tmplugin '#{WS_HOME}/Library/Application Support/TextMate/PlugIns'"
|
24
|
+
user WS_USER
|
25
|
+
end
|
26
|
+
|
27
|
+
execute "unmount dmg" do
|
28
|
+
command "hdiutil detach /Volumes/ProjectPlus"
|
29
|
+
user WS_USER
|
30
|
+
end
|
31
|
+
end
|
@@ -0,0 +1,84 @@
|
|
1
|
+
include_recipe "pivotal_workstation::textmate"
|
2
|
+
|
3
|
+
execute "set save on losing focus" do
|
4
|
+
command "defaults write ~/Library/Preferences/com.macromates.textmate OakSaveAllOnDeactivate -bool TRUE"
|
5
|
+
user WS_USER
|
6
|
+
end
|
7
|
+
|
8
|
+
execute "show line numbers" do
|
9
|
+
command "defaults write ~/Library/Preferences/com.macromates.textmate OakTextViewLineNumbersEnabled -bool TRUE"
|
10
|
+
user WS_USER
|
11
|
+
end
|
12
|
+
|
13
|
+
gem_package("plist")
|
14
|
+
|
15
|
+
ruby_block "soft tabs & tabs stop of 2" do
|
16
|
+
block do
|
17
|
+
|
18
|
+
Gem.clear_paths
|
19
|
+
require 'rubygems'
|
20
|
+
|
21
|
+
require 'plist'
|
22
|
+
require 'time'
|
23
|
+
# FIXME: if plist doesn't exist, create it.
|
24
|
+
plist_file = "#{ENV['HOME']}/Library/Preferences/com.macromates.textmate.plist"
|
25
|
+
`plutil -convert xml1 #{plist_file}`
|
26
|
+
tmate_plist = Plist::parse_xml(plist_file)
|
27
|
+
tmate_plist["OakTextViewLineNumbersEnabled"] = true
|
28
|
+
tmate_plist["OakTextViewScopedSoftTabs"] =
|
29
|
+
{ "source.catch-all" =>
|
30
|
+
{ "softTabs" => false,
|
31
|
+
"updated" => Time.parse("2011-07-14T18:59:17Z")
|
32
|
+
},
|
33
|
+
"source.plist" =>
|
34
|
+
{ "softTabs" => true,
|
35
|
+
"updated" => Time.parse("0000-12-30T00:00:00Z")
|
36
|
+
},
|
37
|
+
"source.ruby" =>
|
38
|
+
{ "softTabs" => true,
|
39
|
+
"updated" => Time.parse("0000-12-30T00:00:00Z")
|
40
|
+
},
|
41
|
+
"source.yaml" =>
|
42
|
+
{ "softTabs" => true,
|
43
|
+
"updated" => Time.parse("0000-12-30T00:00:00Z")
|
44
|
+
},
|
45
|
+
"text.catch-all" =>
|
46
|
+
{ "softTabs" => false,
|
47
|
+
"updated" => Time.parse("2011-07-14T18:59:17Z")
|
48
|
+
},
|
49
|
+
"text.plain" =>
|
50
|
+
{ "softTabs" => true,
|
51
|
+
"updated" => Time.parse("0000-12-30T00:00:00Z")
|
52
|
+
}
|
53
|
+
}
|
54
|
+
tmate_plist["OakTextViewScopedTabSize"] =
|
55
|
+
{ "source.catch-all" =>
|
56
|
+
{ "tabSize" => 4,
|
57
|
+
"updated" => Time.parse("2011-07-14T18:59:17Z")
|
58
|
+
},
|
59
|
+
"source.plist" =>
|
60
|
+
{ "tabSize" => 2,
|
61
|
+
"updated" => Time.parse("0000-12-30T00:00:00Z")
|
62
|
+
},
|
63
|
+
"source.ruby" =>
|
64
|
+
{ "tabSize" => 2,
|
65
|
+
"updated" => Time.parse("0000-12-30T00:00:00Z")
|
66
|
+
},
|
67
|
+
"source.yaml" =>
|
68
|
+
{ "tabSize" => 2,
|
69
|
+
"updated" => Time.parse("0000-12-30T00:00:00Z")
|
70
|
+
},
|
71
|
+
"text.catch-all" =>
|
72
|
+
{ "tabSize" => 4,
|
73
|
+
"updated" => Time.parse("2011-07-14T18:59:17Z")
|
74
|
+
},
|
75
|
+
"text.plain" =>
|
76
|
+
{ "tabSize" => 2,
|
77
|
+
"updated" => Time.parse("0000-12-30T00:00:00Z")
|
78
|
+
}
|
79
|
+
}
|
80
|
+
puts Plist::Emit.dump(tmate_plist["OakTextViewScopedTabSize"])
|
81
|
+
plist_handle = File.open(plist_file, "w")
|
82
|
+
plist_handle.puts Plist::Emit.dump(tmate_plist)
|
83
|
+
end
|
84
|
+
end
|
@@ -0,0 +1,35 @@
|
|
1
|
+
::VIM_HOME = "#{WS_HOME}/.vim"
|
2
|
+
include_recipe "pivotal_workstation::homebrew"
|
3
|
+
include_recipe "pivotal_workstation::ack"
|
4
|
+
include_recipe "pivotal_workstation::git"
|
5
|
+
|
6
|
+
brew_install "macvim"
|
7
|
+
|
8
|
+
execute "clone the .vim directory" do
|
9
|
+
user WS_USER
|
10
|
+
command "git clone https://github.com/pivotal/vim-config.git #{VIM_HOME}"
|
11
|
+
not_if "cd #{VIM_HOME} && git remote -v | grep pivotal/vim-config"
|
12
|
+
end
|
13
|
+
|
14
|
+
execute "ensure we're on the approved hash" do
|
15
|
+
user WS_USER
|
16
|
+
command "cd #{VIM_HOME} && git checkout a3d2e49c04cb9258b195"
|
17
|
+
end
|
18
|
+
|
19
|
+
execute "get the submodules" do
|
20
|
+
user WS_USER
|
21
|
+
command "cd #{VIM_HOME} && git submodule update --init"
|
22
|
+
end
|
23
|
+
|
24
|
+
link "#{WS_HOME}/.vimrc" do
|
25
|
+
to "#{VIM_HOME}/vimrc"
|
26
|
+
owner WS_USER
|
27
|
+
end
|
28
|
+
|
29
|
+
brew_install "ctags"
|
30
|
+
|
31
|
+
execute "compile command-t" do
|
32
|
+
cwd "#{VIM_HOME}/bundle/command-t/ruby/command-t"
|
33
|
+
command "ruby extconf.rb && make"
|
34
|
+
user WS_USER
|
35
|
+
end
|
@@ -0,0 +1,5 @@
|
|
1
|
+
export JAVA_HOME="/System/Library/Frameworks/JavaVM.framework/Home"
|
2
|
+
export EC2_HOME="/usr/local/Cellar/ec2-api-tools/1.3-62308/jars"
|
3
|
+
|
4
|
+
test -e $HOME/.ec2/pk-*.pem && export EC2_PRIVATE_KEY="$(/bin/ls $HOME/.ec2/pk-*.pem)"
|
5
|
+
test -e $HOME/.ec2/cert-* && export EC2_CERT="$(/bin/ls $HOME/.ec2/cert-*.pem)"
|
@@ -0,0 +1,26 @@
|
|
1
|
+
parse_git_branch() {
|
2
|
+
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
|
3
|
+
}
|
4
|
+
export -f parse_git_branch
|
5
|
+
|
6
|
+
parse_svn_branch() {
|
7
|
+
parse_svn_url | sed -e 's#^'"$(parse_svn_repository_root)"'##g' | awk -F / '{print "(svn::"$1 "/" $2 ")"}'
|
8
|
+
}
|
9
|
+
export -f parse_svn_branch
|
10
|
+
|
11
|
+
parse_svn_url() {
|
12
|
+
svn info 2>/dev/null | grep -e '^URL*' | sed -e 's#^URL: *\(.*\)#\1#g '
|
13
|
+
}
|
14
|
+
export -f parse_svn_url
|
15
|
+
|
16
|
+
parse_svn_repository_root() {
|
17
|
+
svn info 2>/dev/null | grep -e '^Repository Root:*' | sed -e 's#^Repository Root: *\(.*\)#\1\/#g '
|
18
|
+
}
|
19
|
+
export -f parse_svn_repository_root
|
20
|
+
|
21
|
+
export SUDO_PS1='\[\e[0;31m\]\u\[\e[m\] \[\e[1;34m\]\w\[\e[m\] \[\e[0;31m\]\$ \[\e[0m\]'
|
22
|
+
export PS1="\h:\w \$(parse_git_branch)$ "
|
23
|
+
|
24
|
+
export CLICOLOR=1
|
25
|
+
export PS1="\[\033[36m\]\h:\w \[\033[33m\]\$(parse_svn_branch)\$(parse_git_branch)\[\033[00m\]$\[\033[00m\] "
|
26
|
+
|
@@ -0,0 +1 @@
|
|
1
|
+
source ${HOME}/.rvm/scripts/rvm;
|
@@ -0,0 +1,10 @@
|
|
1
|
+
pairs:
|
2
|
+
<% node.git_pairs_authors.each do |half_pair| %>
|
3
|
+
<%= "#{half_pair["initials"]}: #{half_pair["name"]}"%><%= half_pair["shortname"] ? "; #{half_pair["shortname"]}" : "" %>
|
4
|
+
<% end %>
|
5
|
+
|
6
|
+
email:
|
7
|
+
prefix: pair
|
8
|
+
domain: pivotallabs.com
|
9
|
+
|
10
|
+
global: true
|