-
Notifications
You must be signed in to change notification settings - Fork 3
/
install
executable file
·26 lines (18 loc) · 921 Bytes
/
install
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
#!/bin/bash
REPOSITORY_URI="https://github.com/moacirosa/git-current-contributors.git"
git clone ${REPOSITORY_URI} ~/.git-current-contributors
echo "### Adding custom git command 'git-current-contributors' @moacirosa" >> ~/.bashrc
echo "export PATH=${PATH}:~/.git-current-contributors" >> ~/.bashrc
echo "export MANPATH=${PATH}:~/.git-current-contributors/man" >> ~/.bashrc
source ~/.bashrc
# Include PATHs for oh-my-zsh as well when it's present
ZSH_FILE=~/.zshrc
if [ -e "$ZSH_FILE" ]
then
echo "### Adding custom git command 'git-current-contributors' @moacirosa" >> ~/.zshrc
echo "export PATH=${PATH}:~/.git-current-contributors" >> ~/.zshrc
echo "export MANPATH=${PATH}:~/.git-current-contributors/man" >> ~/.zshrc
fi
echo "Custom git command 'git-current-contributors' was successfully installed"
echo "Check new command availability by running 'git help -a'"
echo "More info visit ${REPOSITORY_URI}"