This repository has been archived by the owner on Dec 18, 2023. It is now read-only.
forked from tiaringhio/Surreal.NET
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into tests_on_windows_fixes
- Loading branch information
Showing
16 changed files
with
158 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#!/bin/env bash | ||
|
||
# Obtain the latest version from the stable branch | ||
ver=$(grep -oPm1 "(?<=<Version>)[^<]+" src/Directory.Build.props) | ||
|
||
# Generate the nightly version | ||
ver="v$ver-nightly$(date +%Y%m%d)" | ||
export NIGHTLY_TAG=$ver | ||
# Set environment variable for use in the next step | ||
echo "NIGHTLY_TAG=$ver" >>$GITHUB_ENV |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#!/bin/env bash | ||
# This script is used to update the patch versions of the project. | ||
|
||
# Get the current version tag from the argument | ||
cur_ver=$1 | ||
# Convert the tag to a SemVer compatbile version | ||
cur_ver=${cur_ver#v} | ||
|
||
# Read the version from src/Directory.Build.props | ||
# `<Version>1.0.4</Version>`. We later need to update the property | ||
ver=$(grep -oPm1 "(?<=<Version>)[^<]+" src/Directory.Build.props) | ||
|
||
# The version is defined in src/Directory.Build.props as a property | ||
echo "Patching project version from $ver to $cur_ver" | ||
sed -i "s/<Version>.*<\/Version>/<Version>$cur_ver<\/Version>/" src/Directory.Build.props | ||
|
||
# The version is also defined in the README.md | ||
# Replace the version in `Version="1.0.3"` with the current version | ||
echo "Patching README.md version from $ver to $cur_ver" | ||
sed -i "s/Version=\".*\"/Version=\"$cur_ver\"/" README.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: Nightly | ||
|
||
on: | ||
schedule: | ||
- cron: "0 0 * * *" | ||
|
||
env: | ||
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true | ||
DOTNET_CLI_TELEMETRY_OPTOUT: 1 | ||
DOTNET_SYSTEM_GLOBALIZATION_INVARIANT: true | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
jobs: | ||
nightly: | ||
permissions: | ||
contents: write | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
ref: master | ||
|
||
- name: Get version | ||
run: | | ||
.github/nightly_version.sh | ||
- name: Patch version | ||
run: | | ||
.github/patch_version.sh ${{ env:NIGHTLY_TAG }} | ||
- name: Create release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ github.token }} | ||
with: | ||
tag_name: ${{ env:NIGHTLY_TAG }} | ||
release_name: ${{ env:NIGHTLY_TAG }} - Automated nightly release | ||
generateReleaseNotes: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
name: Release | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
tag: | ||
type: string | ||
description: Tag | ||
required: true | ||
message: | ||
type: string | ||
description: Message | ||
required: true | ||
env: | ||
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true | ||
DOTNET_CLI_TELEMETRY_OPTOUT: 1 | ||
DOTNET_SYSTEM_GLOBALIZATION_INVARIANT: true | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
jobs: | ||
release: | ||
permissions: | ||
contents: write | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Merge master -> release | ||
uses: devmasx/merge-branch@master | ||
with: | ||
type: now | ||
from_branch: master | ||
target_branch: release | ||
github_token: ${{ github.token }} | ||
|
||
- uses: actions/checkout@v3 | ||
with: | ||
ref: release | ||
|
||
- name: Patch version | ||
run: | | ||
../patch_version.sh ${{ github.event.inputs.tag }} | ||
- name: Commit version | ||
uses: stefanzweifel/git-auto-commit-action@v4 | ||
with: | ||
commit_options: "--no-verify --signoff" | ||
file_pattern: "**.props *.md" | ||
|
||
- name: Merge release -> master | ||
uses: devmasx/merge-branch@master | ||
with: | ||
type: now | ||
from_branch: release | ||
target_branch: master | ||
github_token: ${{ github.token }} | ||
|
||
- name: Create release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ github.token }} | ||
with: | ||
tag_name: ${{ github.event.inputs.tag }} | ||
release_name: ${{ github.event.inputs.tag }} - ${{ github.event.inputs.message }} | ||
generateReleaseNotes: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters