replace documentation with scripts

This commit is contained in:
Morgan Wattiez 2019-07-25 21:38:04 +02:00
parent fff673825e
commit 6d8500b7c1
5 changed files with 85 additions and 61 deletions

View File

@ -1,34 +1,26 @@
### Use SDKMan to install development tools
```
curl -s "https://get.sdkman.io" | bash
sdk install java
sdk install gradle
sdk install java 8.0.202-zulu
```
### Run
run `.scripts/bootstrap.sh`
### Install Docker Desktop for Mac
```
~/.scripts/executable_bootstrap.sh
```
### Reload
run `zsh .scripts/reload.sh`
### Install dependencies (apps, fonts, ...) with Brew
`brew bundle`
### Upgrade
run `zsh .scripts/upgrade.sh`
### Install asciidoctor-pdf
`sudo gem install -n /usr/local/bin asciidoctor-pdf --pre`
### Scope
* Use SDKMan to install development tools
* Install Docker Desktop for Mac
* Install asciidoctor-pdf
* Install Oh My Zsh and some cool dependencies
* OSX Defaults
* Install NPM dependencies
* Install pip and pipenv
* Install AWS-CLI
### Install Oh My Zsh and some cool dependencies
```
sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
git clone https://github.com/bhilburn/powerlevel9k.git ~/.oh-my-zsh/custom/themes/powerlevel9
git clone https://github.com/AlexisBRENON/oh-my-zsh-reminder ~/.oh-my-zsh/custom/plugins/reminder
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting
git clone https://github.com/zsh-users/zsh-autosuggestions ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions
```
#### In order to upgrade it, just run
`upgrade_oh_my_zsh`
### If Yubico is installed, run this :
`sudo ansible-playbook ~/Code/dotfiles/macsecure_playbook.yaml`
### In cases of `\n` errors with zsh
#### In cases of `\n` errors with zsh
https://github.com/robbyrussell/oh-my-zsh/issues/6764#issuecomment-384045008
```
cd $ZSH
@ -37,38 +29,4 @@ git rm --cached -r .
git reset --hard
```
### OSX Defaults
```
sudo sh .macos
```
### Install NPM dependencies
`npm install -g jira-node-cli`
### Install pip and pipenv
```
sudo easy_install pip
sudo pip install --upgrade pip
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
sudo python3 get-pip.py
sudo pip3 install --upgrade pip
ln -s /usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/bin/pip pip3
export PATH=$PATH:/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/bin/
pip3 install pipenv
```
### Install AWS-CLI
```
pip3 install boto3
pip3 install awscli
```
### If Yubico is installed, run this :
`sudo ansible-playbook ~/Code/dotfiles/macsecure_playbook.yaml`
## Upgrades
### Upgrade dependencies with Brew
`brew outdated | xargs brew upgrade`

48
dot_scripts/bootstrap.sh Executable file
View File

@ -0,0 +1,48 @@
# Use SDKMan to install development tools
curl -s "https://get.sdkman.io" | bash
sdk install java
sdk install gradle
sdk install java 8.0.202-zulu
# Install Docker Desktop for Mac
~/.scripts/executable_bootstrap.sh
# Install dependencies (apps, fonts, ...) with Brew
brew bundle
# Install asciidoctor-pdf
sudo gem install -n /usr/local/bin asciidoctor-pdf --pre
# Install Oh My Zsh and some cool dependencies
sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
git clone https://github.com/bhilburn/powerlevel9k.git ~/.oh-my-zsh/custom/themes/powerlevel9
git clone https://github.com/AlexisBRENON/oh-my-zsh-reminder ~/.oh-my-zsh/custom/plugins/reminder
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting
git clone https://github.com/zsh-users/zsh-autosuggestions ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions
# OSX Defaults
sudo sh .macos
# Install NPM dependencies
npm install -g jira-node-cli --save
# Install pip and pipenv
sudo easy_install pip
sudo pip install --upgrade pip
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
sudo python3 get-pip.py
sudo pip3 install --upgrade pip
ln -s /usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/bin/pip pip3
export PATH=$PATH:/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/bin/
pip3 install pipenv
# Install AWS-CLI
pip3 install boto3
pip3 install awscli
# Upgrade
upgrade.sh
# Reload
reload.sh

6
dot_scripts/reload.sh Normal file
View File

@ -0,0 +1,6 @@
#!/usr/bin/env zsh
source ~/.zshrc
sdk use java 8.0.202-zulu
brew bundle
# OSX Defaults
sudo sh .macos

12
dot_scripts/upgrade.sh Normal file
View File

@ -0,0 +1,12 @@
sdk selfupdate
brew update
#brew upgrade
brew outdated | xargs brew upgrade
gem update --system
gem update asciidoctor-pdf
upgrade_oh_my_zsh
npm update -g jira-node-cli --save
sudo pip install --upgrade pip
sudo pip3 install --upgrade pip

View File

@ -105,6 +105,6 @@ sh ~/.scripts/resume.sh
export SDKMAN_DIR="$HOME/.sdkman"
[[ -s "$SDKMAN_DIR/bin/sdkman-init.sh" ]] && source "$SDKMAN_DIR/bin/sdkman-init.sh"
sdk use java 8.0.202-zulu
#sdk use java 8.0.202-zulu
export PATH=$PATH:/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/bin/
export PATH="/usr/local/opt/grep/libexec/gnubin:$PATH"