@xpertss/projen-types 0.0.6 → 0.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/.jsii +62 -174
  2. package/API.md +20 -329
  3. package/README.md +20 -5
  4. package/lib/actions/action-build-workflow.js +4 -2
  5. package/lib/actions/action-dogfood-workflow.js +4 -2
  6. package/lib/actions/action-sonar-workflow.d.ts +6 -6
  7. package/lib/actions/action-sonar-workflow.js +8 -6
  8. package/lib/actions/github-action-project.d.ts +7 -7
  9. package/lib/actions/github-action-project.js +13 -7
  10. package/lib/cdk/app-runtime-scaffold.js +1 -1
  11. package/lib/cdk/cdk-app-project.js +5 -3
  12. package/lib/cdk/cdk-infra-project.js +1 -1
  13. package/lib/cdk/cdk-typescript-base.js +19 -4
  14. package/lib/cdk/components/ecr-ecs-constructs.js +1 -1
  15. package/lib/cdk/components/edge-networking-constructs.js +1 -1
  16. package/lib/cdk/database-component.js +1 -1
  17. package/lib/common/manual-deploy-workflow.js +3 -1
  18. package/lib/common/projen-drift-check-workflow.js +4 -2
  19. package/lib/common/upgrade-workflow.js +3 -1
  20. package/lib/common/workflow-change-notice-workflow.js +4 -2
  21. package/lib/common/workflow-purpose.d.ts +21 -0
  22. package/lib/common/workflow-purpose.js +51 -0
  23. package/lib/index.d.ts +0 -1
  24. package/lib/index.js +1 -2
  25. package/lib/java/components/cdk-deploy-hook.js +1 -1
  26. package/lib/java/components/code-index-workflow.js +5 -3
  27. package/lib/java/components/docker-publish.js +5 -3
  28. package/lib/java/components/flyway-migration.js +1 -1
  29. package/lib/java/components/github-packages-publish.js +5 -3
  30. package/lib/java/components/maven-central-publish.js +5 -3
  31. package/lib/java/java-app-project.js +1 -1
  32. package/lib/java/java-library-project.js +1 -1
  33. package/lib/java/java-maven-base.js +7 -4
  34. package/lib/java/java-service-project.js +1 -1
  35. package/lib/java/options.d.ts +1 -1
  36. package/lib/java/options.js +1 -1
  37. package/package.json +1 -1
  38. package/lib/common/actions-allowlist-guard.d.ts +0 -37
  39. package/lib/common/actions-allowlist-guard.js +0 -70
package/API.md CHANGED
@@ -498,250 +498,12 @@ public readonly workflow: GithubWorkflow;
498
498
  ---
499
499
 
500
500
 
