Age | Commit message (Collapse) | Author |
|
In the overview page, the name of the interface is converted to
uppercase. However, this is not the name in the configuration. From my
point of view, this makes no sense. The name displayed should correspond
exactly to the name in the configuration.
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
|
|
Ref: https://github.com/openwrt/luci/pull/5976#issuecomment-1290370037
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
The LuCI uci configuration requires language tags with underscores due
limitations of uci option names but the language catalogs themselves
are designated with dash separated language tags.
Make sure to substitute underscores with dashes when determining the
desired request language in order to fix loading of languages such as
`pt-br` or `zh-cn`.
Ref: https://github.com/openwrt/luci/pull/5976#issuecomment-1290352951
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
The ability to require certain paths to be absent for a menu entry to show
up was lost during the ucode conversion.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
GNU Make version 4.2 chokes on `#` characters embedded in variable
substitutions, leading to the following error:
../../luci.mk:114: *** unterminated call to function 'if': missing ')'. Stop.
Avoid this problem by replacing variable substitutions with Git branch
format arguments.
Ref: https://github.com/openwrt/luci/pull/5976#issuecomment-1289935106
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
[RFT] Rewrite LuCI runtime in ucode
|
|
Rewrite the luci-app-command configuration to client side cbi forms and
port the server side templates and controller logic to ucode.
Also utilize a query string parameter to pass custom arguments.
Fixes: #5559
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Some packages require Lua libraries but do not ship with a luasrc directory,
add explicit dependencies in these cases.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Remove the uhttpd and CGI gateway modules as they're not compatible with
the Lua compat stub runtime anymore.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
The TIME_WAIT indicator might not appear at the beginning of the tuple
string in some cases, so match it anywhere.
Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
[add commit message]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Ensure that the extracted tuple string starts with a space to fully match
all contained key-value pairs.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Some init scripts, such as the sysfsutils one, declare their START or
STOP variables very late in the file. Duplicate the search buffer to
2048 byte in order to catch these cases.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Gracefully handle missing indexes in the luci rpcd plugin getInitList
procedure.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Rewrite the wireguard rpcd plugin in ucode to prevent an implicit dependency
on the LuCI Lua runtime.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Rewrite the collectd config generator script in ucode to remove the implicit
dependency on the Lua runtime.
Also move the stat-genconfig script into /usr/libexec as it isn't really a
user facing executable.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Utilize the rpcd ucode plugin to reimplement the upnp backend ubus actions
in ucode, simplifying the implementation and roughly halving the processing
time for the `get_status` call.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Some existing LuCI application code accesses the
`luci.http.context.request.message.params` HTTP parameter table directly.
Forward the `luci.http.context.request.message` object to the ucode
`luci.http.message` instance in order to properly support this.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Some existing LuCI apps ship menu.d JSON files with `cbi` and `form` typed
dispatch targets, support those as well.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Some existing model code expects the luci.sys namespace to be implicitly
available, even without requiring it beforehand.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Re-scan base translations after ucode conversion and update po files.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
None of the components pulled in by the standard luci collection require
server side Lua processing anymore, so we're free to drop the explicit
dependency on the libiwinfo Lua binding.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Add ucode template equivalents for the Lua templates used by the theme.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Drop an unused, leftover Lua cbi model from the system module.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Transform the only Lua template of the status module into an equivalent
ucode template and make it conditionally include the legacy Lua logic
factored out in a previous commit.
Only if the ucode Lua bridge is installed and loadable, the Lua template
loading the legacy Lua status partials is included.
After this commit, luci-mod-status is free of Lua dependencies.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Add a compatibility template containing legacy Lua logic extracted from
the luci-mod-status main status page in order to free the status module
from any explicit or implicit Lua dependencies.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Since the LuCI status module was rewritten into client side views,
there is no server side Lua processing anymore.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Since the LuCI network admin module was rewritten into client side views,
there is no server side Lua processing anymore. The iwinfo routines are
utilized through the corresponding rpcd plugin.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Recognize ucode source files and ucode templates and add the necessary logic
to preprocess ucode templates into valid JavaScript sources.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Make packages having a non-empty luasrc/ directory automatically depend
on the LuCI Lua runtime package.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Move classes required for Lua runtime support into a new `luci-lua-runtime`
package. Also replace the `luci.http` and `luci.util` classes in
`luci-lib-base` with stubbed versions interacting with the ucode based
runtime environment.
Finally merge `luci-base-ucode` into the remainders of `luci-base`.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
This commits introduces an initial ucode based LuCI runtime. It supports
JSON menu files as used by Lua based LuCI and the template, call, view and
alias dispatch targets.
It is able to render a basic LuCI installation without errors. An embedded
Lua VM is lazily loaded when Lua based resources are encountered, such as
`*.htm` templates or server side Lua call targets.
When a template is requested, the ucode runtime first tries to render an
`/usr/share/ucode/luci/template/${path}.uc` ucode template and falls back
to rendering the corresponding `/usr/lib/lua/luci/view/${path}.htm` Lua
template in case no suitable ucode replacement is found. This allows for
gradual migration of existing Lua based tmeplates to ucode.
Furthermore, a set of stripped down LuCI libraries is shipped in the
`/usr/lib/lua/luci/ucodebridge/` directory. Those libraries provide
compatibility shims for the current Lua API towards Lua templates and Lua
based server side actions while utilizing the ucode request runtime state
internally.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Add a zoneinfo2ucode.pl script which is the ucode equivalent to
zoneinfo2lua.pl. It will generate a ucode module exporting a dictionary
of known timezone names and their corresponding TZ strings.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Add special handling for ucode/ package subdirs, analogeous to luasrc/.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
The index cache files have been split into separate, dynamically named
Lua and JSON files a while ago, so adjust the remove command in the
postinstall script accordingly.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
- Fix misspelled comment
- Fix wrong variable in Lua SrcDiet condition
- Fix wrong indentation
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
In case `git branch --remote` yields no result, fall back to `git branch`
without `--remote` since it is possible that the local branch has not
been pushed yet.
Also simplify extraction of the branch name by not passing `--verbose`
and utilizing variable substitutions instead of sed expressions.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
The ucode-mod-html library provides assorted utility functions for dealing
with HTML markup data.
Example usage:
#!/usr/bin/ucode
'use strict';
import { tokenize, striptags, entitydecode, entityencode,
OPEN, ATTR, TEXT, CLOSE, RAW, COMMENT, CDATA, PROCINST, EOF } from 'html';
tokenize('<div class="example">Hello world!</div>...',
function(type, text, value) {
switch (type) {
case OPEN: print(`Opening tag: ${text}\n`); break;
case ATTR: print(`Attribute: ${text}${value ? `=${value}`}\n`; break;
case TEXT: print(`Text data: ${text}\n`); break;
case CLOSE: print(`Closing tag: ${text}\n`); break;
case RAW: print(`Script/CSS: ${text}\n`); break;
case COMMENT: print(`Comment: ${text}\n`); break;
case CDATA: print(`CDATA text: ${text}\n`); break;
case PROCINST: print(`<!...> tag: ${text}\n`); break;
case EOF: print(`End of input\n`); break;
}
}
);
print(striptags('<p>This is some <b>text</b> with <br> markup</p>\n'));
print(entitydecode('<   & ä'));
print(entityencode('1 < 2 && "foo"'));
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Avoid redundancies in generated exception messages and include Lua
tracebacks when catching exceptions in protected calls.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
luci-app-simple-adblock: bugfix: identify nft set support
|
|
Signed-off-by: Stan Grishin <stangri@melmac.ca>
|
|
Update timezone data to 2022e.
* http://mm.icann.org/pipermail/tz-announce/2022-September/000073.html
* http://mm.icann.org/pipermail/tz-announce/2022-October/000074.html
- Palestine transitions are now Saturdays at 02:00.
- Simplify three Ukraine zones into one.
- Jordan and Syria switch from +02/+03 with DST to year-round +03.
Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
|
|
Currently translated at 100.0% (2079 of 2079 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/da/
Translated using Weblate (Danish)
Currently translated at 17.9% (35 of 195 strings)
Translated using Weblate (German)
Currently translated at 42.7% (47 of 110 strings)
Translation: OpenWrt/LuCI/applications/smartdns
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationssmartdns/de/
Translated using Weblate (German)
Currently translated at 96.2% (203 of 211 strings)
Translation: OpenWrt/LuCI/applications/dockerman
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsdockerman/de/
Translated using Weblate (German)
Currently translated at 100.0% (50 of 50 strings)
Translation: OpenWrt/LuCI/applications/acme
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsacme/de/
Translated using Weblate (French)
Currently translated at 88.7% (79 of 89 strings)
Translation: OpenWrt/LuCI/applications/frpc
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsfrpc/fr/
Translated using Weblate (German)
Currently translated at 51.6% (16 of 31 strings)
Translation: OpenWrt/LuCI/applications/yggdrasil
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsyggdrasil/de/
Translated using Weblate (German)
Currently translated at 40.1% (47 of 117 strings)
Translation: OpenWrt/LuCI/applications/https-dns-proxy
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationshttps-dns-proxy/de/
Translated using Weblate (German)
Currently translated at 86.3% (165 of 191 strings)
Translation: OpenWrt/LuCI/applications/travelmate
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationstravelmate/de/
Translated using Weblate (German)
Currently translated at 100.0% (110 of 110 strings)
Translation: OpenWrt/LuCI/applications/simple-adblock
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationssimple-adblock/de/
Translated using Weblate (French)
Currently translated at 98.8% (175 of 177 strings)
Translation: OpenWrt/LuCI/applications/adblock
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsadblock/fr/
Translated using Weblate (Greek)
Currently translated at 14.1% (25 of 177 strings)
Translation: OpenWrt/LuCI/applications/adblock
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsadblock/el/
Translated using Weblate (French)
Currently translated at 80.5% (29 of 36 strings)
Translated using Weblate (German)
Currently translated at 83.3% (30 of 36 strings)
Translated using Weblate (German)
Currently translated at 100.0% (15 of 15 strings)
Translation: OpenWrt/LuCI/applications/example
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsexample/de/
Translated using Weblate (German)
Currently translated at 95.7% (202 of 211 strings)
Translation: OpenWrt/LuCI/applications/dockerman
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsdockerman/de/
Translated using Weblate (Arabic)
Currently translated at 4.4% (4 of 89 strings)
Translation: OpenWrt/LuCI/applications/frpc
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsfrpc/ar/
Translated using Weblate (Arabic)
Currently translated at 8.9% (15 of 168 strings)
Translation: OpenWrt/LuCI/applications/aria2
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsaria2/ar/
Translated using Weblate (Arabic)
Currently translated at 7.6% (5 of 65 strings)
Translation: OpenWrt/LuCI/applications/dnscrypt-proxy
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsdnscrypt-proxy/ar/
Translated using Weblate (Arabic)
Currently translated at 24.4% (12 of 49 strings)
Translation: OpenWrt/LuCI/applications/bmx7
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsbmx7/ar/
Translated using Weblate (Arabic)
Currently translated at 3.0% (2 of 66 strings)
Translation: OpenWrt/LuCI/applications/frps
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsfrps/ar/
Translated using Weblate (Arabic)
Currently translated at 20.2% (19 of 94 strings)
Translation: OpenWrt/LuCI/applications/vpn-policy-routing
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsvpn-policy-routing/ar/
Translated using Weblate (Arabic)
Currently translated at 25.0% (13 of 52 strings)
Translation: OpenWrt/LuCI/applications/ttyd
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsttyd/ar/
Translated using Weblate (Arabic)
Currently translated at 22.5% (7 of 31 strings)
Translation: OpenWrt/LuCI/applications/dynapoint
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsdynapoint/ar/
Translated using Weblate (Arabic)
Currently translated at 73.3% (1525 of 2079 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/ar/
Translated using Weblate (German)
Currently translated at 100.0% (89 of 89 strings)
Translation: OpenWrt/LuCI/applications/frpc
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsfrpc/de/
Translated using Weblate (German)
Currently translated at 100.0% (110 of 110 strings)
Translation: OpenWrt/LuCI/applications/simple-adblock
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationssimple-adblock/de/
Translated using Weblate (Portuguese)
Currently translated at 100.0% (177 of 177 strings)
Translation: OpenWrt/LuCI/applications/adblock
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsadblock/pt/
Translated using Weblate (German)
Currently translated at 100.0% (177 of 177 strings)
Translation: OpenWrt/LuCI/applications/adblock
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsadblock/de/
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (196 of 196 strings)
Translation: OpenWrt/LuCI/applications/ddns
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsddns/pt_BR/
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (2079 of 2079 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/pt_BR/
Translated using Weblate (Polish)
Currently translated at 100.0% (2079 of 2079 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/pl/
Translated using Weblate (Spanish)
Currently translated at 100.0% (177 of 177 strings)
Translation: OpenWrt/LuCI/applications/adblock
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsadblock/es/
Translated using Weblate (Polish)
Currently translated at 100.0% (195 of 195 strings)
Translated using Weblate (Chinese (Simplified))
Currently translated at 100.0% (2079 of 2079 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/zh_Hans/
Translated using Weblate (Russian)
Currently translated at 100.0% (2079 of 2079 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/ru/
Translated using Weblate (Polish)
Currently translated at 99.9% (2077 of 2079 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/pl/
Translated using Weblate (Spanish)
Currently translated at 96.2% (2001 of 2079 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/es/
Translated using Weblate (Chinese (Simplified))
Currently translated at 100.0% (196 of 196 strings)
Translation: OpenWrt/LuCI/applications/ddns
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsddns/zh_Hans/
Co-authored-by: Abdullah AlShaikh <abdullah@alshai5.com>
Co-authored-by: Amaury <y0da@live.fr>
Co-authored-by: Anton Kikin <a.a.kikin@gmail.com>
Co-authored-by: Eric <hamburger1024@mailbox.org>
Co-authored-by: Franco Castillo <castillofrancodamian@gmail.com>
Co-authored-by: Glax <gfreak70@gmail.com>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: Matthaiks <kitynska@gmail.com>
Co-authored-by: TakissX <pxatzidakis@gmail.com>
Co-authored-by: Wellington Terumi Uemura <wellingtonuemura@gmail.com>
Co-authored-by: Zeik0s <zeik0s@zeik0s.at>
Co-authored-by: drax red <drax@outlook.dk>
Co-authored-by: ssantos <ssantos@web.de>
Signed-off-by: Abdullah AlShaikh <abdullah@alshai5.com>
Signed-off-by: Amaury <y0da@live.fr>
Signed-off-by: Anton Kikin <a.a.kikin@gmail.com>
Signed-off-by: Eric <hamburger1024@mailbox.org>
Signed-off-by: Franco Castillo <castillofrancodamian@gmail.com>
Signed-off-by: Glax <gfreak70@gmail.com>
Signed-off-by: Matthaiks <kitynska@gmail.com>
Signed-off-by: TakissX <pxatzidakis@gmail.com>
Signed-off-by: Wellington Terumi Uemura <wellingtonuemura@gmail.com>
Signed-off-by: Zeik0s <zeik0s@zeik0s.at>
Signed-off-by: drax red <drax@outlook.dk>
Signed-off-by: ssantos <ssantos@web.de>
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsolsr/da/
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsolsr/pl/
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationswatchcat/de/
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationswatchcat/fr/
Translation: OpenWrt/LuCI/applications/olsr
Translation: OpenWrt/LuCI/applications/watchcat
|
|
LuCI Support for Keepalived
Signed-off-by: Jaymin Patel <jem.patel@gmail.com>
|
|
The `network.getDSLModemType()` function returns a promise, so handle it
accordingly.
Fixes: 45ab2cd6be ("luci-mod-status: use network.getDSLModemType()")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
remove 'dsl' feature flag
|
|
This is now unused.
Signed-off-by: Andre Heider <a.heider@gmail.com>
|
|
This matches what luci-mod-network does for the DSL modem configuration.
Since this is based on a common uci config, it may also prevent issues as
fixed with 111c551c "luci-base: fix DSL feature detection" in the future.
Signed-off-by: Andre Heider <a.heider@gmail.com>
|
|
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Placeholder hint also reflects syntax.
Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
[replace asdf.com with example.com, use … instead of ..., remove uneeded
entities]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|