diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 10e1045..14510e8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -9,7 +9,7 @@ concurrency: on: push: tags: - - 'v*' + - 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10 # So we can use the GitHub API to create releases with the run token. permissions: @@ -42,6 +42,12 @@ jobs: wget https://goatcorp.github.io/dalamud-distrib/latest.zip -O /tmp/dalamud.zip unzip /tmp/dalamud.zip -d /tmp/dalamud + - name: Update Version in csproj + run: | + release_version=$(echo ${{ github.ref_name }} | sed 's/^v//') + sed -i Meddle.Plugin.csproj -E \ + -e 's#[0-9]*\.([0-9]*\.){0,1}[0-9]*#'"$release_version"'#g' + - name: Restore Dependencies run: dotnet restore @@ -78,15 +84,17 @@ jobs: cd ../../ release_version=$(echo ${{ github.ref_name }} | sed 's/^v//') - repo_url=$(echo ${{ github.server_url }}/${{ github.repository }} | sed 's/#/\\#/g') - + repo_url=$(echo ${{ github.server_url }}/${{ github.repository }} | sed 's/#/\\#/g') sed -i repo.json -E \ -e 's#"AssemblyVersion": "([0-9]*\.){2,3}[0-9]*"#"AssemblyVersion": "'"$release_version"'"#g' \ -e 's#"TestingAssemblyVersion": "([0-9]*\.){2,3}[0-9]*"#"TestingAssemblyVersion": "'"$release_version"'"#' \ -e 's#"DownloadLinkInstall": "[^"]*"#"DownloadLinkInstall": "'"$repo_url/releases/download/${{ github.ref_name }}/latest.zip"'"#g' \ -e 's#"DownloadLinkTesting": "[^"]*"#"DownloadLinkTesting": "'"$repo_url/releases/download/${{ github.ref_name }}/latest.zip"'"#g' \ -e 's#"DownloadLinkUpdate": "[^"]*"#"DownloadLinkUpdate": "'"$repo_url/releases/download/${{ github.ref_name }}/latest.zip"'"#g' - + sed -i Meddle/Meddle.Plugin/Meddle.Plugin.csproj -E \ + -e 's#[0-9]*\.([0-9]*\.){0,1}[0-9]*#'"$release_version"'#g' + + git add Meddle/Meddle.Plugin/Meddle.Plugin.csproj git add repo.json git config --local user.name "github-actions [bot]" git config --local user.email "github-actions@users.noreply.github.com" diff --git a/Meddle/Meddle.Plugin/Meddle.Plugin.csproj b/Meddle/Meddle.Plugin/Meddle.Plugin.csproj index b11c8b7..30398b6 100644 --- a/Meddle/Meddle.Plugin/Meddle.Plugin.csproj +++ b/Meddle/Meddle.Plugin/Meddle.Plugin.csproj @@ -1,6 +1,6 @@ - 0.0.1 + 0.0.3 net7.0-windows enable enable diff --git a/repo.json b/repo.json index cb1b75f..9fece4b 100644 --- a/repo.json +++ b/repo.json @@ -4,8 +4,8 @@ "Name": "Meddle", "InternalName": "Meddle.Plugin", "Description": "Did I mention I'm a model?", - "AssemblyVersion": "0.0.2", - "TestingAssemblyVersion": "0.0.2", + "AssemblyVersion": "0.0.3", + "TestingAssemblyVersion": "0.0.3", "RepoUrl": "https://github.com/PassiveModding/Meddle", "ApplicableVersion": "any", "DalamudApiLevel": 9, @@ -13,8 +13,8 @@ "Xande", "Models" ], - "DownloadLinkInstall": "https://github.com/PassiveModding/Meddle/releases/download/v0.0.2/latest.zip", - "DownloadLinkTesting": "https://github.com/PassiveModding/Meddle/releases/download/v0.0.2/latest.zip", - "DownloadLinkUpdate": "https://github.com/PassiveModding/Meddle/releases/download/v0.0.2/latest.zip" + "DownloadLinkInstall": "https://github.com/PassiveModding/Meddle/releases/download/v0.0.3/latest.zip", + "DownloadLinkTesting": "https://github.com/PassiveModding/Meddle/releases/download/v0.0.3/latest.zip", + "DownloadLinkUpdate": "https://github.com/PassiveModding/Meddle/releases/download/v0.0.3/latest.zip" } ] \ No newline at end of file