Skip to content

Commit e214088

Browse files
authored
Updates to readme (#238)
1 parent 001a0fc commit e214088

File tree

6 files changed

+86
-77
lines changed

6 files changed

+86
-77
lines changed

.github/workflows/analyze.yaml

-56
This file was deleted.

.github/workflows/build.yaml

+52-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,24 @@
1-
# CI workflow for validating action
1+
#
2+
# Repository build and analysis
3+
#
4+
5+
# NOTES:
6+
# This workflow uses PSRule, and DevSkim.
7+
# You can read more about these linting tools and configuration options here:
8+
# PSRule - https://aka.ms/ps-rule and https://github.com/Microsoft/PSRule.Rules.MSFT.OSS
9+
# DevSkim - https://github.com/microsoft/DevSkim-Action and https://github.com/Microsoft/DevSkim
10+
211
name: Build
312
on:
413
push:
5-
branches: [main, 'release/*']
14+
branches: [main, 'release/*', 'dependencies/*']
615
pull_request:
716
branches: [main, 'release/*']
17+
schedule:
18+
- cron: '42 18 * * 0' # At 6:42 PM, on Sunday each week
19+
workflow_dispatch:
20+
21+
permissions: {}
822

923
jobs:
1024
test:
@@ -72,3 +86,39 @@ jobs:
7286
with:
7387
name: PSRule-results
7488
path: reports/report.md
89+
90+
oss:
91+
name: Analyze with PSRule
92+
runs-on: ubuntu-latest
93+
permissions:
94+
contents: read
95+
steps:
96+
- name: Checkout
97+
uses: actions/checkout@v4
98+
99+
- name: Run PSRule analysis
100+
uses: microsoft/ps-rule@main
101+
with:
102+
modules: PSRule.Rules.MSFT.OSS
103+
prerelease: true
104+
105+
devskim:
106+
name: Analyze with DevSkim
107+
runs-on: ubuntu-latest
108+
permissions:
109+
actions: read
110+
contents: read
111+
security-events: write
112+
steps:
113+
- name: Checkout
114+
uses: actions/checkout@v4
115+
116+
- name: Run DevSkim scanner
117+
uses: microsoft/DevSkim-Action@v1
118+
with:
119+
directory-to-scan: .
120+
121+
- name: Upload results to security tab
122+
uses: github/codeql-action/upload-sarif@v3
123+
with:
124+
sarif_file: devskim-results.sarif

.github/workflows/dependencies.yaml

+2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ on:
1111
- cron: '50 1 * * 1' # At 01:50 AM, on Monday each week
1212
workflow_dispatch:
1313

14+
permissions: {}
15+
1416
env:
1517
WORKING_BRANCH: dependencies/powershell-bump
1618

.github/workflows/release.yaml

+6-5
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,15 @@ on:
2121
options:
2222
- 'v1'
2323
- 'v2'
24-
default: v2
25-
26-
env:
27-
RELEASE_BRANCH: ${{ inputs.major || 'v2' }}
28-
LATEST_BRANCH: v2
24+
- 'v3'
25+
default: v3
2926

3027
permissions: {}
3128

29+
env:
30+
RELEASE_BRANCH: ${{ inputs.major || 'v3' }}
31+
LATEST_BRANCH: v3
32+
3233
jobs:
3334
branch:
3435
name: Update release branch

.github/workflows/stale.yaml

+2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ on:
1212
schedule:
1313
- cron: '30 1 * * *' # At 1:30 AM, daily
1414

15+
permissions: {}
16+
1517
jobs:
1618
stale:
1719
runs-on: ubuntu-latest

README.md

+24-14
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,35 @@ To get a specific release use **(recommended)**:
3131
uses: microsoft/[email protected]
3232
```
3333
34-
To get the latest bits use:
34+
---
35+
36+
> [!TIP]
37+
> The recommended approach is to pin to the latest specific release for example `microsoft/[email protected]`.
38+
> Pinning to a specific release reduces the risk of new releases breaking your pipeline.
39+
>
40+
> You can easily update to the latest release by changing the version number or using version updates with Dependabot.
41+
> To configure version updates of `github-actions` with Dependabot see [Configuring version updates][5].
42+
>
43+
> When the next release is available, bumping the version allows you to test in a feature branch before merging to main.
44+
45+
---
46+
47+
To get the latest bits use **(not recommended for general use or production)**:
3548

3649
```yaml
3750
- name: Run PSRule analysis
3851
uses: microsoft/ps-rule@main
3952
```
4053

54+
---
55+
56+
> [!CAUTION]
57+
> Using `microsoft/ps-rule@main` is **not recommended** for general use or production workflows.
58+
> The `main` branch is under **active development and may be unstable** or include breaking changes.
59+
> Use `microsoft/ps-rule@main` to try latest updates before the next stable release and provide feedback.
60+
61+
---
62+
4163
To use the latest action with an older version of PSRule, you can use the `version` parameter.
4264
For example:
4365

@@ -50,20 +72,8 @@ For example:
5072

5173
For a list of changes please see the [change log][2].
5274

53-
---
54-
55-
The recommended approach is to pin to the latest specific release.
56-
Pinning to a specific release reduces the risk of new releases breaking your pipeline.
57-
You can easily update to the latest release by changing the version number.
58-
At such time, you can test the new release in a feature branch before merging to main.
59-
60-
Using `microsoft/ps-rule@main` is **not recommended** for production workflows.
61-
The `main` branch is under **active development and may be unstable**.
62-
Use `microsoft/ps-rule@main` to try latest updates ahead of a stable release and provide feedback.
63-
64-
---
65-
6675
[2]: CHANGELOG.md
76+
[5]: https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuring-dependabot-version-updates#enabling-dependabot-version-updates
6777

6878
## Inputs
6979

0 commit comments

Comments
 (0)