xiaomianao666

小程序:戈雪

Oct 18th, 2022
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 海阔视界规则分享,当前分享的是:小程序¥home_rule_v2¥base64://@戈雪@eyJmaXJzdEhlYWRlciI6ImNsYXNzIiwibGFzdF9jaGFwdGVyX3J1bGUiOiIiLCJ0aXRsZSI6IuaIiOmbqiIsImF1dGhvciI6IkBMb3lEZ0lrIiwidXJsIjoiaGlrZXI6Ly9lbXB0eSIsInZlcnNpb24iOjQwLCJjb2xfdHlwZSI6Imljb25fc21hbGxfNCIsImNsYXNzX25hbWUiOiIiLCJ0eXBlIjoib3RoZXIiLCJjbGFzc191cmwiOiIiLCJhcmVhX25hbWUiOiIiLCJhcmVhX3VybCI6IiIsInNvcnRfbmFtZSI6IiIsInllYXJfbmFtZSI6IiIsInNvcnRfdXJsIjoiIiwieWVhcl91cmwiOiIiLCJmaW5kX3J1bGUiOiJ7XCJsYXN0X2NoYXB0ZXJfcnVsZVwiOiBcIlwiLCBcInBhZ2VMaXN0XCI6IFt7XCJjb2xfdHlwZVwiOiBcIm1vdmllXzNcIiwgXCJuYW1lXCI6IFwi6aG16Z2iXCIsIFwicGF0aFwiOiBcImNvbmZpZy5odG1sXCIsIFwicnVsZVwiOiBcImNvbnN0IGVtcHR5ID0gJ2hpa2VyOi8vZW1wdHknXFxuY29uc3QgcGFnZSA9IE1ZX1BBR0U7XFxuXFxuY29uc3QgQ29sb3IgPSAodGVzdCkgPT4ge1xcbiAgICByZXR1cm4gJzxmb250IGNvbG9yPVxcXCIjRkE3Mjk4XFxcIj4nICsgdGVzdCArICc8L2Zyb250Pic7XFxufVxcblxcbmNvbnN0IFN0cm9uZyA9ICh0ZXN0KSA9PiB7XFxuICAgIHJldHVybiAnPHN0cm9uZz4nICsgdGVzdCArICc8L3N0cm9uZz4nO1xcbn1cXG5cXG5jb25zdCBTbWFsbCA9ICh0ZXN0KSA9PiB7XFxuICAgIHJldHVybiAnPHNtYWxsPicgKyB0Z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xcbiAgICAgICAgYm9keTogRW5jb2RlKEpTT04uc3RyaW5naWZ5KGJvZHkpKSxcXG4gICAgICAgIG1ldGhvZDogJ1BPU1QnXFxuICAgIH0pKVxcbiAgICByZXR1cm4gSlNPTi5wYXJzZShkYXRhKS5kYXRhLnJlc3VsdHNcXG59XFxuXFxuY29uc3QgZ2V0QmFzZVBhcnNlID0gKCkgPT4ge1xcbiAgICBjb25zdCB0YWJzID0gWyfmiYvmnLrlo4HnurgnLCAn5Yqo5oCB5aOB57q4JywgJ+eUteiEkeWjgee6uCddO1xcbiAgICBjb25zdCBkID0gW11cXG4gICAgaWYgKHBhZ2UgPT0gMSkge1xcbiAgICAgICAgdGFicy5mb3JFYWNoKGl0ZW0gPT4ge1xcbiAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiBpdGVtID09IGdldE15VmFyKCfliIbnu4QnLCB0YWJzWzBdKSA/IFJpY2goU3Ryb25nKENvbG9yKGl0ZW0pKSkgOiBpdGVtLFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoJyNub0xvYWRpbmcjJykubGF6eVJ1bGUoKGl0ZW0sIGVtcHR5KSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICBwdXRNeVZhcign5YiG57uEJywgaXRlbSk7XFxuICAgICAgICAgICAgICAgICAgICByZWZyZXNoUGFnZSgpO1xcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGVtcHR5O1xcbiAgICAgICAgICAgICAgICB9LCBpdGVtLCBlbXB0eSksXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnc2Nyb2xsX2J1dHRvbidcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgfSlcXG4gICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgY29sX3R5cGU6ICdibGFua19ibG9jaydcXG4gICAgICAgIH0pXFxuICAgIH1cXG4gICAgc3dpdGNoIChnZXRNeVZhcign5YiG57uEJywgdGFic1swXSkpIHtcXG4gICAgIC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ICAgICB9XFxuICAgIH1cXG4gICAgaWYgKHBhZ2UgPT0gMSkge1xcbiAgICAgICAgaVRhZy5mb3JFYWNoKGl0ZW0gPT4ge1xcbiAgICAgICAgICAgIHRhZyA9IGl0ZW0udGFnXFxuICAgICAgICAgICAgbmFtZSA9IGl0ZW0udGFiTmFtZVxcbiAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiB0YWcgPT0gZ2V0TXlWYXIoZ2V0TXlWYXIoJ+WIhue7hCcsIHRhYnNbMF0pICsgJ+WIhuexuycsIGlUYWdbMF0udGFnKSA/IFJpY2goU3Ryb25nKENvbG9yKG5hbWUpKSkgOiBuYW1lLFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoJyNub0xvYWRpbmcjJykubGF6eVJ1bGUoKHRhZywgZW1wdHksIHRhYnMpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHB1dE15VmFyKGdldE15VmFyKCfliIbnu4QnLCB0YWJzWzBdKSArICfliIbnsbsnLCB0YWcpO1xcbiAgICAgICAgICAgICAgICAgICAgcmVmcmVzaFBhZ2UoKTtcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBlbXB0eTtcXG4gICAgICAgICAgICAgICAgfSwgdGFnLCBlbXB0eSwgdGFicyksXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnc2Nyb2xsX2J1dHRvbidcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgfSlcXG4gICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgY29sX3R5cGU6ICdibGFua19ibG9jaydcXG4gICAgICAgIH0pXFxuICAgIH1cXG4gICAgb3JkZXJzID0gWyfmnIDmlrAnLCAn5pyA54OtJ107XFxuICAgIGlmIChwYWdlID09IDEpIHtcXG4gICAgICAgIG9yZGVycy5mb3JFYWNoKGl0ZW0gPT4ge1xcbiAgICAgICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgICAgIHRpdGxlOiBpdGVtID09IGdldE15VmFyKGdldE15VmFyKCfliIbnu4QnLCB0YWJzWzBdKSArICfmjpLluo8nLCBvcmRlcnNbMF0pID8gUmljaChTdHJvbmcoQ29sb3IoaXRlbSkpKSA6IGl0ZW0sXFxuICAgICAgICAgICAgICAgIHVybDogJCgnI25vTG9hZGluZyMnKS5sYXp5UnVsZSgoaXRlbSwgZW1wdHksIHRhYnMpID0+IHtcXG4gICAgICAgICAgICAgICAgICAgIHB1dE15VmFyKGdldE15VmFyKCfliIbnu4QnLCB0YWJzWzBdKSArICfmjpLluo8nLCBpdGVtKTtcXG4gICAgICAgICAgICAgICAgICAgIHJlZnJlc2hQYWdlKCk7XFxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gZW1wdHk7XFxuICAgICAgICAgICAgICAgIH0sIGl0ZW0sIGVtcHR5LCB0YWJzKSxcXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6ICdzY3JvbGxfYnV0dG9uJ1xcbiAgICAgICAgICAgIH0pXFxuICAgICAgICB9KVxcbiAgICB9XFxuICAgIHN3aXRjaCAoZ2V0TXlWYXIoZ2V0TXlWYXIoJ+WIhue7hCcsIHRhYnNbMF0pICsgJ+aOkuW6jycsIG9yZGVyc1swXSkpIHtcXG4gICAgICAgIGNhc2Ugb3JkZXJzWzBdOlxcbiAgICAgICAgICAgIG9yZGVyID0gJy1jcmVhdGVkQXQnXFxuICAgICAgICAgICAgYnJlYWs7XFxuICAgICAgICBjYXNlIG9yZGVyc1sxXTpcXG4gICAgICAgICAgICBvcmRlciA9ICctdXBkYXRlZEF0J1xcbiAgICAgICAgICAgIGJyZWFrO1xcbiAgICB9XFxuICAgIHRhZ3MgPSBnZXRNeVZhcihnZXRNeVZhcign5YiG57uEJywgdGFic1swXSkgKyAn5YiG57G7JywgaVRhZ1swXS50YWcpXFxuICAgIGJvZHkgPSB7XFxuICAgICAgICBcXFwiY1xcXCI6IFxcXCJOZXdXYWxscGFwZXJcXFwiLFxcbiAgICAgICAgXFxcImRhdGFcXFwi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gaVRhZyA9IFtdO1xcbiAgICAgICAgfVxcbiAgICB9XFxuICAgIGlmIChwYWdlID09IDEpIHtcXG4gICAgICAgIGlUYWcuZm9yRWFjaChpdGVtID0+IHtcXG4gICAgICAgICAgICB0YWdzID0gaXRlbS5yZXF1ZXN0X3BhcmFtcy5zaXplX3R5cGUgfHwgaXRlbS5jYXRlZ29yeV9uYW1lXFxuICAgICAgICAgICAgbmFtZSA9IGl0ZW0ubmFtZSB8fCBpdGVtLmNhdGVnb3J5X25hbWVcXG4gICAgICAgICAgICBkLnB1c2goe1xcbiAgICAgICAgICAgICAgICB0aXRsZTogdGFncyA9PSBnZXRNeVZhcihnZXRNeVZhcign5YiG57uEJywgdGFic1swXSkgKyAn5YiG57G7JywgJycgKyAoaVRhZ1swXS5yZXF1ZXN0X3BhcmFtcy5zaXplX3R5cGUgfHwgaVRhZ1swXS5jYXRlZ29yeV9uYW1lKSArICcnKSA/IFJpY2goU3Ryb25nKENvbG9yKG5hbWUpKSkgOiBuYW1lLFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoJyNub0xvYWRpbmcjJykubGF6eVJ1bGUoKHRhZ3MsIGVtcHR5LCB0YWJzKSA9PiB7XFxuICAgICAgICAgICAgICAgICAgICBwdXRNeVZhcihnZXRNeVZhcign5YiG57uEJywgdGFic1swXSkgKyAn5YiG57G7JywgdGFncyk7XFxuICAgICAgICAgICAgICAgICAgICByZWZyZXNoUGFnZSgpO1xcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGVtcHR5O1xcbiAgICAgICAgICAgICAgICB9LCB0YWdzLCBlbXB0eSwgdGFicyksXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnc2Nyb2xsX2J1dHRvbidcXG4gICAgICAgICAgICB9KVxcbiAgICAgICAgfSlcXG4gICAgICAgIGQucHVzaCh7XFxuICAgICAgICAgICAgY29sX3R5cGU6ICdibGFua19ibG9jaydcXG4gICAgICAgIH0pXFxuICAgIH1cXG4gICAgb3JkZXJzID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XFxuICAgICAgICAgICAgICAgIHRpdGxlOiB0YWcgPT0gZ2V0TXlWYXIoZ2V0TXlWYXIoJ+WIhue7hCcsIHRhYnNbMF0pICsgJ+WIhuexuycsIGlUYWdbMF0udGFnKSA/IFJpY2goU3Ryb25nKENvbG9yKG5hbWUpKSkgOiBuYW1lLFxcXFxuICAgICAgICAgICAgICAgIHVybDogJCgnI25vTG9hZGluZyMnKS5sYXp5UnVsZSgodGFnLCBlbXB0eSwgdGFicykgPT4ge1xcXFxuICAgICAgICAgICAgICAgICAgICBwdXRNeVZhcihnZXRNeVZhcign5YiG57uEJywgdGFic1swXSkgKyAn5YiG57G7JywgdGFnKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgcmVmcmVzaFBhZ2UoKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGVtcHR5O1xcXFxuICAgICAgICAgICAgICAgIH0sIHRhZywgZW1wdHksIHRhYnMpLFxcXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiAnc2Nyb2xsX2J1dHRvbidcXFxcbiAgICAgICAgICAgIH0pXFxcXG4gICAgICAgIH0pXFxcXG4gICAgICAgIGQucHVzaCh7XFxcXG4gICAgICAgICAgICBjb2xfdHlwZTogJ2JsYW5rX2Jsb2NrJ1xcXFxuICAgICAgICB9KVxcXFxuICAgIH1cXFxcbiAgICBvcmRlcnMgPSBbJ+acgOaWsCcsICfmnIDng60nXTtcXFxcbiAgICBpZiAocGFnZSA9PSAxKSB7XFxcXG4gICAgICAgIG9yZGVycy5mb3JFYWNoKGl0ZW0gPT4ge1xcXFxuICAgICAgICAgICAgZC5wdXNoKHtcXFxcbiAgICAgICAgICAgICAgICB0aXRsZTogaXRlbSA9PSBnZXRNeVZhcihnZXRNeVZhcign5YiG57uEJywgdGFic1swXSkgKyAn5o6S5bqPJywgb3JkZXJzWzBdKSA/IFJpY2goU3Ryb25nKENvbG9yKGl0ZW0pKSkgOiBpdGVtLFxcXFxuICAgICAgICAgICAgICAgIH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ign5YiG57uEJywgdGFic1swXSkgKyAn5YiG57G7JywgdGFncyk7XFxcXG4gICAgICAgICAgICAgICAgICAgIHJlZnJlc2hQYWdlKCk7XFxcXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBlbXB0eTtcXFxcbiAgICAgICAgICAgICAgICB9LCB0YWdzLCBlbXB0eSwgdGFicyksXFxcXG4gICAgICAgICAgICAgICAgY29sX3R5cGU6ICdzY3JvbGxfYnV0dG9uJ1xcXFxuICAgICAgICAgICAgfSlcXFxcbiAgICAgICAgfSlcXFxcbiAgICAgICAgZC5wdXNoKHtcXFxcbiAgICAgICAgICAgIGNvbF90eXBlOiAnYmxhbmtfYmxvY2snXFxcXG4gICAgICAgIH0pXFxcXG4gICAgfVxcXFxuICAgIG9yZGVycyA9IFsn5pyA5pawJywgJ+eDremXqCcsICfmnIDng60nLCAn5Y+R546wJ107XFxcXG4gICAgaWYgKHBhZ2UgPT0gMSkge1xcXFxuICAgICAgICBvcmRlcnMuZm9yRWFjaChpdGVtID0+IHtcXFxcbiAgICAgICAgICAgIGQucHVzaCh7XFxcXG4gICAgICAgICAgICAgICAgdGl0bGU6IGl0ZW0gPT0gZ2V0TXlWYXIoZ2V0TXlWYXIoJ+WIhue7hCcsIHRhYnNbMF0pICsgJ+aOkuW6jycsIG9yZGVyc1sxXSkgPyBSaWNoKFN0cm9uZyhDb2xvcihpdGVtKSkpIDogaXRlbSxcXFxcbiAgICAgICAgICAgICAgICB1cmw6ICQoJyNub0xvYWRpbmcjJykubGF6eVJ1bGUoKGl0ZW0sIGVtcHR5LCB0YWJzKSA9PiB7XFxcXG4gICAgICAgICAgICAgICAgICAgIHB1dE15VmFyKGdldE15VmFyKCfliIbnu4QnLCB0YWJzWzBdKSArICfmjpLluo8nLCBpdGVtKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgcmVmcmVzaFBhZ2UoKTtcXFxcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGVtcHR5O1xcXFxuICAgICAgICAgICAgICAgIH0sIGl0ZW0sIGVtcHR5LCB0YWJzKSxcXFxcbiAgICAgICAgICAgICAgICBjb2xfdHlwZTogJ3Njcm9sbF9idXR0b24nXFxcXG4gICAgICAgICAgICB9KVxcXFxuICAgICAgICB9KVxcXFxuICAgIH1cXFxcbiAgICBzd2l0Y2ggKGdldE15VmFyKGdldE15VmFyKCfliIbnu4QnLCB0YWJzWzBdKSArICfmjpLluo8nLCBvcmRlcnNbMV0pKSB7XFxcXG4gICAgICAgIGNhc2Ugb3JkZXJzWzBdOlxcXFxuICAgICAgICAgICAgb3JkZXIgPSAxXFxcXG4gICAgICAgICAgICBicmVhaztcXFxcbiAgICAgICAgY2FzZSBvcmRlcnNbMV06XFxcXG4gICAgICAgICAgICBvcmRlciA9IDBcXFxcbiAgICAgICAgICAgIGJyZWFrO1xcXFxuICAgICAgICBjYXNlIG9yZGVyc1syXTpcXFxcbiAgICAgICAgICAgIG9yZGVyID0gMlxcXFxuICAgICAgICAgICAgYnJlYWs7XFxcXG4gICAgICAgIGNhc2Ugb3JkZXJzWzNdOlxcXFxuICAgICAgICAgICAgb3JkZXIgPSAzXFxcXG4gICAgICAgICAgICBicmVhaztcXFxcbiAgICB9XFxcXG4gICAgdGFncyA9IGdldE15VmFyKGdldE15VmFyKCfliIbnu4QnLCB0YWJzWzBdKSArICfliIbnsbsnLCAnJyArIChpVGFnWzBdLnJlcXVlc3RfcGFyYW1zLnNpemVfdHlwZSB8fCBpVGFnWzBdLmNhdGVnb3J5X25hbWUpICsgJycpXFxcXG4gICAgaWYgKGdldE15VmFyKCfliIbnu4QnLCB0YWJzWzBdKSA9PSB0YWJzWzFdKSB7XFxcXG4gICAgICAgIHN3aXRjaCAodGFncykge1xcXFxuICAgICAgICAgICAgY2FzZSAn5YWo6YOoJzpcXFxcbiAgICAgICAgICAgICAgICBzaWduID0gJ3BhZ2U9JyArIChwYWdlIC0gMSkgKyAnJnBsYXRmb3JtPTAmcHJvZHVjdF9pZD0xNiZzb3J0X3R5c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R5KVxcXFxuICAgIGxheW91dFBhcnNlKGQsIGRhdGEsIHRhYnMpXFxcXG59XFxcXG5cXFxcbmNvbnN0IGxheW91dFBhcnNlID0gKGQsIGRhdGEsIHRhYnMpID0+IHtcXFxcbiAgICBpZiAoZGF0YS5sZW5ndGgpIHtcXFxcbiAgICAgICAgZGF0YS5mb3JFYWNoKGl0ZW0gPT4ge1xcXFxuICAgICAgICAgICAgaXRlbVVybCA9ICdwaWNzOi8vJyArIGl0ZW0ubGFyZ2VVcmxcXFxcbiAgICAgICAgICAgIGlmIChpdGVtLnZpZGVvVXJsKSB7XFxcXG4gICAgICAgICAgICAgICAgaXRlbVVybCA9IGl0ZW0udmlkZW9VcmxcXFxcbiAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgIHR5cGUgPSAncGljXzJfY2FyZCdcXFxcbiAgICAgICAgICAgIGlmIChnZXRNeVZhcign5YiG57uEJywgdGFic1swXSkgPT0gdGFic1syXSkge1xcXFxuICAgICAgICAgICAgICAgIHR5cGUgPSAncGljXzFfY2FyZCdcXFxcbiAgICAgICAgICAgIH1cXFxcbiAgICAgICAgICAgIGQucHVzaCh7XFxcXG4gICAgICAgICAgICAgICAgdGl0bGU6IGl0ZW0uY29udGVudCB8fCBpdGVtLnRpdGxlLFxcXFxuICAgICAgICAgICAgICAgIGRlc2M6IGl0ZW0uZGV0YWlsSW5mbyxcXFxcbiAgICAgICAgICAgICAgICBwaWNfdXJsOiBpdGVtLmxhcmdlVXJsIHx8IGl0ZW0uY292ZXJVcmwsXFxcXG4gICAgICAgICAgICAgICAgdXJsOiBpdGVtVXJsLFxcXFxuICAgICAgICAgICAgICAgIGNvbF90eXBlOiB0eXBlXFxcXG4gICAgICAgICAgICB9KVxcXFxuICAgICAgICB9KVxcXFxuICAgIH0gZWxzZSB7XFxcXG4gICAgICAgIGQucHVzaCh7XFxcXG4gICAgICAgICAgICB0aXRsZTogUmljaChTbWFsbChHcmF5KCfvvZ7vvZ7vvZ7miJHmmK/mnInlupXnur/nmoTvvZ7vvZ7vvZ4nKSkpLFxcXFxuICAgICAgICAgICAgdXJsOiBlbXB0eSxcXFxcbiAgICAgICAgICAgIGNvbF90eXBlOiAndGV4dF9jZW50ZXJfMScsXFxcXG4gICAgICAgICAgICBleHRyYToge1xcXFxuICAgICAgICAgICAgICAgIGxpbmVWaXNpYmxlOiBmYWxzZVxcXFxuICAgICAgICAgICAgfVxcXFxuICAgICAgICB9KVxcXFxuICAgIH1cXFxcbn1cXFwifV1cIiwgXCJwcm94eVwiOiBcIlwiLCBcImljb25cIjogXCJcIn0iLCJzZWFyY2hfdXJsIjoiIiwiZ3JvdXAiOiLikaDmjqjojZAiLCJzZWFyY2hGaW5kIjoiIiwiZGV0YWlsX2NvbF90eXBlIjoibW92aWVfMSIsImRldGFpbF9maW5kX3J1bGUiOiIiLCJzZGV0YWlsX2NvbF90eXBlIjoibW92aWVfMSIsInNkZXRhaWxfZmluZF9ydWxlIjoiIiwidWEiOiJtb2JpbGUiLCJwcmVSdWxlIjoiIiwicGFnZXMiOiJbXSIsImljb24iOiIiLCJwcm94eSI6IiJ9
Add Comment
Please, Sign In to add comment