-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathutils.sh
41 lines (33 loc) · 1.17 KB
/
utils.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
# go to the root of the plutus-apps repo
alias gtpa='cd /workspaces/ppp-3/plutus-apps'
# start a nix-shell
alias nxs='pushd /workspaces/ppp-3/plutus-apps && nix-shell && popd'
# start a playground server
alias spps='pushd /workspaces/ppp-3/plutus-apps && nix-shell --command "cd plutus-playground-client && plutus-playground-server"; popd'
# start a playground client
alias sppc='pushd /workspaces/ppp-3/plutus-apps && nix-shell --command "cd plutus-playground-client && npm start"; popd'
# read the docs
alias docs='pushd /workspaces/ppp-3/plutus-apps && nix-shell --command build-and-serve-docs; popd'
# go to a week in the plutus pioneer program repo
gtppp () {
if [ $# -eq 0 ]
then
cd /workspaces/ppp-3/plutus-pioneer-program
else
cd /workspaces/ppp-3/plutus-pioneer-program/code/$1
fi
}
# checkout tag in the plutus-apps repo
cpa() {
git --git-dir /workspaces/ppp-3/plutus-apps/.git checkout "$1" ;
}
# get the week's plutus-apps.git tag
gwpat() {
cat cabal.project | \
grep 'plutus-apps.git' -A 1 | \
grep tag | \
cut -d : -f 2 | \
tr -d '[:space:]'
}
# load nix stuff
. /home/vscode/.nix-profile/etc/profile.d/nix.sh