Skip to content

Fix case sensitive comparison (closes #198) #298

Fix case sensitive comparison (closes #198)

Fix case sensitive comparison (closes #198) #298

Workflow file for this run

name: release
on:
push:
tags:
- "v*"
branches:
- "*"
jobs:
build:
name: build-windows
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Figure out if we're running for a tag
id: checktag
run: |
cd ${{ github.workspace }}
If($Env:GITHUB_REF -match "(?<=v)([0-9]*)\.([0-9]*)\.([0-9]*)") {
$IsRelease = "yes";
$Version = $Matches[0];
$VersionMajor = $Matches[1];
$VersionMinor = $Matches[2];
$VersionPatch = $Matches[3];
} Else {
$IsRelease = "no";
$Version = (git describe --dirty --broken --always) -replace '^v', '';
If($Version -match "([0-9]*)\.([0-9]*)\.([0-9]*)-.*") {
$VersionMajor = $Matches[1];
$VersionMinor = $Matches[2];
$VersionPatch = $Matches[3];
} Else {
$VersionMajor = 0;
$VersionMinor = 0;
$VersionPatch = 0;
}
}
Echo ("is_release=" + $IsRelease) >> $Env:GITHUB_OUTPUT;
Echo ("version=" + $Version) >> $Env:GITHUB_OUTPUT;
Echo ("version_major=" + $VersionMajor) >> $Env:GITHUB_OUTPUT;
Echo ("version_minor=" + $VersionMinor) >> $Env:GITHUB_OUTPUT;
Echo ("version_patch=" + $VersionPatch) >> $Env:GITHUB_OUTPUT;
- name: Build Algorithms
run: |
cd ${{ github.workspace }}
.\build_algorithms.ps1
- name: Build OpenHashTab
run: |
cd ${{ github.workspace }}
$Env:CI_VERSION = "${{ steps.checktag.outputs.version }}";
$Env:CI_VERSION_MAJOR = "${{ steps.checktag.outputs.version_major }}";
$Env:CI_VERSION_MINOR = "${{ steps.checktag.outputs.version_minor }}";
$Env:CI_VERSION_PATCH = "${{ steps.checktag.outputs.version_patch }}";
.\build_openhashtab.ps1
- name: Build Installer
run: |
iscc .\installer.iss -DCI_VERSION="${{ steps.checktag.outputs.version }}" -DCI_VERSION_NUMERIC="${{ steps.checktag.outputs.version_major }}.${{ steps.checktag.outputs.version_minor }}.${{ steps.checktag.outputs.version_patch }}"
- name: Upload Installer
uses: actions/upload-artifact@v4
with:
name: setup
path: |
.\OpenHashTab_setup.exe
- name: Upload Unpacked
uses: actions/upload-artifact@v4
with:
name: unpacked
path: |
.\AlgorithmsDlls\*.dll
.\AlgorithmsDlls\*.pdb
.\cmake-openhashtab-x64\OpenHashTab.dll
.\cmake-openhashtab-x64\*.exe
.\cmake-openhashtab-x64\*.pdb
.\cmake-openhashtab-ARM64\OpenHashTab.dll
.\cmake-openhashtab-ARM64\*.exe
.\cmake-openhashtab-ARM64\*.pdb