forked from freekmurze/dotfiles
-
Notifications
You must be signed in to change notification settings - Fork 1
/
installscript
executable file
·167 lines (129 loc) · 4.7 KB
/
installscript
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
#!/bin/bash
# Hide "last login" line when starting a new terminal session
touch $HOME/.hushlogin
# Install zsh
echo 'Install oh-my-zsh'
echo '-----------------'
rm -rf $HOME/.oh-my-zsh
curl -L https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh | sh
# Add global gitignore
ln -s $HOME/.dotfiles/shell/.global-gitignore $HOME/.global-gitignore
git config --global core.excludesfile $HOME/.global-gitignore
# Symlink zsh prefs
rm $HOME/.zshrc
ln -s $HOME/.dotfiles/shell/.zshrc $HOME/.zshrc
# Symlink vim prefs
rm $HOME/.vimrc
ln -s $HOME/.dotfiles/shell/.vimrc $HOME/.vimrc
rm $HOME/.vim
ln -s $HOME/.dotfiles/shell/.vim $HOME/.vim
# Symlink yarn prefs
rm $HOME/.yarnrc
ln -s $HOME/.dotfiles/shell/.yarnrc $HOME/.yarnrc
# Symlink the Mackup config
ln -s $HOME/.dotfiles/macos/.mackup.cfg $HOME/.mackup.cfg
# Fix missing font characters (see https://github.com/robbyrussell/oh-my-zsh/issues/1906)
cd ~/.oh-my-zsh/themes/
git checkout d6a36b1 agnoster.zsh-theme
# Activate z
cd ~/.dotfiles/shell
chmod +x z.sh
echo 'Install composer'
echo '----------------'
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
php -r "if (hash_file('sha384', 'composer-setup.php') === 'a5c698ffe4b8e849a443b120cd5ba38043260d5c4023dbf93e1558871f1f07f58274fc6f4c93bcfd858c6bd0775cd8d1') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
php composer-setup.php
php -r "unlink('composer-setup.php');"
mv composer.phar /usr/local/bin/composer
echo 'Install homebrew'
echo '----------------'
echo install homebrew
sudo rm -rf /usr/local/Cellar /usr/local/.git && brew cleanup
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
echo 'Install node'
echo '-----------'
brew install node@11
echo 'Install pkg-config'
echo '------------------'
brew install pkg-config
echo 'Install wget'
echo '------------'
brew install wget --overwrite
echo 'Install httpie'
echo '--------------'
brew install httpie
echo 'Install ncdu'
echo '------------'
brew install ncdu
echo 'Install hub'
echo '-----------'
brew install hub
echo 'Install ack'
echo '-----------'
brew install ack
echo 'Install brew-cask'
echo '-----------------'
brew tap caskroom/cask
brew install brew-cask
echo 'Install some nice quicklook plugins'
echo '-----------------------------------'
brew cask install --force qlcolorcode qlstephen qlmarkdown quicklook-json qlprettypatch quicklook-csv betterzipql webp-quicklook suspicious-package
echo 'Install php'
echo '-----------'
brew install php@7.0
brew install php@7.1
brew install php@7.2
brew install php@7.4
echo 'Install imagemagick'
echo '-------------------'
brew install imagemagick
echo 'Install imagick'
echo '---------------'
pecl install imagick
echo 'Install memcached'
echo '-----------------'
pecl install memcached
echo 'Install xdebug'
echo '--------------'
pecl install xdebug
echo 'Install redis'
echo '-------------'
pecl install redis
echo 'Install php-cs-fixer'
echo '--------------------'
composer global require friendsofphp/php-cs-fixer
echo 'Install laravel envoy'
echo '---------------------'
composer global require "laravel/envoy=~1.0"
echo 'Install phpunit-watcher'
echo '-----------------------'
composer global require spatie/phpunit-watcher
echo 'Install mixed-content-scanner-cli'
echo '---------------------------------'
composer global require spatie/mixed-content-scanner-cli
echo 'Install Valet Plus'
echo '---------------------'
composer global require weprovide/valet-plus
valet install
echo 'Install yarn'
echo '------------'
brew install yarn --without-node
echo 'Install mackup'
echo '--------------'
brew install mackup
echo 'Install zsh-autosuggestions'
echo '---------------------------'
brew install zsh-autosuggestions
echo '++++++++++++++++++++++++++++++'
echo '++++++++++++++++++++++++++++++'
echo 'All done!'
echo 'Things to do to make the agnoster terminal theme work:'
echo '1. Install menlo patched font included in ~/.dotfiles/misc https://gist.github.com/qrush/1595572/raw/Menlo-Powerline.otf'
echo '2. Install patched solarized theme included in ~/.dotfiles/misc'
echo '++++++++++++++++++++++++++++++'
echo 'Some optional tidbits'
echo '1. Make sure dropbox is running first. If you have not backed up via Mackup yet, then run `mackup backup` to symlink preferences for a wide collection of apps to your dropbox. If you already had a backup via mackup run `mackup restore` You'\''ll find more info on Mackup here: https://github.com/lra/mackup.'
echo '2. Set some sensible os x defaults by running: $HOME/.dotfiles/macos/set-defaults.sh'
echo '3. Make a .dotfiles-custom/shell/.aliases for your personal commands'
echo '++++++++++++++++++++++++++++++'
echo '++++++++++++++++++++++++++++++'