@vidavidorra/create-project
Version:
Interactively create a GitHub project
249 lines (248 loc) • 6.8 kB
TypeScript
import { z } from 'zod';
import { type Options } from '../options.js';
import { File } from './file.js';
declare const schema: z.ZodObject<{
name: z.ZodLiteral<"CI/CD">;
on: z.ZodObject<{
push: z.ZodObject<{
branches: z.ZodTuple<[z.ZodLiteral<"main">, z.ZodLiteral<"beta">, z.ZodLiteral<"renovate/**">], null>;
}, "strip", z.ZodTypeAny, {
branches: ["main", "beta", "renovate/**"];
}, {
branches: ["main", "beta", "renovate/**"];
}>;
pull_request: z.ZodNull;
}, "strip", z.ZodTypeAny, {
push: {
branches: ["main", "beta", "renovate/**"];
};
pull_request: null;
}, {
push: {
branches: ["main", "beta", "renovate/**"];
};
pull_request: null;
}>;
jobs: z.ZodObject<{
'lint-commit-messages': z.ZodObject<{
uses: z.ZodString;
}, "strip", z.ZodTypeAny, {
uses: string;
}, {
uses: string;
}>;
lint: z.ZodObject<{
uses: z.ZodString;
}, "strip", z.ZodTypeAny, {
uses: string;
}, {
uses: string;
}>;
build: z.ZodObject<{
uses: z.ZodString;
}, "strip", z.ZodTypeAny, {
uses: string;
}, {
uses: string;
}>;
test: z.ZodObject<{
uses: z.ZodString;
}, "strip", z.ZodTypeAny, {
uses: string;
}, {
uses: string;
}>;
'code-coverage': z.ZodObject<{
uses: z.ZodString;
} & {
needs: z.ZodTuple<[z.ZodLiteral<"lint">, z.ZodLiteral<"build">, z.ZodLiteral<"test">], null>;
secrets: z.ZodObject<{
codecovToken: z.ZodString;
}, "strip", z.ZodTypeAny, {
codecovToken: string;
}, {
codecovToken: string;
}>;
}, "strip", z.ZodTypeAny, {
uses: string;
needs: ["lint", "build", "test"];
secrets: {
codecovToken: string;
};
}, {
uses: string;
needs: ["lint", "build", "test"];
secrets: {
codecovToken: string;
};
}>;
release: z.ZodObject<{
uses: z.ZodString;
} & {
needs: z.ZodArray<z.ZodUnion<[z.ZodLiteral<"lint-commit-messages">, z.ZodLiteral<"lint">, z.ZodLiteral<"build">, z.ZodLiteral<"test">, z.ZodLiteral<"code-coverage">]>, "many">;
secrets: z.ZodObject<{
privateKey: z.ZodString;
npmToken: z.ZodString;
}, "strip", z.ZodTypeAny, {
privateKey: string;
npmToken: string;
}, {
privateKey: string;
npmToken: string;
}>;
}, "strip", z.ZodTypeAny, {
uses: string;
needs: ("lint-commit-messages" | "lint" | "build" | "test" | "code-coverage")[];
secrets: {
privateKey: string;
npmToken: string;
};
}, {
uses: string;
needs: ("lint-commit-messages" | "lint" | "build" | "test" | "code-coverage")[];
secrets: {
privateKey: string;
npmToken: string;
};
}>;
}, "strict", z.ZodTypeAny, {
'lint-commit-messages': {
uses: string;
};
lint: {
uses: string;
};
build: {
uses: string;
};
test: {
uses: string;
};
'code-coverage': {
uses: string;
needs: ["lint", "build", "test"];
secrets: {
codecovToken: string;
};
};
release: {
uses: string;
needs: ("lint-commit-messages" | "lint" | "build" | "test" | "code-coverage")[];
secrets: {
privateKey: string;
npmToken: string;
};
};
}, {
'lint-commit-messages': {
uses: string;
};
lint: {
uses: string;
};
build: {
uses: string;
};
test: {
uses: string;
};
'code-coverage': {
uses: string;
needs: ["lint", "build", "test"];
secrets: {
codecovToken: string;
};
};
release: {
uses: string;
needs: ("lint-commit-messages" | "lint" | "build" | "test" | "code-coverage")[];
secrets: {
privateKey: string;
npmToken: string;
};
};
}>;
}, "strict", z.ZodTypeAny, {
name: "CI/CD";
on: {
push: {
branches: ["main", "beta", "renovate/**"];
};
pull_request: null;
};
jobs: {
'lint-commit-messages': {
uses: string;
};
lint: {
uses: string;
};
build: {
uses: string;
};
test: {
uses: string;
};
'code-coverage': {
uses: string;
needs: ["lint", "build", "test"];
secrets: {
codecovToken: string;
};
};
release: {
uses: string;
needs: ("lint-commit-messages" | "lint" | "build" | "test" | "code-coverage")[];
secrets: {
privateKey: string;
npmToken: string;
};
};
};
}, {
name: "CI/CD";
on: {
push: {
branches: ["main", "beta", "renovate/**"];
};
pull_request: null;
};
jobs: {
'lint-commit-messages': {
uses: string;
};
lint: {
uses: string;
};
build: {
uses: string;
};
test: {
uses: string;
};
'code-coverage': {
uses: string;
needs: ["lint", "build", "test"];
secrets: {
codecovToken: string;
};
};
release: {
uses: string;
needs: ("lint-commit-messages" | "lint" | "build" | "test" | "code-coverage")[];
secrets: {
privateKey: string;
npmToken: string;
};
};
};
}>;
type Yaml = z.infer<typeof schema>;
declare class CiCd extends File {
protected readonly _yaml: Yaml;
constructor(path: string, options: Options);
process(): this;
protected get sha(): string;
protected get version(): string;
}
export { CiCd };