Skip to content

Commit 4803c73

Browse files
committed
check if CARGO_TARGET_DIR is set
1 parent 231a920 commit 4803c73

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

install.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,11 @@ if [[ $# -eq 1 && $1 == "uninstall" ]]; then
1010
echo "Uninstalled"
1111

1212
else
13-
14-
cp target/release/rdg /usr/bin/rdg
13+
if [[ -n $CARGO_TARGET_DIR ]]; then
14+
cp $CARGO_TARGET_DIR/release/rdg /usr/bin/rdg
15+
else
16+
cp target/release/rdg /usr/bin/rdg
17+
fi
1518
cp assets/net.olback.rdg.desktop /usr/share/applications/net.olback.rdg.desktop
1619
cp assets/net.olback.rdg.png /usr/share/icons/hicolor/256x256/apps/net.olback.rdg.png
1720

0 commit comments

Comments
 (0)