From 1636e5034ec011b2b91183220f62a2f94f97a11e Mon Sep 17 00:00:00 2001 From: Ahurac Date: Mon, 22 Jan 2024 23:45:05 +0100 Subject: [PATCH] =?UTF-8?q?qemush=20:=20ajout=20de=20`cd=20||=20return`=20?= =?UTF-8?q?au=20d=C3=A9but=20de=20fonctions=20sinon=20=C3=A7a=20marche=20p?= =?UTF-8?q?as?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bin/qemush | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bin/qemush b/bin/qemush index 172c10b..9b56de2 100755 --- a/bin/qemush +++ b/bin/qemush @@ -82,12 +82,14 @@ public_watch() { # List running virtual machines public_active() { + cd || return echo "Running machines:" exec ls -t sockets } # List available virtual machines entrypoints public_ls() { + cd || return echo "Available machines:" exec ls launchers } @@ -110,12 +112,14 @@ public_diskrm() { # List available disks public_diskls() { + cd || return echo "Available disks:" exec ls disks } # Edit a virtual machine entrypoint with a text editor public_edit() { + cd || return local file="launchers/${1}" "$EDITOR" "$file" @@ -124,6 +128,7 @@ public_edit() { # Delete a virtual machine entrypoint public_rm() { + cd || return exec rm -vi -- "launchers/${1}" }