summaryrefslogtreecommitdiffstats
path: root/README.md
blob: a3ef960768037ee9b87fbae7d044d2122c5a1961 (plain) (blame)
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
# Prerequisites :
Install xcode and homebrew

```bash
xcode-select --install
git clone https://github.com/a14m/.rc.git ~/.rc
cd ~/.rc

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew tap Homebrew/bundle
brew bundle
```

# Installation :

- Essentials
```bash
ln -sf ~/.rc/.bash_profile ~/.bash_profile
ln -sf ~/.rc/.editorconfig ~/.editorconfig
ln -sf ~/.rc/.inputrc ~/.inputrc
ln -sf ~/.rc/.screenrc ~/.screenrc
ln -sf ~/.rc/.netrc ~/.netrc
ln -sf ~/.rc/.terraformrc ~/.terraformrc
ln -sf ~/.rc/.tmux.conf ~/.tmux.conf
chmod 600 ~/.netrc
chmod 600 ~/.terraformrc

ln -sf ~/.rc/.gitconfig ~/.gitconfig
ln -sf ~/.rc/.gitignore_global ~/.gitignore_global

mkdir -p ~/.aws
ln -sf ~/.rc/.aws/config ~/.aws/config
ln -sf ~/.rc/.aws/credentials ~/.aws/credentials

mkdir -p ~/.config/htop ~/.config/tmuxinator ~/.config/wtf
ln -sf ~/.rc/.config/htop/htoprc ~/.config/htop/htoprc
ln -sf ~/.rc/.config/wtf/config.yml ~/.config/wtf/config.yml

sudo bash -c 'echo /usr/local/bin/bash >> /etc/shells'
chsh -s /usr/local/bin/bash

git remote remove origin
git remote add origin [email protected]:a14m/.rc.git
```
- Load pgp key from card and trust it
```bash
gpg --edit-card
> fetch

gpg --edit-key [email protected]
> trust
```

- Setup ruby/rbenv
```bash
mkdir -p ~/.bundle
ln -sf ~/.rc/.bundle/config ~/.bundle/config

git clone https://github.com/sstephenson/rbenv-gem-rehash.git ~/.rbenv/plugins/rbenv-gem-rehash
git clone https://github.com/sstephenson/rbenv-vars.git ~/.rbenv/plugins/rbenv-vars
git clone https://github.com/tpope/rbenv-ctags.git ~/.rbenv/plugins/rbenv-ctags
git clone https://github.com/sstephenson/rbenv-default-gems.git ~/.rbenv/plugins/rbenv-default-gems
git clone https://github.com/rkh/rbenv-update.git ~/.rbenv/plugins/rbenv-update

ln -sf ~/.rc/.gemrc ~/.gemrc
ln -sf ~/.rc/.rbenv/default-gems ~/.rbenv/default-gems
rbenv install $(cat ~/.rc/.rbenv/version)
ln -sf ~/.rc/.rbenv/version ~/.rbenv/version
```

- Setup rust
```bash
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
```

- Setup node/nvm
```bash
mkdir -p ~/.nvm
ln -sf ~/.rc/.npmrc ~/.npmrc
ln -sf ~/.rc/.nvmrc ~/.nvmrc
ln -sf ~/.rc/.nvm/default-packages ~/.nvm/default-packages
nvm install
nvm alias default
```

- Decrypt secrets
```bash
source ~/.bash_profile
git-crypt unlock
```

- Other Useful tools setup
```bash
# Install pow
curl get.pow.cx | sh
ln -sf ~/.rc/.powconfig ~/.powconfig

# Uninstall pow
curl get.pow.cx/uninstall.sh | sh
```

- Setup password store
```bash
git clone [email protected]:a14m/.pass ~/.password-store
```

- Fix Kali Linux Timezone
```bash
sudo apt-get install ntpdate
sudo ntpdate in.pool.ntp.org
```