501
- ### ActionsAllowlistGuard <a name="ActionsAllowlistGuard" id="@xpertss/projen-types.ActionsAllowlistGuard"></a>
502
-
503
- #### Initializers <a name="Initializers" id="@xpertss/projen-types.ActionsAllowlistGuard.Initializer"></a>
504
-
505
- ```typescript
506
- import { ActionsAllowlistGuard } from '@xpertss/projen-types'
507
-
508
- new ActionsAllowlistGuard(scope: GitHubProject, options?: ActionsAllowlistGuardOptions)
509
- ```
510
-
511
- | **Name** | **Type** | **Description** |
512
- | --- | --- | --- |
513
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.Initializer.parameter.scope">scope</a></code> | <code>projen.github.GitHubProject</code> | *No description.* |
514
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.Initializer.parameter.options">options</a></code> | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuardOptions">ActionsAllowlistGuardOptions</a></code> | *No description.* |
515
-
516
- ---
517
-
518
- ##### `scope`<sup>Required</sup> <a name="scope" id="@xpertss/projen-types.ActionsAllowlistGuard.Initializer.parameter.scope"></a>
519
-
520
- - *Type:* projen.github.GitHubProject
521
-
522
- ---
523
-
524
- ##### `options`<sup>Optional</sup> <a name="options" id="@xpertss/projen-types.ActionsAllowlistGuard.Initializer.parameter.options"></a>
525
-
526
- - *Type:* <a href="#@xpertss/projen-types.ActionsAllowlistGuardOptions">ActionsAllowlistGuardOptions</a>
527
-
528
- ---
529
-
530
- #### Methods <a name="Methods" id="Methods"></a>
531
-
532
- | **Name** | **Description** |
533
- | --- | --- |
534
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.toString">toString</a></code> | Returns a string representation of this construct. |
535
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.with">with</a></code> | Applies one or more mixins to this construct. |
536
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.postProjectCreation">postProjectCreation</a></code> | Called once, right after `postSynthesize()`, only when the project is created for the first time. |
537
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.postSynthesize">postSynthesize</a></code> | Called after synthesis. |
538
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.preSynthesize">preSynthesize</a></code> | Called before synthesis. |
539
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.projectCreation">projectCreation</a></code> | Called once, right after `synthesize()`, only when the project is created for the first time. |
540
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.synthesize">synthesize</a></code> | Synthesizes files to the project output directory. |
541
-
542
- ---
543
-
544
- ##### `toString` <a name="toString" id="@xpertss/projen-types.ActionsAllowlistGuard.toString"></a>
545
-
546
- ```typescript
547
- public toString(): string
548
- ```
549
-
550
- Returns a string representation of this construct.
551
-
552
- ##### `with` <a name="with" id="@xpertss/projen-types.ActionsAllowlistGuard.with"></a>
553
-
554
- ```typescript
555
- public with(mixins: ...IMixin[]): IConstruct
556
- ```
557
-
558
- Applies one or more mixins to this construct.
559
-
560
- Mixins are applied in order. The list of constructs is captured at the
561
- start of the call, so constructs added by a mixin will not be visited.
562
- Use multiple `with()` calls if subsequent mixins should apply to added
563
- constructs.
564
-
565
- ###### `mixins`<sup>Required</sup> <a name="mixins" id="@xpertss/projen-types.ActionsAllowlistGuard.with.parameter.mixins"></a>
566
-
567
- - *Type:* ...constructs.IMixin[]
568
-
569
- The mixins to apply.
570
-
571
- ---
572
-
573
- ##### `postProjectCreation` <a name="postProjectCreation" id="@xpertss/projen-types.ActionsAllowlistGuard.postProjectCreation"></a>
574
-
575
- ```typescript
576
- public postProjectCreation(initProject: InitProject): void
577
- ```
578
-
579
- Called once, right after `postSynthesize()`, only when the project is created for the first time.
580
-
581
- It does not run on later `projen` invocations. It only fires for `projen new` (or `Projects.createProject`).
582
- It is also skipped when post-synthesis steps are disabled, e.g. `--no-post` or `PROJEN_DISABLE_POST`.
583
- Use it for one-off setup that can be turned off by the user, like running a task to give the user immediate
584
- feedback on their new project. Order across components is not guaranteed.
585
-
586
- ###### `initProject`<sup>Required</sup> <a name="initProject" id="@xpertss/projen-types.ActionsAllowlistGuard.postProjectCreation.parameter.initProject"></a>
587
-
588
- - *Type:* projen.InitProject
589
-
590
- Details about how the project was created, e.g. its type and the original CLI args.
591
-
592
- ---
593
-
594
- ##### `postSynthesize` <a name="postSynthesize" id="@xpertss/projen-types.ActionsAllowlistGuard.postSynthesize"></a>
595
-
596
- ```typescript
597
- public postSynthesize(): void
598
- ```
599
-
600
- Called after synthesis.
601
-
602
- Order is *not* guaranteed.
603
-
604
- ##### `preSynthesize` <a name="preSynthesize" id="@xpertss/projen-types.ActionsAllowlistGuard.preSynthesize"></a>
605
-
606
- ```typescript
607
- public preSynthesize(): void
608
- ```
609
-
610
- Called before synthesis.
611
-
612
- ##### `projectCreation` <a name="projectCreation" id="@xpertss/projen-types.ActionsAllowlistGuard.projectCreation"></a>
613
-
614
- ```typescript
615
- public projectCreation(initProject: InitProject): void
616
- ```
617
-
618
- Called once, right after `synthesize()`, only when the project is created for the first time.
619
-
620
- It does not run on later `projen` invocations. It only fires for `projen new` (or `Projects.createProject`).
621
- Use it for deterministic, one-off file generation. Order across components is not guaranteed.
622
-
623
- ###### `initProject`<sup>Required</sup> <a name="initProject" id="@xpertss/projen-types.ActionsAllowlistGuard.projectCreation.parameter.initProject"></a>
624
-
625
- - *Type:* projen.InitProject
626
-
627
- Details about how the project was created, e.g. its type and the original CLI args.
628
-
629
- ---
630
-
631
- ##### `synthesize` <a name="synthesize" id="@xpertss/projen-types.ActionsAllowlistGuard.synthesize"></a>
632
-
633
- ```typescript
634
- public synthesize(): void
635
- ```
636
-
637
- Synthesizes files to the project output directory.
638
-
639
- #### Static Functions <a name="Static Functions" id="Static Functions"></a>
640
-
641
- | **Name** | **Description** |
642
- | --- | --- |
643
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.isConstruct">isConstruct</a></code> | Checks if `x` is a construct. |
644
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.isComponent">isComponent</a></code> | Test whether the given construct is a component. |
645
-
646
- ---
647
-
648
- ##### `isConstruct` <a name="isConstruct" id="@xpertss/projen-types.ActionsAllowlistGuard.isConstruct"></a>
649
-
650
- ```typescript
651
- import { ActionsAllowlistGuard } from '@xpertss/projen-types'
652
-
653
- ActionsAllowlistGuard.isConstruct(x: any)
654
- ```
655
-
656
- Checks if `x` is a construct.
657
-
658
- Use this method instead of `instanceof` to properly detect `Construct`
659
- instances, even when the construct library is symlinked.
660
-
661
- Explanation: in JavaScript, multiple copies of the `constructs` library on
662
- disk are seen as independent, completely different libraries. As a
663
- consequence, the class `Construct` in each copy of the `constructs` library
664
- is seen as a different class, and an instance of one class will not test as
665
- `instanceof` the other class. `npm install` will not create installations
666
- like this, but users may manually symlink construct libraries together or
667
- use a monorepo tool: in those cases, multiple copies of the `constructs`
668
- library can be accidentally installed, and `instanceof` will behave
669
- unpredictably. It is safest to avoid using `instanceof`, and using
670
- this type-testing method instead.
671
-
672
- ###### `x`<sup>Required</sup> <a name="x" id="@xpertss/projen-types.ActionsAllowlistGuard.isConstruct.parameter.x"></a>
673
-
674
- - *Type:* any
675
-
676
- Any object.
677
-
678
- ---
679
-
680
- ##### `isComponent` <a name="isComponent" id="@xpertss/projen-types.ActionsAllowlistGuard.isComponent"></a>
681
-
682
- ```typescript
683
- import { ActionsAllowlistGuard } from '@xpertss/projen-types'
684
-
685
- ActionsAllowlistGuard.isComponent(x: any)
686
- ```
687
-
688
- Test whether the given construct is a component.
689
-
690
- ###### `x`<sup>Required</sup> <a name="x" id="@xpertss/projen-types.ActionsAllowlistGuard.isComponent.parameter.x"></a>
691
-
692
- - *Type:* any
693
-
694
- ---
695
-
696
- #### Properties <a name="Properties" id="Properties"></a>
697
-
698
- | **Name** | **Type** | **Description** |
699
- | --- | --- | --- |
700
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.property.node">node</a></code> | <code>constructs.Node</code> | The tree node. |
701
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.property.project">project</a></code> | <code>projen.Project</code> | *No description.* |
702
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuard.property.workflow">workflow</a></code> | <code>projen.github.GithubWorkflow</code> | *No description.* |
703
-
704
- ---
705
-
706
- ##### `node`<sup>Required</sup> <a name="node" id="@xpertss/projen-types.ActionsAllowlistGuard.property.node"></a>
707
-
708
- ```typescript
709
- public readonly node: Node;
710
- ```
711
-
712
- - *Type:* constructs.Node
713
-
714
- The tree node.
715
-
716
- ---
717
-
718
- ##### `project`<sup>Required</sup> <a name="project" id="@xpertss/projen-types.ActionsAllowlistGuard.property.project"></a>
719
-
720
- ```typescript
721
- public readonly project: Project;
722
- ```
723
-
724
- - *Type:* projen.Project
725
-
726
- ---
727
-
728
- ##### `workflow`<sup>Required</sup> <a name="workflow" id="@xpertss/projen-types.ActionsAllowlistGuard.property.workflow"></a>
729
-
730
- ```typescript
731
- public readonly workflow: GithubWorkflow;
732
- ```
733
-
734
- - *Type:* projen.github.GithubWorkflow
735
-
736
- ---
737
-
738
-
739
501
  ### ActionSonarWorkflow <a name="ActionSonarWorkflow" id="@xpertss/projen-types.ActionSonarWorkflow"></a>
