mirror of https://github.com/kenzok8/small.git
update 2025-02-10 00:13:50
This commit is contained in:
parent
71b63536a3
commit
1d92b64378
|
@ -9,7 +9,8 @@ OS=linux
|
||||||
ARCH=amd64
|
ARCH=amd64
|
||||||
JQVERSION=1.7.1
|
JQVERSION=1.7.1
|
||||||
DOCNAME=Ruleset-URI-Scheme
|
DOCNAME=Ruleset-URI-Scheme
|
||||||
SHARKNAME=shark-taiko.gif
|
SHARKIMG='img/shark-taiko.gif'
|
||||||
|
SHARKAUDIO='audio/A!.mp3'
|
||||||
|
|
||||||
mkdir -p "$PKG_BUILD_BIN"
|
mkdir -p "$PKG_BUILD_BIN"
|
||||||
curl -L "https://github.com/jqlang/jq/releases/download/jq-${JQVERSION}/jq-${OS}-${ARCH}" -o "$PKG_BUILD_BIN"/jq
|
curl -L "https://github.com/jqlang/jq/releases/download/jq-${JQVERSION}/jq-${OS}-${ARCH}" -o "$PKG_BUILD_BIN"/jq
|
||||||
|
@ -34,9 +35,13 @@ tail -n +$(( $p +1 )) $DOCNAME.html
|
||||||
popd
|
popd
|
||||||
minify "$PKG_BUILD_DIR"/buildin.html | base64 | tr -d '\n' > "$PKG_BUILD_DIR"/base64
|
minify "$PKG_BUILD_DIR"/buildin.html | base64 | tr -d '\n' > "$PKG_BUILD_DIR"/base64
|
||||||
sed -i "s|'cmxzdHBsYWNlaG9sZGVy'|'$(cat "$PKG_BUILD_DIR"/base64)'|" "$PKG_BUILD_DIR"/htdocs/luci-static/resources/fchomo.js
|
sed -i "s|'cmxzdHBsYWNlaG9sZGVy'|'$(cat "$PKG_BUILD_DIR"/base64)'|" "$PKG_BUILD_DIR"/htdocs/luci-static/resources/fchomo.js
|
||||||
# shaka
|
# shaka audio
|
||||||
|
sed -i "s|audio/x-wav|audio/mpeg|;
|
||||||
|
s|'UklGRiQAAABXQVZFZm10IBAAAAABAAEARKwAAIhYAQACABAAZGF0YQAAAAA='|'$(base64 "$CURDIR/docs/$SHARKAUDIO" | tr -d '\n')'|" \
|
||||||
|
"$PKG_BUILD_DIR"/htdocs/luci-static/resources/fchomo.js
|
||||||
|
# shaka gif
|
||||||
echo -n "'" > "$PKG_BUILD_DIR"/base64
|
echo -n "'" > "$PKG_BUILD_DIR"/base64
|
||||||
base64 "$CURDIR"/docs/img/$SHARKNAME | tr -d '\n' >> "$PKG_BUILD_DIR"/base64
|
base64 "$CURDIR/docs/$SHARKIMG" | tr -d '\n' >> "$PKG_BUILD_DIR"/base64
|
||||||
echo "'" >> "$PKG_BUILD_DIR"/base64
|
echo "'" >> "$PKG_BUILD_DIR"/base64
|
||||||
p=$(sed -n "/'c2hhcmstdGFpa28uZ2lm'/=" "$PKG_BUILD_DIR"/htdocs/luci-static/resources/fchomo.js)
|
p=$(sed -n "/'c2hhcmstdGFpa28uZ2lm'/=" "$PKG_BUILD_DIR"/htdocs/luci-static/resources/fchomo.js)
|
||||||
{
|
{
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
LUCI_TITLE:=FullCombo Mihomo supplies maximum customization on OpenWrt.
|
LUCI_TITLE:=FullCombo Shark! supplies maximum customization on OpenWrt.
|
||||||
LUCI_PKGARCH:=all
|
LUCI_PKGARCH:=all
|
||||||
LUCI_DEPENDS:= \
|
LUCI_DEPENDS:= \
|
||||||
+mihomo \
|
+mihomo \
|
||||||
|
|
Binary file not shown.
|
@ -10,6 +10,11 @@
|
||||||
/* Member */
|
/* Member */
|
||||||
const rulesetdoc = 'data:text/html;base64,' + 'cmxzdHBsYWNlaG9sZGVy';
|
const rulesetdoc = 'data:text/html;base64,' + 'cmxzdHBsYWNlaG9sZGVy';
|
||||||
|
|
||||||
|
const sharkaudio = function() {
|
||||||
|
return 'data:audio/x-wav;base64,' +
|
||||||
|
'UklGRiQAAABXQVZFZm10IBAAAAABAAEARKwAAIhYAQACABAAZGF0YQAAAAA='
|
||||||
|
}()
|
||||||
|
|
||||||
const sharktaikogif = function() {
|
const sharktaikogif = function() {
|
||||||
return 'data:image/gif;base64,' +
|
return 'data:image/gif;base64,' +
|
||||||
'c2hhcmstdGFpa28uZ2lm'
|
'c2hhcmstdGFpa28uZ2lm'
|
||||||
|
@ -1126,6 +1131,7 @@ function uploadInitialPack(ev, section_id) {
|
||||||
return baseclass.extend({
|
return baseclass.extend({
|
||||||
/* Member */
|
/* Member */
|
||||||
rulesetdoc,
|
rulesetdoc,
|
||||||
|
sharkaudio,
|
||||||
sharktaikogif,
|
sharktaikogif,
|
||||||
less_24_10,
|
less_24_10,
|
||||||
pr7558_merged,
|
pr7558_merged,
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
'require uci';
|
'require uci';
|
||||||
'require ui';
|
'require ui';
|
||||||
'require view';
|
'require view';
|
||||||
|
'require dom';
|
||||||
|
|
||||||
'require fchomo as hm';
|
'require fchomo as hm';
|
||||||
'require tools.firewall as fwtool';
|
'require tools.firewall as fwtool';
|
||||||
|
@ -135,8 +136,24 @@ return view.extend({
|
||||||
|
|
||||||
let m, s, o, ss, so;
|
let m, s, o, ss, so;
|
||||||
|
|
||||||
m = new form.Map('fchomo', _('FullCombo Mihomo'),
|
m = new form.Map('fchomo', _('FullCombo Shark!'),
|
||||||
'<img src="' + hm.sharktaikogif + '" title="Ciallo~(∠・ω< )⌒☆" height="52"></img>');
|
'<img src="' + hm.sharktaikogif + '" title="A!" alt="Ciallo~(∠・ω< )⌒☆" height="52"></img>' +
|
||||||
|
'<audio src="' + hm.sharkaudio + '" preload="auto" hidden=""></audio>');
|
||||||
|
m.renderContents = function(/* ... */) {
|
||||||
|
let node = form.Map.prototype.renderContents.apply(this, arguments);
|
||||||
|
|
||||||
|
return node.then((mapEl) => {
|
||||||
|
const playButton = mapEl.querySelector('.cbi-map-descr > img');
|
||||||
|
const audio = mapEl.querySelector('.cbi-map-descr > audio');
|
||||||
|
|
||||||
|
playButton.addEventListener('click', function() {
|
||||||
|
if (audio.paused)
|
||||||
|
audio.play();
|
||||||
|
});
|
||||||
|
|
||||||
|
return mapEl;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
s = m.section(form.NamedSection, 'config', 'fchomo');
|
s = m.section(form.NamedSection, 'config', 'fchomo');
|
||||||
|
|
||||||
|
|
|
@ -93,14 +93,14 @@ return view.extend({
|
||||||
|
|
||||||
s = m.section(form.NamedSection, 'config', 'fchomo');
|
s = m.section(form.NamedSection, 'config', 'fchomo');
|
||||||
|
|
||||||
/* FullCombo Mihomo START */
|
/* FullCombo Shark! START */
|
||||||
s.tab('fchomo', _('FullCombo Mihomo'));
|
s.tab('fchomo', _('FullCombo Shark!'));
|
||||||
o = s.taboption('fchomo', form.SectionValue, '_fchomo', form.NamedSection, 'config', null);
|
o = s.taboption('fchomo', form.SectionValue, '_fchomo', form.NamedSection, 'config', null);
|
||||||
ss = o.subsection;
|
ss = o.subsection;
|
||||||
|
|
||||||
so = ss.option(form.DummyValue, '_fchomo_logview');
|
so = ss.option(form.DummyValue, '_fchomo_logview');
|
||||||
so.render = L.bind(getRuntimeLog, so, _('FullCombo Mihomo'), 'fchomo');
|
so.render = L.bind(getRuntimeLog, so, _('FullCombo Shark!'), 'fchomo');
|
||||||
/* FullCombo Mihomo END */
|
/* FullCombo Shark! END */
|
||||||
|
|
||||||
/* Mihomo client START */
|
/* Mihomo client START */
|
||||||
s.tab('mihomo_c', _('Mihomo client'));
|
s.tab('mihomo_c', _('Mihomo client'));
|
||||||
|
|
|
@ -830,7 +830,7 @@ msgstr ""
|
||||||
#: htdocs/luci-static/resources/view/fchomo/log.js:97
|
#: htdocs/luci-static/resources/view/fchomo/log.js:97
|
||||||
#: htdocs/luci-static/resources/view/fchomo/log.js:102
|
#: htdocs/luci-static/resources/view/fchomo/log.js:102
|
||||||
#: root/usr/share/luci/menu.d/luci-app-fchomo.json:3
|
#: root/usr/share/luci/menu.d/luci-app-fchomo.json:3
|
||||||
msgid "FullCombo Mihomo"
|
msgid "FullCombo Shark!"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: htdocs/luci-static/resources/view/fchomo/node.js:620
|
#: htdocs/luci-static/resources/view/fchomo/node.js:620
|
||||||
|
|
|
@ -848,7 +848,7 @@ msgstr "格式"
|
||||||
#: htdocs/luci-static/resources/view/fchomo/log.js:97
|
#: htdocs/luci-static/resources/view/fchomo/log.js:97
|
||||||
#: htdocs/luci-static/resources/view/fchomo/log.js:102
|
#: htdocs/luci-static/resources/view/fchomo/log.js:102
|
||||||
#: root/usr/share/luci/menu.d/luci-app-fchomo.json:3
|
#: root/usr/share/luci/menu.d/luci-app-fchomo.json:3
|
||||||
msgid "FullCombo Mihomo"
|
msgid "FullCombo Shark!"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: htdocs/luci-static/resources/view/fchomo/node.js:620
|
#: htdocs/luci-static/resources/view/fchomo/node.js:620
|
||||||
|
|
|
@ -848,7 +848,7 @@ msgstr "格式"
|
||||||
#: htdocs/luci-static/resources/view/fchomo/log.js:97
|
#: htdocs/luci-static/resources/view/fchomo/log.js:97
|
||||||
#: htdocs/luci-static/resources/view/fchomo/log.js:102
|
#: htdocs/luci-static/resources/view/fchomo/log.js:102
|
||||||
#: root/usr/share/luci/menu.d/luci-app-fchomo.json:3
|
#: root/usr/share/luci/menu.d/luci-app-fchomo.json:3
|
||||||
msgid "FullCombo Mihomo"
|
msgid "FullCombo Shark!"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: htdocs/luci-static/resources/view/fchomo/node.js:620
|
#: htdocs/luci-static/resources/view/fchomo/node.js:620
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"admin/services/fchomo": {
|
"admin/services/fchomo": {
|
||||||
"title": "FullCombo Mihomo",
|
"title": "FullCombo Shark!",
|
||||||
"order": 12,
|
"order": 12,
|
||||||
"action": {
|
"action": {
|
||||||
"type": "firstchild"
|
"type": "firstchild"
|
||||||
|
|
|
@ -24,7 +24,7 @@ function wGET(url, header, filepath) {
|
||||||
if (!url || type(url) !== 'string')
|
if (!url || type(url) !== 'string')
|
||||||
return null;
|
return null;
|
||||||
|
|
||||||
let ua = 'Wget/1.21 (FullCombo Mihomo)';
|
let ua = 'Wget/1.21 (FullCombo Shark!)';
|
||||||
|
|
||||||
if (header) {
|
if (header) {
|
||||||
header = json(trim(header) || {});
|
header = json(trim(header) || {});
|
||||||
|
|
|
@ -5,12 +5,12 @@
|
||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=mihomo
|
PKG_NAME:=mihomo
|
||||||
PKG_VERSION:=1.19.1
|
PKG_VERSION:=1.19.2
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||||
PKG_SOURCE_URL:=https://codeload.github.com/metacubex/mihomo/tar.gz/v$(PKG_VERSION)?
|
PKG_SOURCE_URL:=https://codeload.github.com/metacubex/mihomo/tar.gz/v$(PKG_VERSION)?
|
||||||
PKG_HASH:=cf32a96bea6caeb2769e86e3001da67d332a673fc6db703b5bc1a5d14754daa1
|
PKG_HASH:=8afa33b5eb9fc20e521a986be5e21908b53858e4b2350b56e0bf3495b740c4dc
|
||||||
|
|
||||||
PKG_MAINTAINER:=Anya Lin <hukk1996@gmail.com>
|
PKG_MAINTAINER:=Anya Lin <hukk1996@gmail.com>
|
||||||
PKG_LICENSE:=GPL-2.0
|
PKG_LICENSE:=GPL-2.0
|
||||||
|
|
Loading…
Reference in New Issue