Skip to content

Commit

Permalink
Fix eject linux issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Franck ALARY committed Feb 29, 2024
1 parent 90eb7a4 commit 7b2d5d9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions extraResources/eject/linux/eject.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/usr/bin/env bash
umount -l "$1"
mountPart=$(df "$1" | tail -1 | awk '{ print $1 }')
readonly pathDevice=$1
readonly mountPart=$(df "$pathDevice" | tail -1 | awk '{ print $1 }')
umount -l "$pathDevice"
udisksctl power-off -b "$mountPart" --no-user-interaction

0 comments on commit 7b2d5d9

Please sign in to comment.