740
502
 
741
- AD-001 Layer 2: self-hosted SonarQube Community Edition via the Scanner CLI only (never `SonarSource/sonarqube-scan-action` - third-party, and it carried a security advisory).
503
+ AD-001 Layer 2: SonarCloud via the Scanner CLI only (never `SonarSource/sonarqube-scan-action` - third-party, and it carried a security advisory).
742
504
 
743
- `sonar.inclusions` is set explicitly since
744
- default inclusions may skip `action.yml` outside `.github/`.
505
+ `sonar.inclusions` is set explicitly since default
506
+ inclusions may skip `action.yml` outside `.github/`.
745
507
 
746
508
  #### Initializers <a name="Initializers" id="@xpertss/projen-types.ActionSonarWorkflow.Initializer"></a>
747
509
 
@@ -7192,7 +6954,7 @@ public readonly project: Project;
7192
6954
 
7193
6955
  ### GitHubActionProject <a name="GitHubActionProject" id="@xpertss/projen-types.GitHubActionProject"></a>
7194
6956
 
7195
- Scaffolds the repo lifecycle (AD-001) around a hand-committed, composite (shell) GitHub Action: the `build`/`test-dogfood`/`sonar`/`release` workflows, versioning and release discipline, the F003 verify components, the F009 allowlist guard, and repo boilerplate (a private version-source `package.json`, `.yamllint`, `LICENSE`, and a `README.md` template). The action's own content (`action.yml`, its shell scripts, `test/` fixtures) is authored by hand per the action's own F### spec - this type only lints it.
6957
+ Scaffolds the repo lifecycle (AD-001) around a hand-committed, composite (shell) GitHub Action: the `build`/`test-dogfood`/`sonar`/`release` workflows, versioning and release discipline, the F003 verify components, and repo boilerplate (a private version-source `package.json`, `.yamllint`, `LICENSE`, and a `README.md` template). The action's own content (`action.yml`, its shell scripts, `test/` fixtures) is authored by hand per the action's own F### spec - this type only lints it.
7196
6958
 
7197
6959
  #### Initializers <a name="Initializers" id="@xpertss/projen-types.GitHubActionProject.Initializer"></a>
7198
6960
 
@@ -12970,70 +12732,6 @@ public readonly inputs: {[ key: string ]: string};
12970
12732
 
12971
12733
  ---
12972
12734
 
