Skip to content
This repository has been archived by the owner on Mar 28, 2023. It is now read-only.

Commit

Permalink
Merge pull request #26 from Beginner-Go/tidy
Browse files Browse the repository at this point in the history
luci-app-aliyundrive-fuse: tidy up code
  • Loading branch information
messense authored Mar 31, 2022
2 parents 6530b19 + 07d7647 commit 6c4b689
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 13 deletions.
12 changes: 6 additions & 6 deletions openwrt/aliyundrive-fuse/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,19 +28,19 @@ PKG_HASH:=skip

include $(INCLUDE_DIR)/package.mk

define Package/$(PKG_NAME)
define Package/aliyundrive-fuse
SECTION:=multimedia
CATEGORY:=Multimedia
DEPENDS:=+fuse-utils
TITLE:=FUSE for AliyunDrive
URL:=https://github.com/messense/aliyundrive-fuse
endef

define Package/$(PKG_NAME)/description
define Package/aliyundrive-fuse/description
FUSE for AliyunDrive.
endef

define Package/$(PKG_NAME)/conffiles
define Package/aliyundrive-fuse/conffiles
/etc/config/aliyundrive-fuse
endef

Expand All @@ -62,10 +62,10 @@ define Build/Prepare
endef

define Build/Compile
echo "$(PKG_NAME) using precompiled binary."
echo "aliyundrive-fuse using precompiled binary."
endef

define Package/$(PKG_NAME)/install
define Package/aliyundrive-fuse/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/aliyundrive-fuse $(1)/usr/bin/aliyundrive-fuse
$(INSTALL_DIR) $(1)/etc/init.d
Expand All @@ -74,4 +74,4 @@ define Package/$(PKG_NAME)/install
$(INSTALL_CONF) ./files/aliyundrive-fuse.config $(1)/etc/config/aliyundrive-fuse
endef

$(eval $(call BuildPackage,$(PKG_NAME)))
$(eval $(call BuildPackage,aliyundrive-fuse))
2 changes: 1 addition & 1 deletion openwrt/luci-app-aliyundrive-fuse/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ PKG_MAINTAINER:=messense <[email protected]>

LUCI_TITLE:=LuCI Support for aliyundrive-fuse
LUCI_PKGARCH:=all
LUCI_DEPENDS:=+aliyundrive-fuse +lua +libuci-lua
LUCI_DEPENDS:=+aliyundrive-fuse

include $(TOPDIR)/feeds/luci/luci.mk

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@ function index()
if not nixio.fs.access("/etc/config/aliyundrive-fuse") then
return
end
entry({"admin", "services", "aliyundrive-fuse"}, alias("admin", "services", "aliyundrive-fuse", "client"),_("AliyunDrive FUSE"), 10).dependent = true -- 首页
entry({"admin", "services", "aliyundrive-fuse", "client"}, cbi("aliyundrive-fuse/client"),_("Settings"), 10).leaf = true -- 客户端配置
entry({"admin", "services", "aliyundrive-fuse", "log"}, form("aliyundrive-fuse/log"),_("Log"), 30).leaf = true -- 日志页面

local page
page = entry({"admin", "services", "aliyundrive-fuse"}, alias("admin", "services", "aliyundrive-fuse", "client"), _("AliyunDrive FUSE"), 10) -- 首页
page.dependent = true
page.acl_depends = { "luci-app-aliyundrive-fuse" }

entry({"admin", "services", "aliyundrive-fuse", "client"}, cbi("aliyundrive-fuse/client"), _("Settings"), 10).leaf = true -- 客户端配置
entry({"admin", "services", "aliyundrive-fuse", "log"}, form("aliyundrive-fuse/log"), _("Log"), 30).leaf = true -- 日志页面

entry({"admin", "services", "aliyundrive-fuse", "status"}, call("action_status")).leaf = true
entry({"admin", "services", "aliyundrive-fuse", "logtail"}, call("action_logtail")).leaf = true
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
local uci = luci.model.uci.cursor()
local m, e

m = Map("aliyundrive-fuse")
m.title = translate("AliyunDrive FUSE")
m.description = translate("<a href=\"https://github.com/messense/aliyundrive-fuse\" target=\"_blank\">Project GitHub URL</a>")
Expand Down
1 change: 1 addition & 0 deletions openwrt/luci-app-aliyundrive-fuse/po/zh_Hans
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"luci-app-aliyundrive-fuse": {
"description": "Grant UCI access for luci-app-aliyundrive-fuse",
"read": {
"uci": [ "aliyundrive-fuse" ]
},
"write": {
"uci": [ "aliyundrive-fuse" ]
}
}
}

0 comments on commit 6c4b689

Please sign in to comment.