Skip to content

Update SqlServer testing image #125

Update SqlServer testing image

Update SqlServer testing image #125

Workflow file for this run

name: Bump package version
on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: |
8.0.x
9.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Run tests
run: dotnet test
- name: Bump version
id: bump
shell: pwsh
run: |
$xml = [Xml] (Get-Content .\src\Ooze.Typed\Ooze.Typed.csproj)
$version = [Version] $xml.Project.PropertyGroup.Version
$newVersion = "{0}.{1}.{2}" -f $version.Major, $version.Minor, ($version.Build + 1)
$xml.Project.PropertyGroup.Version = $newVersion
$xml.Save("./src/Ooze.Typed/Ooze.Typed.csproj")
$xml = [Xml] (Get-Content .\src\Ooze.Typed.EntityFrameworkCore\Ooze.Typed.EntityFrameworkCore.csproj)
$xml.Project.PropertyGroup.Version = $newVersion
$xml.Save("./src/Ooze.Typed.EntityFrameworkCore/Ooze.Typed.EntityFrameworkCore.csproj")
$xml = [Xml] (Get-Content .\src\Ooze.Typed.EntityFrameworkCore.Sqlite\Ooze.Typed.EntityFrameworkCore.Sqlite.csproj)
$xml.Project.PropertyGroup.Version = $newVersion
$xml.Save("./src/Ooze.Typed.EntityFrameworkCore.Sqlite/Ooze.Typed.EntityFrameworkCore.Sqlite.csproj")
$xml = [Xml] (Get-Content .\src\Ooze.Typed.EntityFrameworkCore.SqlServer\Ooze.Typed.EntityFrameworkCore.SqlServer.csproj)
$xml.Project.PropertyGroup.Version = $newVersion
$xml.Save("./src/Ooze.Typed.EntityFrameworkCore.SqlServer/Ooze.Typed.EntityFrameworkCore.SqlServer.csproj")
$xml = [Xml] (Get-Content .\src\Ooze.Typed.EntityFrameworkCore.Npgsql\Ooze.Typed.EntityFrameworkCore.Npgsql.csproj)
$xml.Project.PropertyGroup.Version = $newVersion
$xml.Save("./src/Ooze.Typed.EntityFrameworkCore.Npgsql/Ooze.Typed.EntityFrameworkCore.Npgsql.csproj")
$xml = [Xml] (Get-Content .\src\Ooze.Typed.EntityFrameworkCore.MySql\Ooze.Typed.EntityFrameworkCore.MySql.csproj)
$xml.Project.PropertyGroup.Version = $newVersion
$xml.Save("./src/Ooze.Typed.EntityFrameworkCore.MySql/Ooze.Typed.EntityFrameworkCore.MySql.csproj")
echo "::set-output name=newVersion::$newVersion"
- name: Commit changes
run: |
git status
git config user.name "ooze"
git config user.email "[email protected]"
git add ./src/*
git commit -m "Bump project version to ${{ steps.bump.outputs.newVersion }}"
git push