12973
- ### ActionsAllowlistGuardOptions <a name="ActionsAllowlistGuardOptions" id="@xpertss/projen-types.ActionsAllowlistGuardOptions"></a>
12974
-
12975
- Blocking, tamper-proof PR check that stops a disallowed GitHub Action reference from ever (re)appearing in a repo's workflow or composite-action files.
12976
-
12977
- Runs on `pull_request_target` so it always executes the copy of this
12978
- workflow committed on the base branch - a PR cannot edit this file to
12979
- disable or weaken the check. It checks out and executes nothing from the
12980
- PR; it only reads the PR head's file content via the GitHub API. Because
12981
- `pull_request_target` runs with the base repo's token even for
12982
- fork-originated PRs, the failure comment posts reliably.
12983
-
12984
- It performs a flat, unconditional scan of the PR's head ref (no
12985
- base-vs-head comparison): fetch the content of every GitHub workflow and
12986
- composite-action file, extract every `uses:` value, and fail if any does
12987
- not start with one of the three trusted namespaces from AD-001
12988
- (`actions/`, `docker/`, `xpertss/`). The single
12989
- exemption is a local same-repo reference (`uses: .` or
12990
- `uses: ./.github/actions/<name>`) - the repo's own hand-committed action,
12991
- to which the org policy's "allow select actions" setting does not apply.
12992
-
12993
- #### Initializer <a name="Initializer" id="@xpertss/projen-types.ActionsAllowlistGuardOptions.Initializer"></a>
12994
-
12995
- ```typescript
12996
- import { ActionsAllowlistGuardOptions } from '@xpertss/projen-types'
12997
-
12998
- const actionsAllowlistGuardOptions: ActionsAllowlistGuardOptions = { ... }
12999
- ```
13000
-
13001
- #### Properties <a name="Properties" id="Properties"></a>
13002
-
13003
- | **Name** | **Type** | **Description** |
13004
- | --- | --- | --- |
13005
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuardOptions.property.gheTokenSecret">gheTokenSecret</a></code> | <code>string</code> | GitHub secret holding a token with permission to comment on PRs, used for the failure comment. |
13006
- | <code><a href="#@xpertss/projen-types.ActionsAllowlistGuardOptions.property.workflowName">workflowName</a></code> | <code>string</code> | *No description.* |
13007
-
13008
- ---
13009
-
13010
- ##### `gheTokenSecret`<sup>Optional</sup> <a name="gheTokenSecret" id="@xpertss/projen-types.ActionsAllowlistGuardOptions.property.gheTokenSecret"></a>
13011
-
13012
- ```typescript
13013
- public readonly gheTokenSecret: string;
13014
- ```
13015
-
13016
- - *Type:* string
13017
- - *Default:* "PROJEN_GITHUB_TOKEN"
13018
-
13019
- GitHub secret holding a token with permission to comment on PRs, used for the failure comment.
13020
-
13021
- The check still fails without it, so fork PRs -
13022
- which get no secrets - are only missing the extra comment.
13023
-
13024
- ---
13025
-
13026
- ##### `workflowName`<sup>Optional</sup> <a name="workflowName" id="@xpertss/projen-types.ActionsAllowlistGuardOptions.property.workflowName"></a>
13027
-
13028
- ```typescript
13029
- public readonly workflowName: string;
13030
- ```
13031
-
13032
- - *Type:* string
13033
- - *Default:* "actions-allowlist-guard"
13034
-
13035
- ---
13036
-
13037
12735
  ### ActionSonarWorkflowOptions <a name="ActionSonarWorkflowOptions" id="@xpertss/projen-types.ActionSonarWorkflowOptions"></a>
13038
12736
 
13039
12737
  #### Initializer <a name="Initializer" id="@xpertss/projen-types.ActionSonarWorkflowOptions.Initializer"></a>
@@ -13048,7 +12746,7 @@ const actionSonarWorkflowOptions: ActionSonarWorkflowOptions = { ... }
13048
12746
 
13049
12747
  | **Name** | **Type** | **Description** |
13050
12748
  | --- | --- | --- |
13051
- | <code><a href="#@xpertss/projen-types.ActionSonarWorkflowOptions.property.sonarHostUrl">sonarHostUrl</a></code> | <code>string</code> | URL of the org's self-hosted SonarQube instance. |
12749
+ | <code><a href="#@xpertss/projen-types.ActionSonarWorkflowOptions.property.sonarHostUrl">sonarHostUrl</a></code> | <code>string</code> | URL of the org's SonarCloud instance (e.g. `https://sonarcloud.io`). Required, no default - a guessed server is worse than a loud failure. |
13052
12750
  | <code><a href="#@xpertss/projen-types.ActionSonarWorkflowOptions.property.sonarPullRequestGate">sonarPullRequestGate</a></code> | <code>boolean</code> | Whether `sonar.yml` also runs on `pull_request` as a pass/fail gate. |
13053
12751
  | <code><a href="#@xpertss/projen-types.ActionSonarWorkflowOptions.property.sonarTokenSecret">sonarTokenSecret</a></code> | <code>string</code> | *No description.* |
13054
12752
 
@@ -13062,10 +12760,7 @@ public readonly sonarHostUrl: string;
13062
12760
 
13063
12761
  - *Type:* string
13064
12762
 
13065
- URL of the org's self-hosted SonarQube instance.
13066
-
13067
- Required, no default -
13068
- a guessed server is worse than a loud failure.
12763
+ URL of the org's SonarCloud instance (e.g. `https://sonarcloud.io`). Required, no default - a guessed server is worse than a loud failure.
13069
12764
 
13070
12765
  ---
13071
12766
 
