summaryrefslogtreecommitdiff
path: root/accounts/gkleen@sif/zshrc
diff options
context:
space:
mode:
Diffstat (limited to 'accounts/gkleen@sif/zshrc')
-rw-r--r--accounts/gkleen@sif/zshrc12
1 files changed, 8 insertions, 4 deletions
diff --git a/accounts/gkleen@sif/zshrc b/accounts/gkleen@sif/zshrc
index abc200c6..c532b308 100644
--- a/accounts/gkleen@sif/zshrc
+++ b/accounts/gkleen@sif/zshrc
@@ -61,7 +61,7 @@ dir() {
61 cd ${modifyPDF:h} 61 cd ${modifyPDF:h}
62 typeset -a pages 62 typeset -a pages
63 eval 'pages=(${dir}/${modifyPDF:t:r}_*.png(on))' 63 eval 'pages=(${dir}/${modifyPDF:t:r}_*.png(on))'
64 magick -verbose "$pages" ${modifyPDF} 64 magick -verbose "${pages[@]}" $(mktemp --tmpdir=${modifyPDF:h} ${modifyPDF:t:r}_XXXXXXXXXX.${modifyPDF:e})
65 modifyPDF="" 65 modifyPDF=""
66 fi 66 fi
67 if [[ -n ${miniservePIDFile} ]]; then 67 if [[ -n ${miniservePIDFile} ]]; then
@@ -93,7 +93,7 @@ dir() {
93 if [[ $curlArchive = "true" ]]; then 93 if [[ $curlArchive = "true" ]]; then
94 archiveFile=$(mktemp -t "archive.XXXXXXXXXX.${templateArchive:t}") 94 archiveFile=$(mktemp -t "archive.XXXXXXXXXX.${templateArchive:t}")
95 95
96 curl -L -o ${archiveFile} ${templateArchive} 96 curl -SfL -o ${archiveFile} ${templateArchive}
97 97
98 templateArchive=${archiveFile} 98 templateArchive=${archiveFile}
99 fi 99 fi
@@ -132,6 +132,10 @@ dir() {
132 unpack=false 132 unpack=false
133 fi 133 fi
134 ;; 134 ;;
135 application/x-iso9660-image)
136 7z x ${templateArchive}
137 unpack=false
138 ;;
135 *) 139 *)
136 tar -xvaf ${templateArchive} 140 tar -xvaf ${templateArchive}
137 unpack=false 141 unpack=false
@@ -183,7 +187,7 @@ tmpdir() {
183 cd / 187 cd /
184 unmount() { 188 unmount() {
185 printf "Unmounting %s\n" ${1} >&2 189 printf "Unmounting %s\n" ${1} >&2
186 fusermount -u ${1} || umount ${1} || sudo umount ${1} 190 fusermount3 -u ${1} || umount ${1} || sudo umount ${1}
187 } 191 }
188 192
189 if [[ -n ${dir} ]]; then 193 if [[ -n ${dir} ]]; then
@@ -231,7 +235,7 @@ clock() {
231} 235}
232 236
233public-ip() { 237public-ip() {
234 curl -s -H 'Accept: application/json' $@ ifconfig.co | jq -r '.ip' 238 curl -sSf -H 'Accept: application/json' $@ ifconfig.co | jq -r '.ip'
235} 239}
236 240
237swap() { 241swap() {