We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5b6c63a commit 178ceddCopy full SHA for 178cedd
installer.sh
@@ -93,13 +93,17 @@ _install_pkgx() {
93
unset tmpdir pipe
94
}
95
96
+_pkgx_is_old() {
97
+ v="$(/usr/local/bin/pkgx --version || echo pkgx 0)"
98
+ /usr/local/bin/pkgx --silent semverator gt \
99
+ $(curl -Ssf https://pkgx.sh/VERSION) \
100
+ $(echo $v | awk '{print $2}')
101
+}
102
+
103
_should_install_pkgx() {
104
if [ ! -f /usr/local/bin/pkgx ]; then
105
return 0
- elif /usr/local/bin/pkgx --silent semverator gt \
- $(curl -Ssf https://pkgx.sh/VERSION) \
- $(/usr/local/bin/pkgx --version | awk '{print $2}') >/dev/null 2>&1
- then
106
+ elif _pkgx_is_old >/dev/null 2>&1; then
107
108
else
109
return 1
0 commit comments