mirror of
https://github.com/ryantm/agenix.git
synced 2024-11-22 09:40:47 +03:00
Simplify removal of trailing spaces
This commit is contained in:
parent
4c315d9683
commit
4b2b6fa111
1 changed files with 1 additions and 3 deletions
|
@ -23,9 +23,7 @@ with lib; let
|
||||||
if isDarwin
|
if isDarwin
|
||||||
then ''
|
then ''
|
||||||
if ! diskutil info "${cfg.secretsMountPoint}" &> /dev/null; then
|
if ! diskutil info "${cfg.secretsMountPoint}" &> /dev/null; then
|
||||||
dev=$(diskutil image attach -mountPolicy=noMount ram://1MiB)
|
dev=$(diskutil image attach -mountPolicy=noMount ram://1MiB | sed 's/[[:space:]]*$//')
|
||||||
# Remove trailing tabs
|
|
||||||
dev=''${dev%%[[:space:]]*}
|
|
||||||
newfs_hfs -v agenix "$dev"
|
newfs_hfs -v agenix "$dev"
|
||||||
mount -t hfs -o nobrowse,nodev,nosuid,-m=0751 "$dev" "${cfg.secretsMountPoint}"
|
mount -t hfs -o nobrowse,nodev,nosuid,-m=0751 "$dev" "${cfg.secretsMountPoint}"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue