Skip to content

Commit 18ac875

Browse files
committed
docs: Update ReadMe instructions
1 parent 6c7b6b5 commit 18ac875

File tree

1 file changed

+10
-7
lines changed
  • src/Template.PowerShell.ScriptModule/TemplateRepoFiles

1 file changed

+10
-7
lines changed

src/Template.PowerShell.ScriptModule/TemplateRepoFiles/ReadMe.md

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ In order to publish the module to the gallery, you need to get an API key.
2929
If you already have an API key that you want to use, you can skip to the next step.
3030

3131
> [!CAUTION]
32-
> It is considered best practice to use a separate API key for each module you publish.
32+
> It is considered best practice to use a different API key for each module you publish.
3333
> It reduces the impact scope if one of the API keys becomes compromised.
3434
3535
If you will be publishing the module to a custom PowerShell Gallery feed, you will need to get an API key for that feed. Otherwise, follow the steps below.
@@ -44,7 +44,9 @@ If you will be publishing the module to a custom PowerShell Gallery feed, you wi
4444
1. Ensure the `Push new packages and package versions` scope is selected.
4545
1. For the `Glob Pattern` enter the name of your module: `__NewModuleName__`
4646
1. Click the `Create` button to create the API key.
47-
1. Click the `Copy` button on the new API key to copy it to your clipboard, as you will need it for the next step.
47+
1. Click the `Copy` button on the new API key to copy it to your clipboard, as you will need it for the next section.
48+
49+
You may want to leave this page open in your browser until you have the API key saved in your repository secrets in the next section.
4850

4951
</details>
5052

@@ -63,19 +65,20 @@ If using GitHub Actions for your CI/CD workflows, perform the following steps to
6365
1. In the left-hand menu, in the `Security` section, click on `Secrets and variables` and select `Actions`.
6466
1. In the `Secrets` tab click the `New repository secret` button.
6567
1. Set the `Name` to: `POWERSHELL_GALLERY_API_KEY`
66-
1. Set the `Secret` to the API key value that you copied in the previous step.
68+
1. Set the `Secret` to the API key value that you copied in the previous section.
6769

6870
Next we want to create an Environment so that stable module versions require manual approval before being published to the gallery:
6971

72+
1. You should still be in the `Settings` section of your repository.
7073
1. In the left-hand menu, in the `Environments` section, click on `Environments`.
7174
1. Click the `New environment` button.
72-
1. Set the `Name` to: `production`
75+
1. Set the `Name` to (all lowercase): `production`
7376
1. Click the `Configure environment` button.
74-
1. Check the `Required reviewers` checkbox and add the appropriate reviewers.
77+
1. Check the `Required reviewers` checkbox and add the usernames of the people allowed to approve new stable version deployments.
7578
1. Click the `Save protection rules` button.
7679

77-
If your account does not meet [the requirements to use `Environments`](https://docs.github.com/en/actions/deployment/targeting-different-environments/using-environments-for-deployment), the `Environments` section will not be available.
78-
You will instead need to use [the Manual Workflow Approval action](https://github.com/marketplace/actions/manual-workflow-approval).
80+
If your GitHub account does not meet [the requirements to use `Environments`](https://docs.github.com/en/actions/deployment/targeting-different-environments/using-environments-for-deployment), the `Environments` section will not be available.
81+
You will instead need to add [the Manual Workflow Approval action](https://github.com/marketplace/actions/manual-workflow-approval) to [the deployment workflow](/.github/workflows/build-test-and-deploy-powershell-module.yml) to block deployments until they are approved.
7982

8083
</details>
8184

0 commit comments

Comments
 (0)