-
Notifications
You must be signed in to change notification settings - Fork 0
/
install-ppl-bpl.sh
69 lines (45 loc) · 2.22 KB
/
install-ppl-bpl.sh
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
printf "Start of Script File \n" > ~/dotfiles/DotfilesLog.txt
printf "PWD= $PWD \n" >> ~/dotfiles/DotfilesLog.txt
printf "DOGVAR= $DOGVAR \n">> ~/dotfiles/DotfilesLog.txt
printf "\n Local Workspace = $localWorkspaceFolder \n" >> ~/dotfiles/DotfilesLog.txt
printf "\n Container Workspace = $containerWorkspaceFolder \n" >> ~/dotfiles/DotfilesLog.txt
## copy git files to Codespace Project Home directory
## cp ~/dotfiles/.gitignore $PWD
## cp ~/dotfiles/.gitconfig $PWD
## Update to the latest PowerShell
curl -sSL https://raw.githubusercontent.com/PowerShell/PowerShell/master/tools/install-powershell.sh | bash
pwsh powerlineinstaller.ps1
mkdir -p /root/.config/powershell/ && cp ~/dotfiles/mypwshprofile.ps1 /root/.config/powershell/Microsoft.PowerShell_profile.ps1
printf "\n pwsh powerline complete \n" >> ~/dotfiles/DotfilesLog.txt
printf "Start of bash powerline \n" >> ~/dotfiles/DotfilesLog.txt
cd ~
wget https://golang.org/dl/go1.15.2.linux-amd64.tar.gz
tar xvf go1.15.2.linux-amd64.tar.gz
mv go /usr/local
mkdir go
rm go1.15.2.linux-amd64.tar.gz
printf "wget, tar, etc complete \n" >> ~/dotfiles/DotfilesLog.txt
export GOROOT=/usr/local/go
export GOPATH=$HOME/go
export PATH=$PATH:$GOROOT/bin:$GOPATH
printf "GOROOT = $GOROOT \n" >> ~/dotfiles/DotfilesLog.txt
printf "GOPATH = $GOPATH \n" >> ~/dotfiles/DotfilesLog.txt
printf "PATH = $PATH \n" >> ~/dotfiles/DotfilesLog.txt
printf "export complete \n" >> ~/dotfiles/DotfilesLog.txt
cd ~
go get -u github.com/justjanne/powerline-go
printf "powerline complete \n" >> ~/dotfiles/DotfilesLog.txt
echo 'export GOROOT=/usr/local/go' >>/root/.bashrc
echo 'export GOPATH=$HOME/go' >>/root/.bashrc
echo 'export PATH=$PATH:$GOROOT/bin:$GOPATH' >>/root/.bashrc
printf "GOROOT = $GOROOT \n" >> ~/dotfiles/DotfilesLog.txt
printf "GOPATH = $GOPATH \n" >> ~/dotfiles/DotfilesLog.txt
printf "PATH = $PATH \n" >> ~/dotfiles/DotfilesLog.txt
echo 'function _update_ps1() {
PS1="$($GOPATH/bin/powerline-go -error $?)"
}
if [ "$TERM" != "linux" ] && [ -f "$GOPATH/bin/powerline-go" ]; then
PROMPT_COMMAND="_update_ps1; $PROMPT_COMMAND"
fi' >>/root/.bashrc
printf "bashrc complete \n" >> ~/dotfiles/DotfilesLog.txt
printf "End of Script File \n" >> ~/dotfiles/DotfilesLog.txt