新增 Scheme URL 支持

This commit is contained in:
lyswhut
2022-01-07 17:23:48 +08:00
parent 20518cbe2b
commit a393bb02dd
18 changed files with 448 additions and 28 deletions
+6
View File
@@ -1,7 +1,13 @@
const urlSchemeRxp = /^lxmusic:\/\//
const parseEnv = () => {
const params = {}
const rx = /^-\w+/
for (let param of process.argv) {
if (urlSchemeRxp.test(param)) {
global.envParams.deeplink = param
}
if (!rx.test(param)) continue
param = param.substring(1)
let index = param.indexOf('=')