mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-16 04:13:31 +00:00
luci-app-aliyundrive-webdav: update to 0.4.7 (#8084)
Co-authored-by: messense <messense@icloud.com>
This commit is contained in:
parent
47f5123531
commit
280c1478f1
@ -1,7 +1,7 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=aliyundrive-webdav
|
PKG_NAME:=aliyundrive-webdav
|
||||||
PKG_VERSION:=0.4.0
|
PKG_VERSION:=0.4.7
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
PKG_LICENSE:=MIT
|
PKG_LICENSE:=MIT
|
||||||
@ -22,7 +22,7 @@ ifeq ($(ARCH),i386)
|
|||||||
PKG_ARCH:=i686
|
PKG_ARCH:=i686
|
||||||
endif
|
endif
|
||||||
|
|
||||||
PKG_SOURCE:=aliyundrive-webdav-$(PKG_ARCH)-unknown-linux-$(PKG_LIBC).tar.gz
|
PKG_SOURCE:=aliyundrive-webdav-v$(PKG_VERSION).$(PKG_ARCH)-unknown-linux-$(PKG_LIBC).tar.gz
|
||||||
PKG_SOURCE_URL:=https://github.com/messense/aliyundrive-webdav/releases/download/v$(PKG_VERSION)/
|
PKG_SOURCE_URL:=https://github.com/messense/aliyundrive-webdav/releases/download/v$(PKG_VERSION)/
|
||||||
PKG_HASH:=skip
|
PKG_HASH:=skip
|
||||||
|
|
||||||
|
@ -8,4 +8,6 @@ config server
|
|||||||
option auth_password ''
|
option auth_password ''
|
||||||
option read_buffer_size '10485760'
|
option read_buffer_size '10485760'
|
||||||
option cache_size '1000'
|
option cache_size '1000'
|
||||||
|
option cache_ttl '600'
|
||||||
option root '/'
|
option root '/'
|
||||||
|
option no_trash '0'
|
||||||
|
@ -21,12 +21,22 @@ start_service() {
|
|||||||
local auth_password=$(uci_get_by_type server auth_password)
|
local auth_password=$(uci_get_by_type server auth_password)
|
||||||
local read_buf_size=$(uci_get_by_type server read_buffer_size 10485760)
|
local read_buf_size=$(uci_get_by_type server read_buffer_size 10485760)
|
||||||
local cache_size=$(uci_get_by_type server cache_size 1000)
|
local cache_size=$(uci_get_by_type server cache_size 1000)
|
||||||
|
local cache_ttl=$(uci_get_by_type server cache_ttl 600)
|
||||||
local host=$(uci_get_by_type server host 127.0.0.1)
|
local host=$(uci_get_by_type server host 127.0.0.1)
|
||||||
local port=$(uci_get_by_type server port 8080)
|
local port=$(uci_get_by_type server port 8080)
|
||||||
local root=$(uci_get_by_type server root /)
|
local root=$(uci_get_by_type server root /)
|
||||||
|
local no_trash=$(uci_get_by_type server no_trash 0)
|
||||||
|
|
||||||
|
local extra_options="-I"
|
||||||
|
case "$no_trash" in
|
||||||
|
1|on|true|yes|enabled)
|
||||||
|
extra_options="$extra_options --no-trash"
|
||||||
|
;;
|
||||||
|
*) ;;
|
||||||
|
esac
|
||||||
|
|
||||||
procd_open_instance
|
procd_open_instance
|
||||||
procd_set_param command /bin/sh -c "/usr/bin/$NAME -I --host $host --port $port --root $root -S $read_buf_size --cache-size $cache_size --workdir /var/run/$NAME >>/var/log/$NAME.log 2>&1"
|
procd_set_param command /bin/sh -c "/usr/bin/$NAME $extra_options --host $host --port $port --root $root -S $read_buf_size --cache-size $cache_size --cache-ttl $cache_ttl --workdir /var/run/$NAME >>/var/log/$NAME.log 2>&1"
|
||||||
procd_set_param pidfile /var/run/$NAME.pid
|
procd_set_param pidfile /var/run/$NAME.pid
|
||||||
procd_set_param env REFRESH_TOKEN="$refresh_token"
|
procd_set_param env REFRESH_TOKEN="$refresh_token"
|
||||||
[[ ! -z "$auth_user" ]] && procd_append_param env WEBDAV_AUTH_USER="$auth_user"
|
[[ ! -z "$auth_user" ]] && procd_append_param env WEBDAV_AUTH_USER="$auth_user"
|
||||||
@ -43,5 +53,5 @@ start_service() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
service_triggers() {
|
service_triggers() {
|
||||||
procd_add_reload_trigger "/etc/config/$NAME"
|
procd_add_reload_trigger "aliyundrive-webdav"
|
||||||
}
|
}
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=luci-app-aliyundrive-webdav
|
PKG_NAME:=luci-app-aliyundrive-webdav
|
||||||
PKG_VERSION:=0.4.0
|
PKG_VERSION:=0.4.7
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
PKG_LICENSE:=MIT
|
PKG_LICENSE:=MIT
|
||||||
|
@ -15,7 +15,8 @@ enable.rmempty = false
|
|||||||
refresh_token = e:option(Value, "refresh_token", translate("Refresh Token"),
|
refresh_token = e:option(Value, "refresh_token", translate("Refresh Token"),
|
||||||
translate("<a href=\"https://github.com/messense/aliyundrive-webdav#%E8%8E%B7%E5%8F%96-refresh_token\" target=\"_blank\">How to get refresh token</a>"))
|
translate("<a href=\"https://github.com/messense/aliyundrive-webdav#%E8%8E%B7%E5%8F%96-refresh_token\" target=\"_blank\">How to get refresh token</a>"))
|
||||||
|
|
||||||
root = e:option(Value, "root", translate("Root Directory"))
|
root = e:option(Value, "root", translate("Root Directory"),
|
||||||
|
translate("Restrict access to a folder of aliyundrive, defaults to / which means no restrictions"))
|
||||||
root.default = "/"
|
root.default = "/"
|
||||||
|
|
||||||
host = e:option(Value, "host", translate("Host"))
|
host = e:option(Value, "host", translate("Host"))
|
||||||
@ -38,11 +39,14 @@ cache_size = e:option(Value, "cache_size", translate("Cache Size"))
|
|||||||
cache_size.default = "1000"
|
cache_size.default = "1000"
|
||||||
cache_size.datatype = "uinteger"
|
cache_size.datatype = "uinteger"
|
||||||
|
|
||||||
|
cache_ttl = e:option(Value, "cache_ttl", translate("Cache Expiration Time (seconds)"))
|
||||||
|
cache_ttl.default = "600"
|
||||||
|
cache_ttl.datatype = "uinteger"
|
||||||
|
|
||||||
|
no_trash = e:option(Flag, "no_trash", translate("Delete file permanently instead of trashing"))
|
||||||
|
no_trash.rmempty = false
|
||||||
|
|
||||||
debug = e:option(Flag, "debug", translate("Debug Mode"))
|
debug = e:option(Flag, "debug", translate("Debug Mode"))
|
||||||
debug.rmempty = false
|
debug.rmempty = false
|
||||||
|
|
||||||
local e = luci.http.formvalue("cbi.apply")
|
|
||||||
if e then
|
|
||||||
io.popen("/etc/init.d/aliyundrive-webdav restart")
|
|
||||||
end
|
|
||||||
return m
|
return m
|
||||||
|
@ -14,7 +14,7 @@ msgid "Refresh Token"
|
|||||||
msgstr "Refresh Token"
|
msgstr "Refresh Token"
|
||||||
|
|
||||||
msgid "Root Directory"
|
msgid "Root Directory"
|
||||||
msgstr "根目录"
|
msgstr "云盘根目录"
|
||||||
|
|
||||||
msgid "Host"
|
msgid "Host"
|
||||||
msgstr "监听主机"
|
msgstr "监听主机"
|
||||||
@ -34,6 +34,9 @@ msgstr "下载缓冲大小(bytes)"
|
|||||||
msgid "Cache Size"
|
msgid "Cache Size"
|
||||||
msgstr "目录缓存大小"
|
msgstr "目录缓存大小"
|
||||||
|
|
||||||
|
msgid "Cache Expiration Time (seconds)"
|
||||||
|
msgstr "目录缓存过期时间(单位为秒)"
|
||||||
|
|
||||||
msgid "Collecting data..."
|
msgid "Collecting data..."
|
||||||
msgstr "获取数据中..."
|
msgstr "获取数据中..."
|
||||||
|
|
||||||
@ -57,3 +60,9 @@ msgstr "<a href=\"https://github.com/messense/aliyundrive-webdav\" target=\"_bla
|
|||||||
|
|
||||||
msgid "<a href=\"https://github.com/messense/aliyundrive-webdav#%E8%8E%B7%E5%8F%96-refresh_token\" target=\"_blank\">How to get refresh token</a>"
|
msgid "<a href=\"https://github.com/messense/aliyundrive-webdav#%E8%8E%B7%E5%8F%96-refresh_token\" target=\"_blank\">How to get refresh token</a>"
|
||||||
msgstr "<a href=\"https://github.com/messense/aliyundrive-webdav#%E8%8E%B7%E5%8F%96-refresh_token\" target=\"_blank\">查看获取 refresh token 的方法</a>"
|
msgstr "<a href=\"https://github.com/messense/aliyundrive-webdav#%E8%8E%B7%E5%8F%96-refresh_token\" target=\"_blank\">查看获取 refresh token 的方法</a>"
|
||||||
|
|
||||||
|
msgid "Restrict access to a folder of aliyundrive, defaults to / which means no restrictions"
|
||||||
|
msgstr "限制只能访问该云盘目录,默认为 / 表示不限制,注意这个参数不是本地磁盘路径"
|
||||||
|
|
||||||
|
msgid "Delete file permanently instead of trashing"
|
||||||
|
msgstr "删除文件不放入回收站"
|
||||||
|
Loading…
Reference in New Issue
Block a user