@@ -13468,7 +13163,7 @@ const commonJavaOptions: CommonJavaOptions = { ... }
13468
13163
  | <code><a href="#@xpertss/projen-types.CommonJavaOptions.property.groupId">groupId</a></code> | <code>string</code> | *No description.* |
13469
13164
  | <code><a href="#@xpertss/projen-types.CommonJavaOptions.property.name">name</a></code> | <code>string</code> | *No description.* |
13470
13165
  | <code><a href="#@xpertss/projen-types.CommonJavaOptions.property.gheTokenSecret">gheTokenSecret</a></code> | <code>string</code> | *No description.* |
13471
- | <code><a href="#@xpertss/projen-types.CommonJavaOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarQube project key. |
13166
+ | <code><a href="#@xpertss/projen-types.CommonJavaOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarCloud project key. |
13472
13167
  | <code><a href="#@xpertss/projen-types.CommonJavaOptions.property.version">version</a></code> | <code>string</code> | *No description.* |
13473
13168
 
13474
13169
  ---
@@ -13522,7 +13217,7 @@ public readonly sonarProjectKey: string;
13522
13217
 
13523
13218
  - *Type:* string
13524
13219
 
13525
- SonarQube project key.
13220
+ SonarCloud project key.
13526
13221
 
13527
13222
  If unset, the sonar scan step is skipped.
13528
13223
 
@@ -13765,10 +13460,10 @@ const gitHubActionProjectOptions: GitHubActionProjectOptions = { ... }
13765
13460
  | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.stale">stale</a></code> | <code>boolean</code> | Auto-close of stale issues and pull request. |
13766
13461
  | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.staleOptions">staleOptions</a></code> | <code>projen.github.StaleOptions</code> | Auto-close stale issues and pull requests. |
13767
13462
  | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.vscode">vscode</a></code> | <code>boolean</code> | Enable VSCode integration. |
13768
- | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.sonarHostUrl">sonarHostUrl</a></code> | <code>string</code> | URL of the org's self-hosted SonarQube instance. |
13463
+ | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.sonarHostUrl">sonarHostUrl</a></code> | <code>string</code> | URL of the org's SonarCloud instance (e.g. `https://sonarcloud.io`). MUST be reachable from github.com-hosted (public) runners (AD-001). Required, no default: a guessed server is worse than a loud failure. |
13769
13464
  | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.description">description</a></code> | <code>string</code> | One-line description of the action. |
13770
13465
  | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.dogfood">dogfood</a></code> | <code><a href="#@xpertss/projen-types.ActionDogfoodOptions">ActionDogfoodOptions</a></code> | The dogfood scenario (AD-001). |
13771
- | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.gheTokenSecret">gheTokenSecret</a></code> | <code>string</code> | Name of the GitHub Actions secret holding the PAT used for projen-automation PR comments (F003/F009) and, when the action has a `token` input, the dogfood's invocation of it. |
13466
+ | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.gheTokenSecret">gheTokenSecret</a></code> | <code>string</code> | Name of the GitHub Actions secret holding the PAT used for projen-automation PR comments (F003) and, when the action has a `token` input, the dogfood's invocation of it. |
13772
13467
  | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.license">license</a></code> | <code>string</code> | SPDX identifier for the generated `LICENSE`. |
13773
13468
  | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.sonarPullRequestGate">sonarPullRequestGate</a></code> | <code>boolean</code> | Whether `sonar.yml` also runs on `pull_request` as a pass/fail gate. |
13774
13469
  | <code><a href="#@xpertss/projen-types.GitHubActionProjectOptions.property.sonarTokenSecret">sonarTokenSecret</a></code> | <code>string</code> | *No description.* |
@@ -14151,11 +13846,7 @@ public readonly sonarHostUrl: string;
14151
13846
 
14152
13847
  - *Type:* string
14153
13848
 
14154
- URL of the org's self-hosted SonarQube instance.
14155
-
14156
- MUST be reachable from
14157
- github.com-hosted (public) runners (AD-001). Required, no default: a
14158
- guessed server is worse than a loud failure.
13849
+ URL of the org's SonarCloud instance (e.g. `https://sonarcloud.io`). MUST be reachable from github.com-hosted (public) runners (AD-001). Required, no default: a guessed server is worse than a loud failure.
14159
13850
 
14160
13851
  ---
14161
13852
 
@@ -14207,7 +13898,7 @@ public readonly gheTokenSecret: string;
14207
13898
  - *Type:* string
14208
13899
  - *Default:* "PROJEN_GITHUB_TOKEN"
14209
13900
 
14210
- Name of the GitHub Actions secret holding the PAT used for projen-automation PR comments (F003/F009) and, when the action has a `token` input, the dogfood's invocation of it.
13901
+ Name of the GitHub Actions secret holding the PAT used for projen-automation PR comments (F003) and, when the action has a `token` input, the dogfood's invocation of it.
14211
13902
 
14212
13903
  ---
14213
13904
 
@@ -14295,7 +13986,7 @@ const javaAppProjectOptions: JavaAppProjectOptions = { ... }
14295
13986
  | <code><a href="#@xpertss/projen-types.JavaAppProjectOptions.property.groupId">groupId</a></code> | <code>string</code> | *No description.* |
14296
13987
  | <code><a href="#@xpertss/projen-types.JavaAppProjectOptions.property.name">name</a></code> | <code>string</code> | *No description.* |
