Просмотр исходного кода

Fix: Update substring handling in firmware build workflow

This commit corrects the extraction of the minor version value in the SubBrute application's firmware build workflow. The fix ensures the last part of the version tag is parsed correctly by excluding the delimiter from the resulting substring.
DerSkythe 2 лет назад
Родитель
Сommit
54a98f9f15
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      .github/workflows/build-with-firmwware.yml

+ 1 - 1
.github/workflows/build-with-firmwware.yml

@@ -104,7 +104,7 @@ jobs:
             $latestTag = ((gh release view --json tagName,url -R ${{ vars.REPO_SELF }}) | ConvertFrom-Json ).tagName
             $lastIndex = $latestTag.LastIndexOf('.')
             
-            $minorValue = $latestTag.Substring($latestTag.LastIndexOf('.'))
+            $minorValue = $latestTag.Substring($latestTag.LastIndexOf('.') + 1)
             $minorValue = [Convert]::ToInt32($minorValue) + 1
             $latestTag = $latestTag.Substring(0, $lastIndex)