Skip to content

Commit 23ace4e

Browse files
committed
Add build type in version
1 parent dbf029e commit 23ace4e

File tree

3 files changed

+9
-4
lines changed

3 files changed

+9
-4
lines changed

.github/scripts/setup_build_variables.sh

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ BUILD_DATE=$(date +"%a %b %d %Y")
66
VERSION_NUMBER=$(grep "project.*" CMakeLists.txt | egrep -o "${VERSION_REGEX}")
77
WORKSPACE="$GITHUB_WORKSPACE"
88
INSTALL_PREFIX="$WORKSPACE/tmp"
9-
BUILD_TYPE="$MATRIX_BUILD_TYPE"
109

1110
echo "BUILD_TYPE=$BUILD_TYPE" >> $GITHUB_ENV
1211
echo "BUILD_TIME=$BUILD_TIME" >> $GITHUB_ENV
@@ -35,11 +34,11 @@ if [[ -z "${GITHUB_TAG}" ]]; then
3534
echo "Build is not tagged this is a continuous build"
3635
VERSION_SUFFIX="continuous"
3736
echo "VERSION_SUFFIX=$VERSION_SUFFIX" >> $GITHUB_ENV
38-
echo "VERSION=${VERSION_NUMBER}-${VERSION_SUFFIX}" >> $GITHUB_ENV
37+
echo "VERSION=${VERSION_NUMBER}-${$BUILD_TYPE}-${VERSION_SUFFIX}" >> $GITHUB_ENV
3938
else
4039
echo "Build is tagged this is not a continues build"
4140
echo "Building ksnip-plugin-ocr version ${VERSION_NUMBER}"
42-
echo "VERSION=${VERSION_NUMBER}" >> $GITHUB_ENV
41+
echo "VERSION=${VERSION_NUMBER}-${$BUILD_TYPE}" >> $GITHUB_ENV
4342
fi
4443

4544

.github/workflows/linux.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,14 @@ jobs:
1111
runs-on: ubuntu-latest
1212
strategy:
1313
matrix:
14-
build_type: [ debug, release ]
14+
build-type: [ debug, release ]
1515
steps:
1616
- name: Checkout
1717
uses: actions/checkout@v2
1818

1919
- name: Set up build variables
20+
env:
21+
BUILD_TYPE: ${{ matrix.build-type }}
2022
run: bash ./.github/scripts/setup_build_variables.sh
2123

2224
- name: Install Qt
@@ -55,6 +57,8 @@ jobs:
5557
uses: actions/checkout@v2
5658

5759
- name: Set up build variables
60+
env:
61+
BUILD_TYPE: ${{ matrix.build-type }}
5862
run: bash ./.github/scripts/setup_build_variables.sh
5963

6064
- name: Install Qt

.github/workflows/windows.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ jobs:
1717
uses: actions/checkout@v2
1818

1919
- name: Set up build variables
20+
env:
21+
BUILD_TYPE: ${{ matrix.build-type }}
2022
run: bash ./.github/scripts/setup_build_variables.sh
2123

2224
- name: Install Qt

0 commit comments

Comments
 (0)