14297
13988
  | <code><a href="#@xpertss/projen-types.JavaAppProjectOptions.property.gheTokenSecret">gheTokenSecret</a></code> | <code>string</code> | *No description.* |
14298
- | <code><a href="#@xpertss/projen-types.JavaAppProjectOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarQube project key. |
13989
+ | <code><a href="#@xpertss/projen-types.JavaAppProjectOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarCloud project key. |
14299
13990
  | <code><a href="#@xpertss/projen-types.JavaAppProjectOptions.property.version">version</a></code> | <code>string</code> | *No description.* |
14300
13991
  | <code><a href="#@xpertss/projen-types.JavaAppProjectOptions.property.ghPackagesRegistry">ghPackagesRegistry</a></code> | <code>string</code> | *No description.* |
14301
13992
 
@@ -14350,7 +14041,7 @@ public readonly sonarProjectKey: string;
14350
14041
 
14351
14042
  - *Type:* string
14352
14043
 
14353
- SonarQube project key.
14044
+ SonarCloud project key.
14354
14045
 
14355
14046
  If unset, the sonar scan step is skipped.
14356
14047
 
@@ -14396,7 +14087,7 @@ const javaLibraryProjectOptions: JavaLibraryProjectOptions = { ... }
14396
14087
  | <code><a href="#@xpertss/projen-types.JavaLibraryProjectOptions.property.groupId">groupId</a></code> | <code>string</code> | *No description.* |
14397
14088
  | <code><a href="#@xpertss/projen-types.JavaLibraryProjectOptions.property.name">name</a></code> | <code>string</code> | *No description.* |
14398
14089
  | <code><a href="#@xpertss/projen-types.JavaLibraryProjectOptions.property.gheTokenSecret">gheTokenSecret</a></code> | <code>string</code> | *No description.* |
14399
- | <code><a href="#@xpertss/projen-types.JavaLibraryProjectOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarQube project key. |
14090
+ | <code><a href="#@xpertss/projen-types.JavaLibraryProjectOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarCloud project key. |
14400
14091
  | <code><a href="#@xpertss/projen-types.JavaLibraryProjectOptions.property.version">version</a></code> | <code>string</code> | *No description.* |
14401
14092
  | <code><a href="#@xpertss/projen-types.JavaLibraryProjectOptions.property.mavenCentralOidc">mavenCentralOidc</a></code> | <code>boolean</code> | Use Maven Central's OIDC trusted-publishing flow instead of secret-based GPG signing. |
14402
14093
  | <code><a href="#@xpertss/projen-types.JavaLibraryProjectOptions.property.publishCodeIndex">publishCodeIndex</a></code> | <code>boolean</code> | *No description.* |
@@ -14452,7 +14143,7 @@ public readonly sonarProjectKey: string;
14452
14143
 
14453
14144
  - *Type:* string
14454
14145
 
14455
- SonarQube project key.
14146
+ SonarCloud project key.
14456
14147
 
14457
14148
  If unset, the sonar scan step is skipped.
14458
14149
 
@@ -14510,7 +14201,7 @@ const javaMavenProjectOptions: JavaMavenProjectOptions = { ... }
14510
14201
  | <code><a href="#@xpertss/projen-types.JavaMavenProjectOptions.property.groupId">groupId</a></code> | <code>string</code> | *No description.* |
14511
14202
  | <code><a href="#@xpertss/projen-types.JavaMavenProjectOptions.property.name">name</a></code> | <code>string</code> | *No description.* |
14512
14203
  | <code><a href="#@xpertss/projen-types.JavaMavenProjectOptions.property.gheTokenSecret">gheTokenSecret</a></code> | <code>string</code> | *No description.* |
14513
- | <code><a href="#@xpertss/projen-types.JavaMavenProjectOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarQube project key. |
14204
+ | <code><a href="#@xpertss/projen-types.JavaMavenProjectOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarCloud project key. |
14514
14205
  | <code><a href="#@xpertss/projen-types.JavaMavenProjectOptions.property.version">version</a></code> | <code>string</code> | *No description.* |
14515
14206
 
14516
14207
  ---
@@ -14564,7 +14255,7 @@ public readonly sonarProjectKey: string;
14564
14255
 
14565
14256
  - *Type:* string
14566
14257
 
14567
- SonarQube project key.
14258
+ SonarCloud project key.
14568
14259
 
14569
14260
  If unset, the sonar scan step is skipped.
14570
14261
 
@@ -14599,7 +14290,7 @@ const javaServiceProjectOptions: JavaServiceProjectOptions = { ... }
14599
14290
  | <code><a href="#@xpertss/projen-types.JavaServiceProjectOptions.property.groupId">groupId</a></code> | <code>string</code> | *No description.* |
14600
14291
  | <code><a href="#@xpertss/projen-types.JavaServiceProjectOptions.property.name">name</a></code> | <code>string</code> | *No description.* |
14601
14292
  | <code><a href="#@xpertss/projen-types.JavaServiceProjectOptions.property.gheTokenSecret">gheTokenSecret</a></code> | <code>string</code> | *No description.* |
14602
- | <code><a href="#@xpertss/projen-types.JavaServiceProjectOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarQube project key. |
14293
+ | <code><a href="#@xpertss/projen-types.JavaServiceProjectOptions.property.sonarProjectKey">sonarProjectKey</a></code> | <code>string</code> | SonarCloud project key. |
14603
14294
  | <code><a href="#@xpertss/projen-types.JavaServiceProjectOptions.property.version">version</a></code> | <code>string</code> | *No description.* |
