bin/homedir-setup

Thu, 23 Jan 2025 22:29:09 -0600

author
Meredith Howard <mhoward@roomag.org>
date
Thu, 23 Jan 2025 22:29:09 -0600
changeset 1183
c5735f6254b1
parent 1182
222bbbc217cc
permissions
-rwxr-xr-x

Remove asdf

964
72a7a0ffbce8 retire plenv for asdf
Meredith Howard <mhoward@roomag.org>
parents: 850
diff changeset
1 #!/bin/bash
72a7a0ffbce8 retire plenv for asdf
Meredith Howard <mhoward@roomag.org>
parents: 850
diff changeset
2 set -euo pipefail
245
9fa186a70bbd add .homedir-setup.sh
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
3
969
28111ba4e573 move to util lib
Meredith Howard <mhoward@roomag.org>
parents: 967
diff changeset
4 source .lib/sh/util.sh
245
9fa186a70bbd add .homedir-setup.sh
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
5
967
9314317ed18f clean up
Meredith Howard <mhoward@roomag.org>
parents: 966
diff changeset
6 [ -f .zshrc ] ||
9314317ed18f clean up
Meredith Howard <mhoward@roomag.org>
parents: 966
diff changeset
7 die "Refusing to run without a .zshrc nearby"
9314317ed18f clean up
Meredith Howard <mhoward@roomag.org>
parents: 966
diff changeset
8
9314317ed18f clean up
Meredith Howard <mhoward@roomag.org>
parents: 966
diff changeset
9 git --version >/dev/null ||
9314317ed18f clean up
Meredith Howard <mhoward@roomag.org>
parents: 966
diff changeset
10 die "Please install git!"
9314317ed18f clean up
Meredith Howard <mhoward@roomag.org>
parents: 966
diff changeset
11
1183
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
12
849
9a6cb845e239 Switch to perl-install and simplify clone or pull
Meredith Howard <mhoward@roomag.org>
parents: 760
diff changeset
13 clone_or_pull 'https://github.com/tarjoilija/zgen.git' .zgen
9a6cb845e239 Switch to perl-install and simplify clone or pull
Meredith Howard <mhoward@roomag.org>
parents: 760
diff changeset
14
9a6cb845e239 Switch to perl-install and simplify clone or pull
Meredith Howard <mhoward@roomag.org>
parents: 760
diff changeset
15 zsh -i -c 'zgen update' || :
1183
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
16 zsh -i -c 'true'
245
9fa186a70bbd add .homedir-setup.sh
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
17
9fa186a70bbd add .homedir-setup.sh
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
18
1183
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
19 if [ -x .local/bin/mise ]; then
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
20 mise self-update -y
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
21 else
1180
308dce5084af start switching to mise-en-place
Meredith Howard <mhoward@roomag.org>
parents: 999
diff changeset
22 curl -sS 'https://mise.run/' | sh
308dce5084af start switching to mise-en-place
Meredith Howard <mhoward@roomag.org>
parents: 999
diff changeset
23 fi
308dce5084af start switching to mise-en-place
Meredith Howard <mhoward@roomag.org>
parents: 999
diff changeset
24
1183
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
25
965
f1e5d30543ba forget the minimal setup mode
Meredith Howard <mhoward@roomag.org>
parents: 964
diff changeset
26 bin/setup-man || :
381
b09db2db7f84 use ruby and nodejs plugins for asdf
Meredith Howard <mhoward@roomag.org>
parents: 328
diff changeset
27
1183
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
28
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
29 if [ -d .asdf ]; then
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
30 source .asdf/asdf.sh
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
31 warn "Pruning asdf installs"
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
32 asdf list
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
33 rm -rf .asdf
c5735f6254b1 Remove asdf
Meredith Howard <mhoward@roomag.org>
parents: 1182
diff changeset
34 fi

mercurial