Conversation
Co-authored-by: MrSimonC <3033044+MrSimonC@users.noreply.github.com>
Co-authored-by: MrSimonC <3033044+MrSimonC@users.noreply.github.com>
Co-authored-by: MrSimonC <3033044+MrSimonC@users.noreply.github.com>
Co-authored-by: MrSimonC <3033044+MrSimonC@users.noreply.github.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a992d16e7c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| name: FolderSnippets-Windows | ||
| path: ./publish/FolderSnippets.exe | ||
| retention-days: 1 | ||
| overwrite: true |
There was a problem hiding this comment.
Enforce single artifact across workflow runs
The retention-days: 1 and overwrite: true settings here only affect each artifact’s lifetime and (at most) duplicate uploads within the same workflow run; they do not delete artifacts from previous runs. That means if two pushes happen in a day, both runs will still leave artifacts for up to 24 hours, so the repo can have multiple “most recent” artifacts at once, which doesn’t satisfy the “only most recent entry” requirement. Consider adding a step that deletes prior artifacts via the GitHub API before uploading the new one if you truly want only a single artifact to exist at any time.
Useful? React with 👍 / 👎.
Automates building the Windows binary on push/PR to master/main branches, storing only the most recent artifact.
Implementation
Workflow:
.github/workflows/build-windows.ymlwindows-latestwith .NET 8.x SDKdotnet publishFolderSnippets.exeto GitHub artifactsArtifact Retention:
retention-days: 1- automatic cleanup after 24 hoursoverwrite: true- allows reusing artifact nameSecurity: Explicit
permissions: contents: readto limit GITHUB_TOKEN scopeManual Trigger
Includes
workflow_dispatchfor on-demand builds from Actions tab.Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.