2 # Copyright (C) 2019 Ian Kelling
3 # SPDX-License-Identifier: AGPL-3.0-or-later
5 # alternatively, using https://iankelling.org/git/?p=errhandle;a=tree
6 # source /path/errhandle/err
8 source /a
/bin
/errhandle
/err
9 source /a
/bin
/distro-functions
/src
/package-manager-abstractions
11 PATH
="$PATH:$HOME/.cargo/bin"
14 # todo: this should happen in some kind of sandbox or vm
17 if type -t rustc
&>/dev
/null
; then
20 curl https
://sh.rustup.rs
-sSf | bash
-s -- -y
23 if ! which rg
&>/dev
/null
; then
27 if ! type -t cargo-install-update
&>/dev
/null
; then
29 # error: failed to run custom build command for `openssl-sys v0.9.53`
30 pi libssl-dev pkg-config
31 cargo
install cargo-update
34 cargo install-update
-a