Skip to content

Commit

Permalink
luci-compat: opkg_package -> package_name
Browse files Browse the repository at this point in the history
opkg is no longer available as the generic name for package-manager

Signed-off-by: Paul Donald <[email protected]>
  • Loading branch information
systemcrash committed Dec 15, 2024
1 parent 0459c37 commit 367b67f
Show file tree
Hide file tree
Showing 16 changed files with 16 additions and 16 deletions.
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1146,7 +1146,7 @@ function protocol.is_bridge(self)
return (not self:is_virtual() and self:type() == "bridge")
end

function protocol.opkg_package(self)
function protocol.package_name(self)
return nil
end

Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_3g.lua
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function proto.is_installed(self)
return nixio.fs.access("/lib/netifd/proto/3g.sh")
end

function proto.opkg_package(self)
function proto.package_name(self)
return "comgt"
end

Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_4x6.lua
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ for _, p in ipairs({"dslite", "map", "464xlat"}) do
return p .. "-" .. self.sid
end

function proto.opkg_package(self)
function proto.package_name(self)
if p == "dslite" or p == "ipip6" then
return "ds-lite"
elseif p == "map" then
Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_6x4.lua
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ for _, p in ipairs({"6in4", "6to4", "6rd"}) do
return p .. "-" .. self.sid
end

function proto.opkg_package(self)
function proto.package_name(self)
return p
end

Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_dhcpv6.lua
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ function proto.is_installed(self)
return nixio.fs.access("/lib/netifd/proto/dhcpv6.sh")
end

function proto.opkg_package(self)
function proto.package_name(self)
return "odhcp6c"
end
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_hnet.lua
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ function proto.is_installed(self)
return nixio.fs.access("/lib/netifd/proto/hnet.sh")
end

function proto.opkg_package(self)
function proto.package_name(self)
return "hnet-full"
end
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_ipip.lua
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ function proto.ifname(self)
return "ipip-" .. self.sid
end

function proto.opkg_package(self)
function proto.package_name(self)
return "ipip"
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ function proto.get_interface(self)
return interface(self:ifname(), self)
end

function proto.opkg_package(self)
function proto.package_name(self)
return "modemmanager"
end

Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_ncm.lua
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ function proto.get_i18n(self)
return luci.i18n.translate("NCM")
end

function proto.opkg_package(self)
function proto.package_name(self)
return "comgt-ncm"
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ function proto.get_interface(self)
return interface(self:ifname(), self)
end

function proto.opkg_package(self)
function proto.package_name(self)
return "openconnect"
end

Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_ppp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ for _, p in ipairs({"ppp", "pptp", "pppoe", "pppoa", "l2tp"}) do
return p .. "-" .. self.sid
end

function proto.opkg_package(self)
function proto.package_name(self)
if p == "ppp" then
return p
elseif p == "pptp" then
Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_pppossh.lua
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ function proto.ifname(self)
return "pppossh-" .. self.sid
end

function proto.opkg_package(self)
function proto.package_name(self)
return "pppossh"
end

Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_qmi.lua
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ function proto.get_interface(self)
return interface(self:ifname(), self)
end

function proto.opkg_package(self)
function proto.package_name(self)
return "uqmi"
end

Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_relay.lua
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ function proto.ifname(self)
return "relay-" .. self.sid
end

function proto.opkg_package(self)
function proto.package_name(self)
return "relayd"
end

Expand Down
2 changes: 1 addition & 1 deletion modules/luci-compat/luasrc/model/network/proto_vpnc.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ function proto.get_interface(self)
return interface(self:ifname(), self)
end

function proto.opkg_package(self)
function proto.package_name(self)
return "vpnc"
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ function proto.get_interface(self)
return interface(self:ifname(), self)
end

function proto.opkg_package(self)
function proto.package_name(self)
return "wireguard-tools"
end

Expand Down

0 comments on commit 367b67f

Please sign in to comment.