Skip to content

Commit 51dfdcc

Browse files
authored
Rename references to dev branch to main (#14)
Signed-off-by: Ludvig Liljenberg <[email protected]>
1 parent 6f670c1 commit 51dfdcc

File tree

8 files changed

+24
-24
lines changed

8 files changed

+24
-24
lines changed

.github/workflows/Benchmarks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ jobs:
7474
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
7575

7676
- name: Run Benchmarks
77-
run: just bench-ci dev release
77+
run: just bench-ci main release
7878

7979
- uses: actions/upload-artifact@v3
8080
with:

.github/workflows/CargoPublish.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ jobs:
1414
publish-hyperlight-packages:
1515
runs-on: [self-hosted, Linux, X64, "1ES.Pool=hld-kvm-amd"]
1616

17-
# We should only publish from dev if minver contains `-preview`
18-
if: ${{ contains(github.ref, 'refs/heads/release/') }} || ${{ github.ref=='refs/heads/dev' }}
17+
# We should only publish from main if minver contains `-preview`
18+
if: ${{ contains(github.ref, 'refs/heads/release/') }} || ${{ github.ref=='refs/heads/main' }}
1919

2020
steps:
2121
- uses: actions/checkout@v4
@@ -46,7 +46,7 @@ jobs:
4646
run: |
4747
echo "github.ref=${{ github.ref }}"
4848
echo "HYPERLIGHT_VERSION=$HYPERLIGHT_VERSION"
49-
if [[ ${{ github.ref }} =~ 'refs/heads/release/' || ( ${{ github.ref }} == 'refs/heads/dev' && $HYPERLIGHT_VERSION =~ '-preview' ) ]]
49+
if [[ ${{ github.ref }} =~ 'refs/heads/release/' || ( ${{ github.ref }} == 'refs/heads/main' && $HYPERLIGHT_VERSION =~ '-preview' ) ]]
5050
then
5151
echo "Setting SHOULD_PUBLISH in GITHUB_ENV"
5252
echo "SHOULD_PUBLISH=true" >> "$GITHUB_ENV"

.github/workflows/CreateRelease.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ name: Create a Release
55
on:
66
workflow_dispatch:
77
push:
8-
branches: [dev]
8+
branches: [main]
99

1010
permissions:
1111
contents: write
@@ -17,7 +17,7 @@ jobs:
1717

1818
build-rust-ubuntu:
1919
# see https://github.com/orgs/community/discussions/26286#discussioncomment-3251208 for why we need to check the ref
20-
if: ${{ contains(github.ref, 'refs/heads/release/') }} || ${{ github.ref=='refs/heads/dev' }}
20+
if: ${{ contains(github.ref, 'refs/heads/release/') }} || ${{ github.ref=='refs/heads/main' }}
2121
runs-on: [self-hosted, Linux, X64, "1ES.Pool=hld-kvm-amd"]
2222

2323
steps:
@@ -46,7 +46,7 @@ jobs:
4646

4747
build-rust-windows:
4848
# see https://github.com/orgs/community/discussions/26286#discussioncomment-3251208 for why we need to check the ref
49-
if: ${{ contains(github.ref, 'refs/heads/release/') }} || ${{ github.ref=='refs/heads/dev' }}
49+
if: ${{ contains(github.ref, 'refs/heads/release/') }} || ${{ github.ref=='refs/heads/main' }}
5050
runs-on: windows-2022
5151

5252
steps:
@@ -92,7 +92,7 @@ jobs:
9292

9393
publish:
9494
# see https://github.com/orgs/community/discussions/26286#discussioncomment-3251208 for why we need to check the ref
95-
if: ${{ contains(github.ref, 'refs/heads/release/') }} || ${{ github.ref=='refs/heads/dev' }}
95+
if: ${{ contains(github.ref, 'refs/heads/release/') }} || ${{ github.ref=='refs/heads/main' }}
9696
runs-on: windows-2022
9797
outputs:
9898
HYPERLIGHT_VERSION: ${{ steps.set_hyperlight_version.outputs.HYPERLIGHT_VERSION }}
@@ -111,7 +111,7 @@ jobs:
111111

112112
steps:
113113
- name: Set Debug Configuration
114-
if: ${{ github.ref=='refs/heads/dev' }}
114+
if: ${{ github.ref=='refs/heads/main' }}
115115
run: echo "CONFIG=debug" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append
116116
shell: pwsh
117117

@@ -188,7 +188,7 @@ jobs:
188188
echo "github.ref=${{ github.ref }}"
189189
echo "HYPERLIGHT_VERSION=$Env:HYPERLIGHT_VERSION"
190190
if (('${{ github.ref }}'.contains('refs/heads/release')) -or
191-
(('${{ github.ref }}'.contains('refs/heads/dev')) -and
191+
(('${{ github.ref }}'.contains('refs/heads/main')) -and
192192
($Env:HYPERLIGHT_VERSION.contains('-preview')))) {
193193
echo "Setting SHOULD_PUBLISH in GITHUB_ENV"
194194
echo "SHOULD_PUBLISH=true" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append
@@ -249,12 +249,12 @@ jobs:
249249
include.tar.gz
250250
env:
251251
GH_TOKEN: ${{ github.token }}
252-
- name: Create release (dev)
253-
# Only create a dev release if we are on the dev branch
254-
if: ${{ github.ref=='refs/heads/dev' }}
252+
- name: Create prerelease
253+
# Only create a prerelease if we are on the main branch
254+
if: ${{ github.ref=='refs/heads/main' }}
255255
run: |
256256
gh release delete dev-latest -y --cleanup-tag || $true
257-
gh release create dev-latest -t "Latest Development Build From Dev Branch" --latest=false -p `
257+
gh release create dev-latest -t "Latest prerelease from main branch" --latest=false -p `
258258
src/tests/rust_guests/bin/${{ env.CONFIG }}/callbackguest `
259259
src/tests/rust_guests/bin/${{ env.CONFIG }}/callbackguest.exe `
260260
src/tests/rust_guests/bin/${{ env.CONFIG }}/simpleguest `

.github/workflows/PRLabelChecker.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: Label Checker
22
on:
33
pull_request:
4-
branches: dev
4+
branches: main
55
types: [opened, labeled, unlabeled, synchronize, reopened]
66
permissions:
77
pull-requests: read

.github/workflows/ValidatePullRequest.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ name: Validate Pull Request
44

55
on:
66
pull_request:
7-
branches: [main, dev, "release/**"]
7+
branches: [main, "release/**"]
88
merge_group:
99

1010
permissions:

.github/workflows/dep_rust.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,13 +126,13 @@ jobs:
126126
run: sudo apt install gh -y
127127

128128
- name: Download benchmarks from "latest"
129-
run: just bench-download ${{ runner.os }} ${{ matrix.hypervisor }} dev-latest # compare to pre-release "dev"
129+
run: just bench-download ${{ runner.os }} ${{ matrix.hypervisor }} dev-latest # compare to prerelease
130130
env:
131131
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
132132
continue-on-error: true
133133
if: ${{ matrix.config == 'release' }}
134134

135135
- name: Run benchmarks
136136
run: |
137-
just bench-ci dev ${{ matrix.config }}
137+
just bench-ci main ${{ matrix.config }}
138138
if: ${{ matrix.config == 'release' }}

docs/benchmarking-hyperlight.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Hyperlight uses the [Criterion](https://bheisler.github.io/criterion.rs/book/ind
55
## When Benchmarks are ran
66

77
1. Every time a branch gets a push
8-
- Compares the current branch benchmarking results to the "dev-latest" release (which is the most recent push to "dev" branch). This is done as part of `dep_rust.yml`, which is invoked by `ValidatePullRequest.yml`. These benchmarks are for the developer to compare their branch to dev, and the results can only be seen in the GitHub action logs, and nothing is saved.
8+
- Compares the current branch benchmarking results to the "dev-latest" release (which is the most recent push to "main" branch). This is done as part of `dep_rust.yml`, which is invoked by `ValidatePullRequest.yml`. These benchmarks are for the developer to compare their branch to main, and the results can only be seen in the GitHub action logs, and nothing is saved.
99

1010
```
1111
sandboxes/create_sandbox
@@ -72,4 +72,4 @@ Found 1 outliers among 100 measurements (1.00%)
7272
7373
## Running benchmarks locally
7474
75-
Use `just bench [debug/release]` parameter to run benchmarks. Comparing local benchmarks results to github-saved benchmarks doesn't make much sense, since you'd be using different hardware, but you can use `just bench-download os hypervisor [tag] ` to download and extract the GitHub release benchmarks to the correct place folder. You can then run `just bench-ci dev` to compare to (and overwrite) the previous release benchmarks. Note that `dev` is the name of the baselines stored in GitHub.
75+
Use `just bench [debug/release]` parameter to run benchmarks. Comparing local benchmarks results to github-saved benchmarks doesn't make much sense, since you'd be using different hardware, but you can use `just bench-download os hypervisor [tag] ` to download and extract the GitHub release benchmarks to the correct place folder. You can then run `just bench-ci main` to compare to (and overwrite) the previous release benchmarks. Note that `main` is the name of the baselines stored in GitHub.

docs/how-to-make-releases.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@ This document details the process of releasing a new version of Hyperlight to th
66

77
Currently, we need to manually update the workspace `Cargo.toml` version number to match to whatever release we are making. This will affect the version of all the crates in the workspace.
88

9-
> Note: we'll use `v0.4.0` as the version for the above and all subsequent instructions. You should replace this with the version you're releasing. Make sure your version follows [SemVer](https://semver.org) conventions as closely as possible, and is prefixed with a `v` character. *In particular do not use a patch version unless you are patching an issue in a release branch, releases from dev should always be minor or major versions*.
9+
> Note: we'll use `v0.4.0` as the version for the above and all subsequent instructions. You should replace this with the version you're releasing. Make sure your version follows [SemVer](https://semver.org) conventions as closely as possible, and is prefixed with a `v` character. *In particular do not use a patch version unless you are patching an issue in a release branch, releases from main should always be minor or major versions*.
1010
11-
Create a PR with this change and merge it into the dev branch.
11+
Create a PR with this change and merge it into the main branch.
1212

1313
## Create a tag
1414

15-
When the above PR has merged into `dev` branch you should create a tag. ***Make sure you have pulled the recently updated `dev` branch***, and do the following on the `dev` branch:
15+
When the above PR has merged into `main` branch you should create a tag. ***Make sure you have pulled the recently updated `main` branch***, and do the following on the `main` branch:
1616

1717
```bash
1818
git tag -a v0.4.0 -m "A brief description of the release"
@@ -33,7 +33,7 @@ After the previous CI job runs to create the new release branch, go to the ["Cre
3333
2. In the Use workflow from dropdown, select the `release/v0.4.0` branch
3434
3. Click the green **Run workflow** button
3535

36-
> Note: In case you see a "Create a Release" job already running before starting this step, that is because the "Create a Release" workflow also automatically runs on push to `dev` branch to create a pre-release. You must still do the steps outlined above.
36+
> Note: In case you see a "Create a Release" job already running before starting this step, that is because the "Create a Release" workflow also automatically runs on push to `main` branch to create a pre-release. You must still do the steps outlined above.
3737
3838
When this job is done, a new [GitHub release](https://github.com/hyperlight-dev/hyperlight/releases) will be created for you. This job also publishes the following rust packages to the crates.io:
3939
- `hyperlight-common`

0 commit comments

Comments
 (0)