mirror of
https://github.com/whyour/qinglong.git
synced 2025-05-23 23:06:06 +08:00
修复定时任务脚本跳转
This commit is contained in:
parent
8ad26267d8
commit
633b30269c
|
@ -281,7 +281,9 @@ export function getCommandScript(
|
|||
command: string,
|
||||
): [string, string] | string | undefined {
|
||||
const cmd = command.split(' ') as string[];
|
||||
if (cmd[0] === 'task') {
|
||||
if (cmd[1] === 'repo' || cmd[1] === 'raw') {
|
||||
return cmd[2];
|
||||
}
|
||||
let scriptsPart = cmd.find((x) =>
|
||||
['.js', '.ts', '.sh', '.py'].some((y) => x.endsWith(y)),
|
||||
);
|
||||
|
@ -300,7 +302,4 @@ export function getCommandScript(
|
|||
p = '';
|
||||
}
|
||||
return [s, p];
|
||||
} else if (cmd[1] === 'repo') {
|
||||
return cmd[2];
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user