xiaomianao666

小程序:动漫岛⛩️

Nov 8th, 2024
230
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 海阔视界规则分享,当前分享的是:小程序¥home_rule_v2¥base64://@动漫岛⛩️@eyJsYXN0X2NoYXB0ZXJfcnVsZSI6Ii8vaHR0cDovL3d3dy44OGRtdy5jb20vIiwidGl0bGUiOiLliqjmvKvlspvim6nvuI8iLCJhdXRob3IiOiJSJua1t+mYlOWwj+eZvSIsInVybCI6Imhpa2VyOi8vZW1wdHkjI2h0dHA6Ly93d3cuZG1hbmQ1LmNvbS90eXBlLzEtZnlwYWdlLmh0bWwiLCJ2ZXJzaW9uIjowLCJjb2xfdHlwZSI6Im1vdmllXzMiLCJjbGFzc19uYW1lIjoiIiwidHlwZSI6InZpZGVvIiwiY2xhc3NfdXJsIjoiIiwiYXJlYV9uYW1lIjoiIiwiYXJlYV91cmwiOiIiLCJzb3J0X25hbWUiOiIiLCJ5ZWFyX25hbWUiOiIiLCJzb3J0X3VybCI6IiIsInllYXJfdXJsIjoiIiwiZmluZF9ydWxlIjoianM6XG52YXIgZCA9IFtdO1xuYWRkTGlzdGVuZXIoXCJvbkNsb3NlXCIsICQudG9TdHJpbmcoKCkgPT4ge1xuICAgIGxldCBrZXlzID0gbGlzdE15VmFyS2V5cygpO1xuICAgIGZvciAobGV0IGl0IG9mIGtleXMpIHtcbiAgICAgICAgY2xlYXJNeVZhcihpdCk7XG4gICAgfVxufSkpO1xudmFyIGdldFJhbmdlQ29sb3JzID0gZnVuY3Rpb24oKSB7wqDCoMKgwqDCoMKgwqBcbiAgICByZXR1cm4gJyMnICsgKCcwMDAwMCcgKyAoTWF0aC5yYW5kb20oKSAqIDB4MTAwMDAwMCA8PCAwKS50b1N0cmluZygxNikpLnN1YnN0cigtNik7wqDCoMKgwqDCoFxufVxuY29uc3Qg5LiL5LiA6aG1ID0gXCJwZChodG1sLCAnYTptYXRjaGVzKOS4i+S4gOmhtSkmJmhyZWYnKVwiO1xuY29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ICAgICBpbnB1dCA9IHRydWU7XFxuICAgICAgfVxcbiAgICAgIHRoaXMuaXNCb29sZWFuKGlucHV0KTtcXG4gICAgICB0aGlzLm9wZW4gPSBpbnB1dDtcXG4gICAgICByZXR1cm4gdGhpcztcXG4gICAgfSxcXG4gICAgc2V0VGl0bGUoaywgaSwgdCkge1xcbiAgICAgIHJldHVybiBrID09IGkgPyBcXFwi4oCc4oCc4oCd4oCdXFxcIiArIHQuZm9udGNvbG9yKHRoaXMu5YiG57G76aKc6ImyKSA6IHQ7XFxuICAgIH0sXFxuICAgIGFjdGlvbihvYmopIHtcXG4gICAgICByZXR1cm4gW1xcbiAgICAgICAge1xcbiAgICAgICAgICB0aXRsZTogXFxcIua4hemZpOeKtuaAgVxcXCIsXFxuICAgICAgICAgIGpzOiAkLnRvU3RyaW5nKChvYmopID0+IHtcXG4gICAgICAgICAgICBsb2cob2JqKTtcXG4gICAgICAgICAgICBjbGVhck15VmFyKG9iai5zdGF0ZSk7XFxuICAgICAgICAgICAgY2xlYXJNeVZhcihcXFwiaGVhZC5jYXRlXFxcIik7XFxuICAgICAgICAgICAgb2JqLmFsbC5mb3JFYWNoKChpdGVtKSA9PiB7XFxuICAgICAgICAgICAgICBjbGVhck15VmFyKGl0ZW0pO1xcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgIG9iai5jbC5mb3JFYWNoKChpdGVtKSA9PiB7XFxuICAgICAgICAgICAgICBjbGVhck15VmFyKGl0ZW0pO1xcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgICAgIHJlZnJlc2hQYWdlKCk7XFxuICAgICAgICAgIH0sIG9iaiksXFxuICAgICAgICB9LFxcbiAgICAgIF07XFxuICAgIH0sXFxuICAgIGNoZWNrUGFyYW0oKSB7XFxuICAgICAgdmFyIG9iaiA9IHt9O1xcbiAgICAgIGlmICh0aGlzLnBhZ2UgPT0gMCAmJiB0eXBlb2YgcGFnZSA9PSBcXFwidW5kZWZpbmVkXFxcIikge1xcbiAgIC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tcXG4gICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICBsaXN0ID0gcGRmYShodG1sLCB4LuS4gOe6p+WumuS9jSk7XFxuICAgICAgICAgIH1cXG4gICAgICAgIH1cXG4gICAgICAgIGlmKHgu5aSn57G75a6a5L2NKXtcXG4gICAgICAgICAgaWYgKHgu5aSn57G75a6a5L2NLnN0YXJ0c1dpdGgoXFxcIkBqczpcXFwiKSkge1xcbiAgICAgICAgICBsaXN0ID0gdGhpcy5ldmFsSlNSdWxlKGh0bWwsIHgu5aSn57G75a6a5L2NKTtcXG4gICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICBsaXN0ID0gW3BkZmEoaHRtbCwgeC7lpKfnsbvlrprkvY0pLmpvaW4oJ1xcXFxuJyldO1xcbiAgICAgICAgIH1cXG4gICAgICAgIH1cXG4gICAgICAgIHZhciDkuIDnuqcgPSBsaXN0Lm1hcCgocykgPT4ge1xcbiAgICAgICAgICB2YXIgc2xpc3QgPSBbXTtcXG4gICAgICAgICAgaWYgKCEoXFxcIuWwj+exu1xcXCIgaW4geCkpIHtcXG4gICAgICAgICAgICB4LuWwj+exuyA9IFxcXCJib2R5JiZhOm5vdCg6bWF0Y2hlcyjpppbpobUpKTpub3QoYTpub3QoW2hyZWZdKSlcXFwiO1xcbiAgICAgICAgICB9XFxuICAgICAgICAgIGlmICh4LuWwj+exuy5zdGFydHNXaXRoKFxcXCJAanM6XFxcIikpIHtcXG4gICAgICAgICAgICBzbGlzdCA9IHRoaXMuZXZhbEpTUnVsZShzLCB4LuWwj+exuyk7XFxuICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgc2xpc3QgPSBwZGZhKHMsIHgu5bCP57G7KTtcXG4gICAgICAgICAgfVxcbiAgICAgICAgICB2YXIg5a6a5L2NID0gc2xpc3QubWFwKChpdGVtKSA9PiB7XFxuICAgICAgICAgICAgdmFyIHRpdGxlID0gdGhpcy5nZXRUaXRsZShpdGVtLCB4Luagh+mimCk7XFxuICAgICAgICAgICAgdmFyIHVybCA9IHRoaXMuZ2V0VXJsKGl0ZW0sIHgpO1xcbiAgICAgICAgICAgIHZhciBvYmogPSB7IHRpdGxlOiB0aXRsZSwgdXJsOiB1cmwgfTtcXG4gICAgICAgICAgICByZXR1cm4gSlNPTi5zdHJpbmdpZnkob2JqKTtcXG4gICAgICAgICAgfSk7XFxuICAgICAgICAgIHJldHVybiDlrprkvY07XFxuICAgICAgICB9KTtcXG4gICAgICAgIC8vbG9nKOS4gOe6pylcXG4gICAgICAgIC8vbG9nKOS4gOe6py5sZW5ndGgpXFxuICAgICAgICBpZiAo5LiA57qnLmxlbmd0aCA9PSAxKSB7XFxuICAgICAgICAgIGNhdGVnb3JpZXMucHVzaCjkuIDnuqcuam9pbihcXFwiXFxcXG5cXFwiKSk7XFxuICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICDkuIDnuqcuZm9yRWFjaCgoaXRlbSkgPT4ge1xcbiAgICAgICAgICAgIGNhdGVnb3JpZXMucHVzaChpdGVtLmpvaW4oXFxcIixcXFwiKSk7XFxuICAgICAgICAgIH0pO1xcbiAgICAgICAgfVxcbiAgICAgICAgLy9sb2coY2F0ZWdvcmllcylcXG4gICAgICB9KTtcXG4gICAgICBpZiAo5oqY5Y+g54q25oCBKSB7XFxuICAgICAgICBpZiAocGFnZSA9PSAxKSB7XFxuICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgdGl0bGU6IGZvbGQgPT09IFxcXCIxXFxcIiA/IOaKmOWPoCA6IOWxleW8gCxcXG4gICAgICAgICAgICB1cmw6ICQoXFxcIiNub0xvYWRpbmcjXFxcIikubGF6eVJ1bGUoXFxuICAgICAgICAgICAgICAoZm9sZCwgdSwgYWxsKSA9PiB7XFxuICAgICAgICAgICAgICAgIHB1dE15VmFyKE1ZX1JVTEUuZ3JvdXAsIGZvbGQgPT09IFxcXCIxXFxcIiA/IFxcXCIwXFxcIiA6IFxcXCIxXFxcIik7XFxuICAgICAgICAgICAgICAgIC8qYWxsLmZvckVhY2goKGl0ZW0pID0+IHtcXG4gICAgICAgICAgICAgICAgICBjbGVhck15VmFyKGl0ZW0pO1xcbiAgICAgICAgICAgICAgICB9KTsqL1xcbiAgICAgICAgICAgICAgICByZWZyZXNoUGFnZShmYWxzZSk7XFxuICAgICAgICAgICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9lbXB0eVxcXCI7XFxuICAgICAgICAgICAgICB9LFxcbiAgICAgICAgICAgICAgZm9sZCxcXG4gICAgICAgICAgICAgIOeKtuaAgSxcXG4gICAgICAgICAgICAgIOWFqOa4hVxcbiAgICAgICAgICAgICksXFxuICAgICAgICAgICAgY29sX3R5cGU6IFxcXCJzY3JvbGxfYnV0dG9uXFxcIixcXG4gICAgICAgICAgICBleHRyYToge1xcbiAgICAgICAgICAgICAgbG9uZ0NsaWNrOiB0aGlzLmFjdGlvbih7XFxuICAgICAgICAgICAgICAgIHN0YXRlOiDnirbmgIEsXFxuICAgICAgICAgICAgICAgIGFsbDog5YWo5riFLFxcbiAgICAgICAgICAgICAgICBjbDog5riF6ZmkLFxcbiAgICAgICAgICAgICAgfSksXFxuICAgICAgICAgICAgfSxcXG4gICAgICAgICAgfSk7XFxuICAgICAgICB9XFxuICAgICAgfVxcbiAgICAgIGlmIChwYWdlID09IDEpIHtcXG4gICAgICBjYXRlZ29yaWVzLmZvckVhY2goKGNhdGVnb3J5LCBpbmRleCkgPT4ge1xcbiAgICAgICAgLy9sb2coY2F0ZWdvcmllcylcXG4gICAgICAgIGxldCBzdWJfY2F0ZWdvcmllcyA9IFtdO1xcbiAgICAgICAgLyppZiAo5bCP57G75a6a5L2NLmluY2x1ZGVzKFxcXCI7XFxcIikpIHtcXG4gICAgICAgICAgc3ViX2NhdGVnb3JpZXMgPSBwZGZhKGNhdGVnb3J5LCDlsI/nsbvlrprkvY0uc3BsaXQoXFxcIjtcXFwiKVswXSk7XFxuICAgICAgICAgIGlmIChzdWJfY2F0ZWdvcmllcy5sZW5ndGgg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nM6IOa4hemZpCxcXG4gICAgICAgICAgICAgIGpzb246IGpzb24sXFxuICAgICAgICAgICAgICBzdGF0ZTog54q25oCBLFxcbiAgICAgICAgICAgICAgYWxsY2xlYXJzOiDlhajmuIUsXFxuICAgICAgICAgICAgfTtcXG5cXG4gICAgICAgICAgICAvL2xldCB1cmwgPSBwZChpdGVtLCBf5aSn57G76ZO+5o6lKTtcXG4gICAgICAgICAgICBsZXQgdXJsID0gaXRlbS51cmw7XFxuICAgICAgICAgICAgLyppZiAo5aSn57G75aSE55CGKSB7XFxuICAgICAgICAgICAgICB1cmwgPSDkuIDnuqfliIbnsbvlpITnkIYodXJsKTtcXG4gICAgICAgICAgICB9Ki9cXG4gICAgICAgICAgICAvL2xvZyh1cmwpXFxuICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgIHRpdGxlOiB0aGlzLnNldFRpdGxlKGtleS50b1N0cmluZygpLCBjYXRlX3RlbXBbaW5kZXhdLCB0aXRsZSksXFxuICAgICAgICAgICAgICBjb2xfdHlwZTogXFxcInNjcm9sbF9idXR0b25cXFwiLFxcbiAgICAgICAgICAgICAgdXJsOiAkKFxcXCJoaWtlcjovL2VtcHR5I25vTG9hZGluZyNcXFwiKS5sYXp5UnVsZSgocGFyYW1zKSA9PiB7XFxuICAgICAgICAgICAgICAgIGxldCBuZXdfY2F0ZSA9IFtdO1xcbiAgICAgICAgICAgICAgICBwYXJhbXMuY2xlYXJzLmZvckVhY2goKGl0ZW0pID0+IHtcXG4gICAgICAgICAgICAgICAgICBjbGVhck15VmFyKGl0ZW0pO1xcbiAgICAgICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICAgICAgcGFyYW1zLmFsbGNsZWFycy5mb3JFYWNoKChpdGVtKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgY2xlYXJNeVZhcihpdGVtKTtcXG4gICAgICAgICAgICAgICAgfSk7XFxuXFxuICAgICAgICAgICAgICAgIHBhcmFtcy5jYXRlX3RlbXAuZm9yRWFjaCgoY2F0ZSwgaW5kZXgpID0+IHtcXG4gICAgICAgICAgICAgICAgICBuZXdfY2F0ZS5wdXNoKGluZGV4ID09PSAwID8gcGFyYW1zLmtleS50b1N0cmluZygpIDogXFxcIjBcXFwiKTtcXG4gICAgICAgICAgICAgICAgfSk7XFxuICAgICAgICAgICAgICAgIHB1dE15VmFyKFxcXCJoZWFkLmNhdGVcXFwiLCBKU09OLnN0cmluZ2lmeShuZXdfY2F0ZSkpO1xcbiAgICAgICAgICAgICAgICBpZiAocGFyYW1zLmpzb24uY29uc3RydWN0b3IgPT09IE9iamVjdCkge1xcbiAgICAgICAgICAgICAgICAgIHB1dE15VmFyKFxcXCJkdF9cXFwiICsgcGFyYW1zLmpzb24udHlwZSwgcGFyYW1zLmpzb24udmFsdWUpO1xcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgIHB1dE15VmFyKHBhcmFtcy5zdGF0ZSwgcGFyYW1zLmpzb24pO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIHJlZnJlc2hQYWdlKHRydWUpO1xcbiAgICAgICAgICAgICAgICByZXR1cm4gXFxcImhpa2VyOi8vZW1wdHlcXFwiO1xcbiAgICAgICAgICAgICAgfSwgcGFyYW1zKSxcXG4gICAgICAgICAgICB9KTtcXG4gICAgICAgICAgfSk7XFxuICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgY29sX3R5cGU6IFxcXCJibGFua19ibG9ja1xcXCIsXFxuICAgICAgICAgIH0pO1xcbiAgICAgICAgfSBlbHNlIGlmIChmb2xkID09PSBcXFwiMVxcXCIgfHwg5oqY5Y+g54q25oCBID09IGZhbHNlKSB7XFxuICAgICAgICAgIHN1Yl9jYXRlZ29yaWVzLmZvckVhY2goKGl0ZW0sIGtleSkgPT4ge1xcbiAgICAgICAgICAgIHZhciBleHRyYXBvcyA9IGZhbHNlO1xcbiAgICAgICAgICAgIC8qaWYgKGl0ZW0uaW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AgICB9XFxuXFxuICAgICAgICAgICAgICB2YXIganNvbiA9IFxcXCJcXFwiO1xcbiAgICAgICAgICAgICAgLypzd2l0Y2ggKHRydWUpIHtcXG4gICAgICAgICAgICAgICAgY2FzZSDliIbnsbvpk77mjqUuaW5jbHVkZXMoXFxcIkBAQFxcXCIpOlxcbiAgICAgICAgICAgICAgICAgIGpzb24gPSB7XFxuICAgICAgICAgICAgICAgICAgICB0eXBlOiBwZGZoKGl0ZW0sIOWIhuexu+mTvuaOpS5zcGxpdChcXFwiQEBAXFxcIilbMF0pLFxcbiAgICAgICAgICAgICAgICAgICAgdmFsdWU6IHBkZmgoaXRlbSwg5YiG57G76ZO+5o6lLnNwbGl0KFxcXCJAQEBcXFwiKVsxXSksXFxuICAgICAgICAgICAgICAgICAgfTtcXG4gICAgICAgICAgICAgICAgICBicmVhaztcXG4gICAgICAgICAgICAgICAgY2FzZSDliIbnsbvpk77mjqUuaW5jbHVkZXMoXFxcIkBAXFxcIik6XFxuICAgICAgICAgICAgICAgICAganNvbiA9IHtcXG4gICAgICAgICAgICAgICAgICAgIHR5cGU6IOWIhuexu+mTvuaOpS5zcGxpdChcXFwiQEBcXFwiKVswXSxcXG4gICAgICAgICAgICAgICAgICAgIHZhbHVlOiBwZGZoKGl0ZW0sIOWIhuexu+mTvuaOpS5zcGxpdChcXFwiQEBcXFwiKVsxXSksXFxuICAgICAgICAgICAgICAgICAgfTtcXG4gICAgICAgICAgICAgICAgICBicmVhaztcXG4gICAgICAgICAgICAgICAgZGVmYXVsdDpcXG4gICAgICAgICAgICAgICAgICBqc29uID0gaXRlbS51cmw7XFxuICAgICAgICAgICAgICAgICAgLy8ganNvbiA9IHBkKGl0ZW0sIOWIhuexu+mTvuaOpSk7XFxuICAgICAgICAgICAgICAgICAgYnJlYWs7XFxuICAgICAgICAgICAgICB9Ki9cXG4gICAgICAgICAgICAgIGpzb24gPSBpdGVtLnVybDtcXG4gICAgICAgICAgICAgIC8qdmFyIGpzb2495YiG57G76ZO+5o6lLmluY2x1ZGVzKCdAQEAnKT97XFxuICAgICAgICAgICAgICAgICAgICB0eXBlOnBkZmgoaXRlbSzliIbnsbvpk77mjqUuc3BsaXQoJ0BAQCcpWzBdKSxcXG4gICAgICAgICAgICAgICAgICAgIHZhbHVlOnBkZmgoaXRlbSzliIbnsbvpk77mjqUuc3BsaXQoJ0BAQCcpWzFdKSxcXG4gICAgICAgICAgICAgICAgfTpwZChpdGVtLOWIhuexu+mTvuaOpSk7XFxuICAgICAgICAgICAgICAgIFxcbiAgICAgICAgICAgICAgICBqc29uPeWIhuexu+mTvuaOpS5pbmNsdWRlcygnQEAnKT97XFxuICAgICAgICAgICAgICAgICAgICB0eXBlOuWIhuexu+mTvuaOpS5zcGxpdCgnQEAnKVswXSxcXG4gICAgICAgICAgICAgICAgICAgIHZhbHVlOnBkZmgoaXRlbSzliIbnsbvpk77mjqUuc3BsaXQoJ0BAJylbMV0pLFxcbiAgICAgICAgICAgICAgICB9OnBkKGl0ZW0s5YiG57G76ZO+5o6lKTsqL1xcbiAgICAgICAgICAgIH1cXG5cXG4gICAgICAgICAgICBsZXQgcGFyYW1zID0ge1xcbiAgICAgICAgICAgICAgY2F0ZV90ZW1wOiBjYXRlX3RlbXAsXFxuICAgICAgICAgICAgICBpbmRleDogaW5kZXgsXFxuICAgICAgICAgICAgICBrZXk6IGtleSxcXG4gICAgICAgICAgICAgIHBhZ2U6IHBhZ2UsXFxuICAgICAgICAgICAgICBqc29uOiBqc29uLFxcbiAgICAgICAgICAgICAgc3RhdGU6IOeKtuaAgSxcXG4gICAgICAgICAgICAgIGFsbGNsZWFyczog5YWo5riFLFxcbiAgICAgICAgICAgIH07XFxuICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgIHRpdGxlOiB0aGlzLnNldFRpdGxlKGtleS50b1N0cmluZygpLCBjYXRlX3RlbXBbaW5kZXhdLCB0aXRsZSksXFxuICAgICAgICAgICAgICB1cmw6ICQoXFxcImhpa2VyOi8vZW1wdHlcXFwiICsgXFxcIiNub0xvYWRpbmcjXFxcIikubGF6eVJ1bGUoKHBhcmFtcykgPT4ge1xcbiAgICAgICAgICAgICAgICBwYXJhbXMuYWxsY2xlYXJzLmZvckVhY2goKGl0ZW0pID0+IHtcXG4gICAgICAgICAgICAgICAgICBjbGVhck15VmFyKGl0ZW0pO1xcbiAgICAgICAgICAgICAgICB9KTtcXG4gICAgICAgICAgICAgICAgcGFyYW1zLmNhdGVfdGVtcFtwYXJhbXMuaW5kZXhdID0gcGFyYW1zLmtleS50b1N0cmluZygpO1xcbiAgICAgICAgICAgICAgICBwdXRNeVZhcihcXFwiaGVhZC5jYXRlXFxcIiwgSlNPTi5zdHJpbmdpZnkocGFyYW1zLmNhdGVfdGVtcCkpO1xcbiAgICAgICAgICAgICAgICBpZiAocGFyYW1zLmpzb24uY29uc3RydWN0b3IgPT09IE9iamVjdCkge1xcbiAgICAgICAgICAgICAgICAgIHB1dE15VmFyKFxcXCJkdF9cXFwiICsgcGFyYW1zLmpzb24udHlwZSwgcGFyYW1zLmpzb24udmFsdWUpO1xcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICAgIHB1dE15VmFyKHBhcmFtcy5zdGF0ZSwgcGFyYW1zLmpzb24pO1xcbiAgICAgICAgICAgICAgICB9XFxuICAgICAgICAgICAgICAgIHJlZnJlc2hQYWdlKCk7XFxuICAgICAgICAgICAgICAgIHJldHVybiBcXFwiaGlrZXI6Ly9lbXB0eVxcXCI7XFxuICAgICAgICAgICAgICB9LCBwYXJhbXMpLFxcbiAgICAgICAgICAgICAgY29sX3R5cGU6IFxcXCJzY3JvbGxfYnV0dG9uXFxcIixcXG4gICAgICAgICAgICB9KTtcXG4gICAgICAgICAgfSk7XFxuICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgY29sX3R5cGU6IFxcXCJibGFua19ibG9ja1xcXCIsXFxuICAgICAgICAgIH0pO1xcbiAgICAgICAgfVxcbiAgICA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cGFnZScsICcnKTtcXG4gICAgICAgIC8vcHV0TXlWYXIodSwgcCk7XFxuICAgICAgfSwg54q25oCBKVxcbiAgICApO1xcbiAgfSxcXG4gIGpzb25MaXN0OiBmdW5jdGlvbiAoYXJyLCBqc29uLCBydWxlKSB7XFxuICAgIGlmIChqc29uLmNvbnN0cnVjdG9yICE9IE9iamVjdCkge1xcbiAgICAgIHRyeSB7XFxuICAgICAgICBqc29uID0gSlNPTi5wYXJzZShqc29uKTtcXG4gICAgICB9IGNhdGNoIHt9XFxuICAgIH1cXG4gICAganNvbltydWxlLmxpc3RdLmZvckVhY2goKGl0ZW0pID0+IHtcXG4gICAgICB2YXIgaW1nID0gZXZhbChydWxlLmltZykgKyBydWxlLnJlZjtcXG4gICAgICB2YXIgaHJlZiA9IGV2YWwocnVsZS51cmwpO1xcbiAgICAgIGhyZWYgPSBydWxlLmltdCA/IGhyZWYgKyBcXFwiI2ltbWVyc2l2ZVRoZW1lI1xcXCIgOiBocmVmO1xcbiAgICAgIHZhciBsYXp5ID0gcnVsZS5sYXp5ID8gcnVsZS5sYXp5IDogXFxcIlxcXCI7XFxuICAgICAgdmFyIGRkID0ge1xcbiAgICAgICAgdGl0bGU6IGV2YWwocnVsZS50aXRsZSksXFxuICAgICAgICBkZXNjOiBldmFsKHJ1bGUuZGVzYyksXFxuICAgICAgICBjb250ZW50OiBldmFsKHJ1bGUuY29udGVudCksXFxuICAgICAgICBwaWNfdXJsOiBpbWcsXFxuICAgICAgICB1cmw6IFxcXCJoaWtlcjovL2VtcHR5IyNcXFwiICsgaHJlZixcXG4gICAgICAgIGNvbF90eXBlOiBydWxlLmNvbF90eXBlLFxcbiAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgaW1nOiBpbWcsXFxuICAgICAgICB9LFxcbiAgICAgIH07XFxuICAgICAgaWYgKGxhenkgIT0gXFxcIlxcXCIpIHtcXG4gICAgICAgIGRkW1xcXCJ1cmxcXFwiXSA9IGhyZWYgKyBsYXp5O1xcb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mxIYW5kbGUoaXRlbSwgcnVsZSk7XFxuICAgICAgICB2YXIgY29udGVudCA9IHRoaXMuc2V0Q29udGVudChpdGVtLCBydWxlLmNvbnRlbnQpO1xcbiAgICAgICAgaWYgKGkgPT0gbGlzdC5sZW5ndGggLSAxKSB7XFxuICAgICAgICAgIGlkID0gXFxcImxhc3RpZF9cXFwiICsgcGFnZTtcXG4gICAgICAgICAgY2xzID0gXFxcImxhc3RtYXJrXFxcIjtcXG4gICAgICAgIH1cXG4gICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgIHRpdGxlOiB0aXRsZSxcXG4gICAgICAgICAgZGVzYzogZGVzYyxcXG4gICAgICAgICAgcGljX3VybDogaW1nLFxcbiAgICAgICAgICB1cmw6IFxcXCJoaWtlcjovL2VtcHR5IyNcXFwiICsgdXJsLFxcbiAgICAgICAgICBjb250ZW50OiBjb250ZW50LFxcbiAgICAgICAgICBjb2xfdHlwZTogcnVsZS5jb2xfdHlwZSxcXG4gICAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgICB0aXRsZTogdGl0bGUsXFxuICAgICAgICAgICAgaW1nOiBpbWcsXFxuICAgICAgICAgICAgaWQ6IGlkLFxcbiAgICAgICAgICAgIGNsczogY2xzLFxcbiAgICAgICAgICB9LFxcbiAgICAgICAgfSk7XFxuICAgICAgICBpZiAoaSA9PSBsaXN0Lmxlbmd0aCAtIDEgJiYgc2hvdykge1xcbiAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgIGNvbF90eXBlOiBcXFwibGluZVxcXCIsXFxuICAgICAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgICAgIGlkOiBcXFwicGFnZWxpbmVcXFwiLFxcbiAgICAgICAgICAgIH0sXFxuICAgICAgICAgIH0pO1xcblxcbiAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgIHRpdGxlOiBcXFwi4oCc4oCc4oCd4oCdPHNtYWxsPuWKoOi9veS4rS4uLjwvc21hbGw+XFxcIixc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J2ZvbGQnKTtcXG4gICAgICAgICAgICAgICAgY2xlYXJNeVZhcih4KTtcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgICAgIGZvciAobGV0IGkgPSAwOyBpIDwgc29ydHM7IGkrKykge1xcbiAgICAgICAgICAgICAgICBjbGVhck15VmFyKCdwbGF5bGlzdF8nICsgaSk7XFxuICAgICAgICAgICAgfVxcbiAgICAgICAgfSwgbGlzdCwgc29ydHMpKVxcbiAgICB9LFxcbiAgICBzbWFsbDogZnVuY3Rpb24oc3RyLCBjb2xvcikge1xcbiAgICAgICAgcmV0dXJuICfigJjigJjigJnigJk8c21hbGw+PGZvbnQgY29sb3I9XFxcIicgKyAoY29sb3IgfHwgJycpICsgJ1xcXCI+JyArIHN0ciArICc8L2ZvbnQ+PC9zbWFsbD4nO1xcbiAgICB9LFxcbiAgICDlo7DmmI46IGZ1bmN0aW9uKCkge1xcbiAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICB0aXRsZTogdGhpcy5zbWFsbCgn5Lul5LiK5pWw5o2u5p2l5rqQ5LqO572R57uc77yM5aaC5oKo5Zac5qyi77yM6K+35pSv5oyB5a6Y5pa577yBJywgJyM4NzFGNzgnKSxcXG4gICAgICAgICAgICBkZXNjOiB0aGlzLnNtYWxsKCfmraTop4TliJnku4XpmZDlrabkuaDkuqTmtYHkvb/nlKjvvIzor7fkuo7lr7zlhaXlkI4yNOWwj+aXtuWGheWIoOmZpO+8jOS7u+S9lee7hOe7h+aIluS4quS6uuS4jeW+l+S7peS7u+S9leaWueW8j+aWueazleS8oOaSreatpOinhOWImeeahOaVtOS9k+aIlumDqOWIhu+8gScsICcjRjIwQzAwJyksXFxuICAgICAgICAgICAgdXJsOiAnaGlrZXI6Ly9lbXB0eScsXFxuICAgICAgICAgICAgY29sX3R5cGU6ICd0ZXh0X2NlbnRlcl8xJ1xcbiAgICAgICAgfSk7XFxuICAgIH0sXFxuICAgIFxcbiAgICBzZXRUYWJzOiBmdW5jdGlvbih0YWJzLCB2YXJpLCBzaHNvcnQpIHtcXG4gICAgICAgIHNoc29ydCA9IHNoc29ydCA/IHNoc29ydCA6ICdzaHNvcnQnO1xcbiAgICAgICAgdmFyIHRpdGxlID0gKGdldE15VmFyKHNoc29ydCwgJzAnKSA9PSAnMScpID8gJzxiPjxzcGFuIHN0eWxlPVxcXCJjb2xvcjogI0ZGMDAwMFxcXCI+6YCG5bqPPC9zcGFuPjwvYj4nIDogJzxiPjxzcGFuIHN0eWxlPVxcXCJjb2xvcjogIzFhYWQxOVxcXCI+5q2j5bqPPC9zcGFuPjwvYj4nXFxuICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgIHRpdGxlOiB2YXJpICsgJzonICsgdGl0bGUsXFxuICAgICAgICAgICAgZGVzYzogJ+WFsScgKyB0YWJzLmxlbmd0aCArICfmnaHnur/ot68nLFxcbiAgICAgICAgICAgIHVybDogJCgnI25vTG9hZGluZyMnKS5sYXp5UnVsZSgoc2hzb3J0KSA9PiB7XFxuICAgICAgICAgICAgICAgIGxldCBjb25mID0gZ2V0TXlWYXIoc2hzb3J0LCAnMCcpO1xcbiAgICAgICAgICAgICAgICBpZiAoY29uZiA9PSAnMScpIHtcXG4gICAgICAgICAgICAgICAgICAgIHB1dE15VmFyKHNoc29ydCwgJzAnKTtcXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcXG4gICAgICAgICAgICAgICAgICAgIHB1dE15VmFyKHNoc29ydCwgJzEnKTtcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICByZWZyZXNoUGFnZSgpXFxuICAgICAgICAgICAgICAgIHJldHVybiAndG9hc3Q6Ly/liIfmjaLmjpLluo/miJDlip8nXFxuICAgICAgICAgICAgfSwgc2hzb3J0KSxcXG4gICAgICAgICAgICBjb2xfdHlwZTogJ2F2YXRhcicsXFxuICAgICAgICAgICAgcGljX3VybDogJ2h0dHBzOi8vZ2hwcm94eS5uZXQvaHR0cHM6Ly9yYXcuZ2l0aHVidXN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bm9Mb2FkaW5nI0BsYXp5UnVsZT0uanM6cHV0TXlWYXIoJ1xcXCIgKyB2YXJpICsgXFxcIicsICdcXFwiICsgaSArIFxcXCInKTtyZWZyZXNoUGFnZShmYWxzZSk7J3RvYXN0Oi8v5YiH5o2i5oiQ5Yqf77yBJzsnI25vSGlzdG9yeSNoaWtlcjovL2VtcHR5J1xcXCI7XFxuICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgdGl0bGU6IGdldE15VmFyKHZhcmksICcwJykgPT0gaSA/ICfigJzigJwnICsgdGFic1tpXSArICfigJ3igJ0nIDogdGFic1tpXSxcXG4gICAgICAgICAgICAgICAgdXJsOiB1cmwsXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnc2Nyb2xsX2J1dHRvbidcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgfVxcbiAgICB9LFxcbiAgICBzZXRMaXN0czogZnVuY3Rpb24obGlzdHMsIGluZGV4LCBzaHNvcnQpIHtcXG4gICAgICAgIHNoc29ydCA9IHNoc29ydCA/IHNoc29ydCA6ICdzaHNvcnQnO1xcbiAgICAgICAgdmFyIGxpc3QgPSBsaXN0c1tpbmRleF07XFxuICAgICAgICBpZiAoZ2V0TXlWYXIoc2hzb3J0KSA9PSAnMScgJiYgbGlzdHMubGVuZ3RoID4gMCkge1xcbiAgICAgICAgICAgIHZhciBsaXN0ID0gbGlzdHNbaW5kZXhdLnJldmVyc2UoKTtcXG4gICAgICAgIH1cXG4gICAgICAgIGZvciAodmFyIGogaW4gbGlzdCkge1xcbiAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiBsaXN0W2pdLnRpdGxlLFxcbiAgICAgICAgICAgICAgICB1cmw6IGxpc3Rbal0udXJsLFxcbiAgICAgICAgICAgICAgICBjb2xfdHlwZTogbGlzdC5sZW5ndGggPiAzID8gJ3RleHRfNCcgOiAndGV4dF8yJyxcXG4gICAgICAgICAgICAgICAgZXh0cmE6IHtcXG4gICAgICAgICAgICAgICAgICAgIGlkOiBsaXN0W2pdLnVybC5yZXBsYWNlKC9AbGF6eVJ1bGVbXFxcXHNcXFxcU10rL2csICcnKSxcXG4gICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIH0pO1xcbiAgICAgICAgfVxcbiAgICB9LFxcbiAgICBnZXRUYWJzOiBmdW5jdGlvbihwYXJzZSkge1xcbiAgICAgICAgdmFyIHRhYnMgPSBbXTtcXG4gICAgICAgIHZhciBhcnRzID0gcGRmYShodG1sLCBwYXJzZS7nur/ot68pO1xcbiAgICAgICAgdmFyIOe6v+i3r+WQjSA9IHBhcnNlLue6v+i3r+WQjeensDtcXG4gICAgICAgIHZhciDmm7/mjaLlh73mlbAgPSAnJztcXG4gICAgICAgIGlmIChwYXJzZS7nur/ot6/lkI3np7AuaW5jbHVkZXMoJ0BAJykpIHtcXG4gICAgICAgICAgICDnur/ot6/lkI0gPSBwYXJzZS7nur/ot6/lkI3np7Auc3BsaXQoJ0BAJylbMF07XFxuICAgICAgICAgICAg5pu/5o2i5Ye95pWwID0gcGFyc2Uu57q/6Lev5ZCN56ewLnNwbGl0KCdAQCcpWzFdO1xcbiAgICAgICAgfVxcbiAgICAgICAgZm9yICh2YXIgaSBpbiBhcnRzKSB7XFxuICAgICAgICAgICAgdmFyIGxpbmVuYW1lID0gcGRmaChhcnRzW2ldLCDnur/ot6/lkI0pO1xcbiAgICAgICAgICAgIGlmICjmm7/mjaLlh73mlbAgIT0gJycpIHtcXG4gICAgICAgICAgICAgICAgbGluZW5hbWUgPSBldmFsKCdsaW5lbmFtZScgKyDmm7/mjaLlh73mlbApO1xcbiAgICAgICAgICAgIH1cXG4gICAgICAgICAgICB0YWJzLnB1c2gobGluZW5hbWUpO1xcbiAgICAgICAgfVxcblxcbiAgICAgICAgcmV0dXJuIHRhYnM7XFxuICAgIH0sXFxuICAgIGdldExpc3RzOiBmdW5jdGlvbihwYXJzZSkge1xcbiAgICAgICAgdmFyIGxpc3RzID0gW107XFxuICAgICAgICB2YXIgY29udHMgPSBwZGZhKGh0bWwsIHBhcnNlLumAiembhik7XFxuICAgICAgICB2YXIg6YCJ6ZuG5ZCN56ewID0gcGFyc2Uu6YCJ6ZuG5ZCN56ewID8gcGFyc2Uu6YCJ6ZuG5ZCN56ewIDogJ2EmJlRleHQnO1xcbiAgICAgICAgdmFyIOmAiembhumTvuaOpSA9IHBhcnNlLumAiembhumTvuaOpSA/IHBhcnNlLumAiembhumTvuaOpSA6ICdhJiZocmVmJztcXG4gICAgICAgIHZhciDop6PmnpAgPSBwYXJzZS7op6PmnpAgPyBwYXJzZS7op6PmnpAgOiAnJztcXG4gICAgICAgIHZhciB0ZW1wID0gW107XFxuICAgICAgICBmb3IgKHZhciBpIGluIGNvbnRzKSB7XFxuICAgICAgICAgICAgaWYgKHBhcnNlLumAiembhuWIl+ihqCAhPSB1bmRlZmluZWQpIHtcXG4gICAgICAgICAgICAgICAgbGlzdHMucHVzaChwZGZhKGNvbnRzW2ldLCBwYXJzZS7pgInpm4bliJfooagpLm1hcCh4ID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiB7XFxuICAgICAgICAgICAgICAgICAgICAgICAgdGl0bGU6IHBkZmgoeCwg6YCJ6ZuG5ZCN56ewKS5yZXBsYWNlKC/nrKx85YWofOmbhnzor5185pyA5pawfOacny9nLCAnJykucmVwbGFjZSgv6aKE5ZGKL2csICfwn5OiJyksXFxuXFxuICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiBwZCh4LCDpgInpm4bpk77mjqUpICsg6Kej5p6QLFxcbiAgICAgICAgICAgICAgICAgICAgfVxcbiAgICAgICAgICAgICAgICB9KSlcXG4gICAgICAgICAgICB9IGVsc2Uge1xcbiAgICAgICAgICAgICAgICB2YXIgdXJsID0gcGQoY29udHNbaV0sIOmAiembhumTvuaOpSk7XFxuICAgICAgICAgICAgICAgIGlmICgh6YCJ6ZuG6ZO+5o6lLmluY2x1ZGVzKCdocmVmJykpIHtcXG4gICAgICAgICAgICAgICAgICAgIHVybCA9IHBkZmgoY29udHNbaV0sIOmAiembhumTvuaOpSk7XFxuICAgICAgICAgICAgICAgIH1cXG4gICAgICAgICAgICAgICAgdGVtcC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgICAgIHRpdGxlOiBwZGZoKGNvbnRzW2ldLCDpgInpm4blkI3np7ApLFxcbiAgICAgICAgICAgICAgICAgICAgdXJsOiB1cmwgKyDop6PmnpAsXFxuICAgICAgICAgICAgICAgIH0pXFxuICAgICAgICAgICAgfVxcbiAgICAgICAgfVxcbiAgICAgICAgbGV0IOWAkuW6jyA9IHBhcnNlLuWAkuW6jyA/IHBhcnNlLuWAkuW6jyA6IGZhbHNlO1xcbiAgICAgICAgdmFyIHJlc3VsdHMgPSBsaXN0cy5sZW5ndGggPyBsaXN0cyA6IFt0ZW1wXTtcXG4gICAgICAgIGlmICjlgJLluo8pIHtcXG4gICAgICAgICAgICByZXN1bHRzID0gcmVzdWx0cy5tYXAoeCA9PiB4LnJldmVyc2UoKSk7XFxuICAgICAgICB9XFxuICAgICAgICByZXR1cm4gcmVzdWx0cztcXG4gICAgfSxcXG4gICAgZ2V0UGxheWVyczogZnVuY3Rpb24ocGFyc2UpIHtcXG4gICAgICAgIHRoaXMuY2xvc2UocGFyc2UubWFwKHggPT4geC7nsbvlnospLCBwYXJzZS5sZW5ndGgpO1xcbiAgICAgICAgcGFyc2UuZm9yRWFjaCgoaXRlbSwgaSkgPT4ge1xcbiAgICAgICAgICAgIHZhciB0YWJzID0gWyfkuLvnur8nXTtcXG4gICAgICAgICAgICBpZiAoaXRlbS7nur/ot68gIT0gdW5kZWZpbmVkKSB7XFxuICAgICAgICAgICAgICAgIHRhYnMgPSB0aGlzLmdldFRhYnMoaXRlbSk7XFxuICAgICAgICAgICAgfVxcbiAgICAgICAgICAgIHZhciBsaXN0cyA9IHRoaXMuZ2V0TGlzdHMoaXRlbSk7XFxuICAgICAgICAgICAgaWYgKGxpc3RzLnNvbWUoeCA9PiB4Lmxlbmd0aCA+IDApKSB7XFxuICAgICAgICAgICAgICAgIHRoaXMuc2V0VGFicyh0YWJzLCBpdGVtLuexu+WeiywgJ3BsYXlsaXN0XycgKyBpKTtcXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgaWYgKGdldE15VmFyKGl0ZW0u57G75Z6LICsgJ2ZvbGQnLCAnMScpID09ICcxJykge1xcbiAgICAgICAgICAgICAgICB0aGlzLnNldExpc3RzKGxpc3RzLCBnZXRNeVZhcihpdGVtLuexu+WeiywgJzAnKSwgJ3BsYXlsaXN0XycgKyBpKTtcXG4gICAgICAgICAgICB9XFxuICAgICAgICAgICAgZC5wdXNoKHtcXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6ICdibGFua19ibG9jaydcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgfSlcXG4gICAgfSxcXG59XCJ9LHtcImNvbF90eXBlXCI6XCJtb3ZpZV8zXCIsXCJuYW1lXCI6XCLop6PmnpBcIixcInBhdGhcIjpcImxhenlcIixcInJ1bGVcIjpcInZhciBsYXp5ID0gJCgnJykubGF6eVJ1bGUoKCkgPT4ge1xcbiAgICB0cnkge1xcbiAgICAgICAgdmFyIGh0bWwgPSBKU09OLnBhcnNlKHJlcXVlc3QoaW5wdXQpLm1hdGNoKC9yIHBsYXllcl8uKj89KC4qPyk8LylbMV0pXFxuICAgICAgICAgICAgdmFyIHVybCA9IGh0bWwudXJsXFxuICAgICAgICAgICAgaWYgKGh0bWwuZW5jcnlwdCA9PSAnMScpIHtcXG4gICAgICAgICAgICAgICAgdXJsID0gdW5lc2NhcGUodXJsKTtcXG4gICAgICAgICAgICB9IGVsc2UgaWYgKGh0bWwuZW5jcnlwdCA9PSAnMicpIHtcXG4gICAgICAgICAgICAgICAgdXJsID0gdW5lc2NhcGUoYmFzZTY0RGVjb2RlKHVybCkpO1xcbiAgICAgICAgICAgIH1cXG4gICAgICAgICAgICBpZiAoL20zdTh8bXA0Ly50ZXN0KHVybCkpIHtcXG4gICAgICAgICAgICAgICAgcmV0dXJuIHVybFxcbiAgICAgICAgICAgIH0gZWxzZSB7XFxuICAgICAgICAgICAgICAgIHJldHVybiAndmlkZW86Ly8nICsgaW5wdXRcXG4gICAgICAgICAgICB9XFxuICAgIH0gY2F0Y2ggKGUpIHtcXG4gICAgICAgIHJldHVybiAndmlkZW86Ly8nICsgaW5wdXRcXG4gICAgfVxcbn0pXCJ9XSIsImljb24iOiJodHRwOi8vd3d3LmRtYW5kNS5jb20vZmF2aWNvbi5pY28iLCJwcm94eSI6IiJ9
Add Comment
Please, Sign In to add comment