From eb48fe09cd830b912158789ed399953d36082ac2 Mon Sep 17 00:00:00 2001 From: Max Kless Date: Mon, 12 Jun 2023 12:31:47 +0200 Subject: [PATCH] fix(misc): mark name as required for ci-workflow generator --- docs/generated/packages/workspace/generators/ci-workflow.json | 2 +- packages/workspace/src/generators/ci-workflow/ci-workflow.ts | 4 ++-- packages/workspace/src/generators/ci-workflow/schema.json | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/generated/packages/workspace/generators/ci-workflow.json b/docs/generated/packages/workspace/generators/ci-workflow.json index 4bc96bfa6a21a..88e6817f72ab7 100644 --- a/docs/generated/packages/workspace/generators/ci-workflow.json +++ b/docs/generated/packages/workspace/generators/ci-workflow.json @@ -40,7 +40,7 @@ "pattern": "^[a-zA-Z].*$" } }, - "required": ["ci"], + "required": ["ci", "name"], "presets": [] }, "description": "Generate a CI workflow.", diff --git a/packages/workspace/src/generators/ci-workflow/ci-workflow.ts b/packages/workspace/src/generators/ci-workflow/ci-workflow.ts index 6c9ab2b247cf6..64617432a3fdb 100644 --- a/packages/workspace/src/generators/ci-workflow/ci-workflow.ts +++ b/packages/workspace/src/generators/ci-workflow/ci-workflow.ts @@ -12,7 +12,7 @@ import { import { deduceDefaultBase } from '../../utilities/default-base'; export interface Schema { - name?: string; + name: string; ci: 'github' | 'azure' | 'circleci' | 'bitbucket-pipelines' | 'gitlab'; } @@ -47,7 +47,7 @@ interface Substitutes { function normalizeOptions(options: Schema): Substitutes { const { name: workflowName, fileName: workflowFileName } = names( - options.name || 'CI' + options.name ); const { exec: packageManagerPrefix, ciInstall: packageManagerInstall } = getPackageManagerCommand(); diff --git a/packages/workspace/src/generators/ci-workflow/schema.json b/packages/workspace/src/generators/ci-workflow/schema.json index 1778db5c48e8b..f1060142d9f95 100644 --- a/packages/workspace/src/generators/ci-workflow/schema.json +++ b/packages/workspace/src/generators/ci-workflow/schema.json @@ -34,5 +34,5 @@ "pattern": "^[a-zA-Z].*$" } }, - "required": ["ci"] + "required": ["ci", "name"] }