Add typings for js-yaml
This commit is contained in:
parent
29a2159db1
commit
0efcf74ce0
16 changed files with 289 additions and 21 deletions
|
|
@ -191,7 +191,7 @@ interface WorkflowTriggers {
|
|||
pull_request?: WorkflowTrigger | null;
|
||||
}
|
||||
|
||||
interface Workflow {
|
||||
export interface Workflow {
|
||||
jobs?: { [key: string]: WorkflowJob };
|
||||
on?: string | string[] | WorkflowTriggers;
|
||||
}
|
||||
|
|
@ -411,7 +411,7 @@ export async function getWorkflow(): Promise<Workflow> {
|
|||
relativePath
|
||||
);
|
||||
|
||||
return yaml.load(fs.readFileSync(absolutePath, "utf-8"));
|
||||
return yaml.load(fs.readFileSync(absolutePath, "utf-8")) as Workflow;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue