mirror of
https://github.com/9001/copyparty.git
synced 2025-08-17 09:02:15 -06:00
osx support for sfx
This commit is contained in:
parent
1c49b71606
commit
00f05941d4
|
@ -1,7 +1,7 @@
|
|||
# coding: utf-8
|
||||
|
||||
VERSION = (0, 2, 3)
|
||||
BUILD_DT = (2020, 1, 19)
|
||||
BUILD_DT = (2020, 4, 27)
|
||||
|
||||
S_VERSION = ".".join(map(str, VERSION))
|
||||
S_BUILD_DT = "{0:04d}-{1:02d}-{2:02d}".format(*BUILD_DT)
|
||||
|
|
5
scripts/make-unix-sfx.sh
Normal file → Executable file
5
scripts/make-unix-sfx.sh
Normal file → Executable file
|
@ -62,6 +62,7 @@ dir="$(
|
|||
awk '/./ {print; exit}'
|
||||
)/pe-copyparty"
|
||||
|
||||
printf '%s\n' "$pybin" | grep -qE ... && [ -e "$pybin" ] && py="$pybin" ||
|
||||
py="$(command -v python3)" ||
|
||||
py="$(command -v python)" ||
|
||||
py="$(command -v python2)" || {
|
||||
|
@ -84,7 +85,9 @@ py="$(command -v python2)" || {
|
|||
|
||||
now=$(date -u +%s)
|
||||
for d in "$dir".*; do
|
||||
ts=$(stat -c%Y -- "$d")
|
||||
ts=$(stat -c%Y -- "$d" 2>/dev/null) ||
|
||||
ts=$(stat -f %m%n -- "$d" 2>/dev/null)
|
||||
|
||||
[ $((now-ts)) -gt 300 ] &&
|
||||
rm -rf "$d"
|
||||
done
|
||||
|
|
Loading…
Reference in a new issue