14604
14295
  | <code><a href="#@xpertss/projen-types.JavaServiceProjectOptions.property.cdkDeployHook">cdkDeployHook</a></code> | <code>boolean</code> | Whether to generate the `deploy-cdk` workflow at all. |
14605
14296
  | <code><a href="#@xpertss/projen-types.JavaServiceProjectOptions.property.cdkDeployTargetRepo">cdkDeployTargetRepo</a></code> | <code>string</code> | The companion CDK infra/app repo (`owner/repo`) whose `deploy.yml` the `deploy-cdk` workflow dispatches. |
@@ -14658,7 +14349,7 @@ public readonly sonarProjectKey: string;
14658
14349
 
14659
14350
  - *Type:* string
14660
14351
 
14661
- SonarQube project key.
14352
+ SonarCloud project key.
14662
14353
 
14663
14354
  If unset, the sonar scan step is skipped.
14664
14355
 
package/README.md CHANGED
@@ -61,6 +61,21 @@ is allowed to be missing loudly, never silently.
61
61
 
62
62
  The `name` option must match the `name` field in the project's `package.json` (for the CDK types) or the project name used by projen's `java.JavaProject` (for the Java types).
63
63
 
64
+ ## Updating an existing project when this package changes
65
+
66
+ Your generated scaffold reflects the *installed* version of `@xpertss/projen-types` - `npx projen` reads your project type from the package in `node_modules`, not from this repository. So when this package ships a change (a bug fix, a new generated file, or altered workflow behavior), an existing project picks it up by bumping the dependency and re-synthesizing. A stale `node_modules` silently regenerates with the old behavior, so the bump is the load-bearing step.
67
+
68
+ Using the [`auto-commit` action](#githubactionproject) as a running example, say a new release adds the `# Purpose:` workflow header and SonarCloud wording. In the `auto-commit` repo:
69
+
70
+ ```bash
71
+ npm view @xpertss/projen-types version # what's the newest release?
72
+ npm i -D @xpertss/projen-types@latest # bump the installed project type
73
+ npx projen # re-synthesize every generated file
74
+ git diff # review before committing
75
+ ```
76
+
77
+ The diff here is the workflows gaining a `# Purpose:` comment and `sonar.yml` reflecting the SonarCloud wording. Commit the result with a normal `chore:` or `fix:` message - you never hand-edit the generated files themselves.
78
+
64
79
  ## Examples
65
80
 
66
81
  ### CdkInfraProject
@@ -206,7 +221,7 @@ import { GitHubActionProject } from '@xpertss/projen-types';
206
221
  const project = new GitHubActionProject({
207
222
  name: 'auto-commit',
208
223
  description: 'Stage a folder and, only if it changed, commit and push it',
209
- sonarHostUrl: 'https://sonar.xpertss.org', // required, no default - your self-hosted SonarQube
224
+ sonarHostUrl: 'https://sonarcloud.io', // required, no default - your SonarCloud URL
210
225
  dogfood: {
211
226
  // Two scenario steps: the "changed" path and the "no-op" path are both
212
227
  // load-bearing behavior for this action (a double-commit or a
@@ -254,9 +269,9 @@ You get:
254
269
  - `action.yml` and `auto-commit.sh` are hand-written - this type only lints their content via `build.yml`'s shellcheck/yamllint/actionlint checks.
255
270
  - `.github/workflows/build.yml` - lint gate: `apt`-installed shellcheck/yamllint plus a pinned, SHA-256-verified `actionlint` release binary. Gates `main` alongside `sonar.yml`.
256
271
  - `.github/workflows/test-dogfood.yml` - runs the `dogfood.scenario` steps above against this repo's own `action.yml` (via `uses: .`), then the shared `cleanup`, on `workflow_dispatch`, every `pull_request`, and nightly. Omit `dogfood` and the workflow still exists, with one step that fails on every PR until you declare a scenario - AD-001 allows a dogfood to be missing loudly, never silently. A *partial* `dogfood` (a scenario with no cleanup) is a synth error.
257
- - `.github/workflows/sonar.yml` - self-hosted SonarQube via the Scanner CLI, scanning `action.yml`/`.github/workflows/**`/`**/*.sh` explicitly.
272
+ - `.github/workflows/sonar.yml` - SonarCloud scan via the Scanner CLI (the quality gate blocks the PR), scanning `action.yml`/`.github/workflows/**`/`**/*.sh` explicitly.
258
273
  - `.github/workflows/release.yml` - `feat:`/`fix:` commits on `main` bump the version, tag `vX.Y.Z`, and create a GitHub Release.
259
- - `.github/workflows/projen-drift-check.yml`, `workflow-change-notice.yml`, `actions-allowlist-guard.yml` - drift detection, a change notice, and an action allow-list guard, always included.
274
+ - `.github/workflows/projen-drift-check.yml` and `workflow-change-notice.yml` - drift detection and a change notice, always included.
260
275
  - `package.json` (**private**, version source only), `.yamllint`, `LICENSE` (MIT by default), and a `README.md` template - all regenerated by `npx projen`.
261
276
 
262
277
  Needs the same two secrets as everything else in this package: `PROJEN_GITHUB_TOKEN` (used for automated PR comments) and `SONAR_TOKEN` (the Sonar scan). Onboard a brand-new action repo following [Getting started](#getting-started), write the `.projenrc.ts` above, then hand-write `action.yml`/`auto-commit.sh`/`test/fixtures/`.
@@ -311,7 +326,7 @@ Plain strings (`'dev'`) are shorthand for `{ name: 'dev' }`.
311
326
  | --- | --- | --- |
312
327
  | `name` | - (required) | Project name |
313
328
  | `description` | - | One-line description; used in the default README template and recorded in the private `package.json` |
314
- | `sonarHostUrl` | - (required) | URL of your self-hosted SonarQube instance; must be reachable from github.com-hosted runners |
329
+ | `sonarHostUrl` | - (required) | URL of your SonarCloud instance (e.g. `https://sonarcloud.io`); must be reachable from github.com-hosted runners |
315
330
  | `sonarTokenSecret` | `SONAR_TOKEN` | GitHub secret holding the Sonar token |
316
331
  | `sonarPullRequestGate` | `true` | Whether `sonar.yml` also runs on `pull_request` as a pass/fail gate |
317
332
  | `dogfood` | - (a `test-dogfood.yml` that fails until you declare one) | `ActionDogfoodOptions` - the scenario that exercises the action end-to-end via `uses: .` |
@@ -365,7 +380,7 @@ The project types are composed from smaller components you can also attach to yo
365
380
  | `CodeIndexWorkflow` | `JavaProject` | Code index generation on push to `main` |
366
381
  | `ActionBuildWorkflow` | `GitHubProject` | The `lint` task (shellcheck/yamllint/pinned actionlint) + `build.yml` |
367
382
  | `ActionDogfoodWorkflow` | `GitHubProject` | `test-dogfood.yml` from an `ActionDogfoodOptions` scenario |
368
- | `ActionSonarWorkflow` | `GitHubProject` | `sonar.yml` (self-hosted SonarQube via the Scanner CLI) |
383
+ | `ActionSonarWorkflow` | `GitHubProject` | `sonar.yml` (SonarCloud scan via the Scanner CLI) |
369
384
 
370
385
  Example - adding a Docker publish to a plain projen `JavaProject`:
371
386
 
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ActionBuildWorkflow = void 0;
4
4
  const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti");
5
5
  const projen_1 = require("projen");
6
+ const workflow_purpose_1 = require("../common/workflow-purpose");
6
7
  // Pinned release + verified SHA-256 (linux_amd64) - upgrade is a reviewed
7
8
  // diff of this constant, never a floating version (AD-001).
8
9
  const ACTIONLINT_VERSION = '1.7.12';
@@ -19,7 +20,7 @@ const ACTIONLINT_SHA256 = '8aca8db96f1b94770f1b0d72b6dddcb1ebb8123cb3712530b08cc
19
20
  * the release build job, so the lint commands exist in exactly one place.
20
21
  */
21
22
  class ActionBuildWorkflow extends projen_1.Component {
22
- static [JSII_RTTI_SYMBOL_1] = { fqn: "@xpertss/projen-types.ActionBuildWorkflow", version: "0.0.6" };
23
+ static [JSII_RTTI_SYMBOL_1] = { fqn: "@xpertss/projen-types.ActionBuildWorkflow", version: "0.0.8" };
23
24
  task;
24
25
  workflow;
25
26
  constructor(scope) {
@@ -46,7 +47,8 @@ class ActionBuildWorkflow extends projen_1.Component {
46
47
  permissions: { contents: projen_1.github.workflows.JobPermission.READ },
47
48
  preBuildSteps: [{ name: 'Install dependencies', run: 'npm ci' }],
48
49
  });
50
+ (0, workflow_purpose_1.noteWorkflowPurpose)(this.workflow.file, 'Lint gate for the action (shellcheck, yamllint, actionlint).');
49
51
  }
50
52
  }
51
53
  exports.ActionBuildWorkflow = ActionBuildWorkflow;
52
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWN0aW9uLWJ1aWxkLXdvcmtmbG93LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL2FjdGlvbnMvYWN0aW9uLWJ1aWxkLXdvcmtmbG93LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7QUFBQSxtQ0FBaUQ7QUFFakQsMEVBQTBFO0FBQzFFLDREQUE0RDtBQUM1RCxNQUFNLGtCQUFrQixHQUFHLFFBQVEsQ0FBQztBQUNwQyxNQUFNLGlCQUFpQixHQUNyQixrRUFBa0UsQ0FBQztBQUVyRTs7Ozs7Ozs7OztHQVVHO0FBQ0gsTUFBYSxtQkFBb0IsU0FBUSxrQkFBUzs7SUFDaEMsSUFBSSxDQUFPO0lBQ1gsUUFBUSxDQUFzQjtJQUU5QyxZQUFZLEtBQTJCO1FBQ3JDLEtBQUssQ0FBQyxLQUFLLEVBQUUscUJBQXFCLENBQUMsQ0FBQztRQUVwQyxNQUFNLEVBQUUsR0FBRyxLQUFLLENBQUMsTUFBTSxDQUFDO1FBQ3hCLElBQUksQ0FBQyxFQUFFLEVBQUUsQ0FBQztZQUNSLE1B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