Skip to content

Conversation

@maythamfahmi
Copy link
Collaborator

No description provided.

Refactored `cd-release-preview.yml` and `cd-release.yml` to use a new reusable workflow, `cd-build-test-pack.yml`, for centralized build, test, and pack steps. This improves maintainability, reduces redundancy, and simplifies artifact handling.

Key changes:
- Introduced `cd-build-test-pack.yml` reusable workflow.
- Replaced `build` jobs with `build-and-pack` in both workflows.
- Simplified `publish` jobs to use artifact-based NuGet push.
- Added `prepare` job in `cd-release.yml` for release notes handling.
- Removed redundant steps for setting version, building, and packing.
- Improved modularity by uploading and downloading artifacts between jobs.
Removed the `runner` input and hardcoded `ubuntu-latest` as the
runner for the build job. Added a "Sanitize version" step to
clean the `version` input by stripping leading `v` or `V`.
Updated `dotnet build`, `dotnet test`, and `dotnet pack` to use
the sanitized version. Upgraded `actions/checkout` and
`actions/setup-dotnet` to `v4` for improved compatibility.
Simplified workflow configuration by removing unused inputs.
Expanded CONTRIBUTING.md with detailed guidelines:
- Added purpose and intent to help contributors avoid build issues.
- Documented workflow reuse conventions with examples.
- Defined versioning/tagging rules aligned with SemVer/NuGet.
- Provided CI version sanitization steps and usage examples.
- Included troubleshooting tips for common CI issues.
- Emphasized maintenance alignment with GitHub Actions/NuGet.
Added a step to fetch the `origin/main` branch with a depth of 1
in the `cd-release.yml` workflow. Introduced a step to verify
that the current commit exists in the `origin/main` branch by
checking if the branch contains the commit. These changes
ensure consistency and validate that the release process
operates on a valid commit from the main branch.
Updated `cd-release.yml` to use `actions/checkout@v4` with `fetch-depth: 0` and modified the "Verify commit exists in origin/main" step.

Updated `CryptoNet.sln` to reflect `VisualStudioVersion` 18.3.11222.16 and added a reference to the new workflow file `.github/workflows/cd-build-test-pack.yml` under the `DevOps` project section.
@maythamfahmi maythamfahmi self-assigned this Nov 30, 2025
@maythamfahmi maythamfahmi merged commit 9762996 into main Nov 30, 2025
8 of 10 checks passed
@maythamfahmi maythamfahmi deleted the feature/enhance-pipelines branch December 8, 2025 20:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants