mirror of
https://github.com/bia-technologies/yaxunit.git
synced 2025-01-20 18:48:36 +02:00
build release job and bump actions dependences
This commit is contained in:
parent
36f71d70a4
commit
612625ee6a
73
.github/workflows/build-release.yml
vendored
Normal file
73
.github/workflows/build-release.yml
vendored
Normal file
@ -0,0 +1,73 @@
|
|||||||
|
name: Build release
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- '*'
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.number }}-release
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
export_to_designer:
|
||||||
|
name: Export to designer xml
|
||||||
|
uses: ./.github/workflows/step-export-xml.yml
|
||||||
|
with:
|
||||||
|
edt_version: 2023.1.2
|
||||||
|
artifact_name: designer-src
|
||||||
|
engine_only: true
|
||||||
|
secrets: inherit
|
||||||
|
|
||||||
|
build_artifacts:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
needs: export_to_designer
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: install 8.3.21.1895
|
||||||
|
uses: alkoleft/onec-setup-build-env-action@develop
|
||||||
|
with:
|
||||||
|
type: onec
|
||||||
|
onec_version: 8.3.21.1895
|
||||||
|
cache: true
|
||||||
|
env:
|
||||||
|
ONEC_USERNAME: ${{ secrets.ONEC_USERNAME }}
|
||||||
|
ONEC_PASSWORD: ${{ secrets.ONEC_PASSWORD }}
|
||||||
|
timeout-minutes: 10
|
||||||
|
|
||||||
|
- name: download artifact
|
||||||
|
uses: actions/download-artifact@v4
|
||||||
|
with:
|
||||||
|
name: designer-src
|
||||||
|
- name: extract artifacts
|
||||||
|
run: |
|
||||||
|
mkdir export
|
||||||
|
cd export
|
||||||
|
7z x ../export.7z -y
|
||||||
|
|
||||||
|
- name: create IB
|
||||||
|
run: ibcmd infobase create --db-path=file-db
|
||||||
|
timeout-minutes: 5
|
||||||
|
|
||||||
|
- name: import yaxunit
|
||||||
|
run: ibcmd infobase config import --db-path=file-db --extension=YAXUNIT export/yaxunit
|
||||||
|
timeout-minutes: 5
|
||||||
|
|
||||||
|
- name: save yaxunit
|
||||||
|
run: ibcmd infobase config save --db-path=file-db --extension=YAXUNIT YAxUnit-${{ needs.export_to_designer.outputs.yaxunit_version }}.cfe
|
||||||
|
timeout-minutes: 5
|
||||||
|
|
||||||
|
- name: Release
|
||||||
|
uses: softprops/action-gh-release@v2
|
||||||
|
if: ${{ success() }}
|
||||||
|
with:
|
||||||
|
draft: true
|
||||||
|
files: YAxUnit-*.cfe
|
||||||
|
fail_on_unmatched_files: true
|
||||||
|
generate_release_notes: true
|
||||||
|
append_body: false
|
||||||
|
name: Версия ${{ needs.export_to_designer.outputs.yaxunit_version }}
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
2
.github/workflows/deploy-documentation.yml
vendored
2
.github/workflows/deploy-documentation.yml
vendored
@ -16,7 +16,7 @@ jobs:
|
|||||||
name: Deploy to GitHub Pages
|
name: Deploy to GitHub Pages
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
- name: Download bsl doc
|
- name: Download bsl doc
|
||||||
run: curl -L https://github.com/alkoleft/bsldoc/releases/download/0.1.0/bsldoc-0.1.0.jar --output ./bsldoc.jar && chmod +7 ./bsldoc.jar
|
run: curl -L https://github.com/alkoleft/bsldoc/releases/download/0.1.0/bsldoc-0.1.0.jar --output ./bsldoc.jar && chmod +7 ./bsldoc.jar
|
||||||
- name: Generate API documentation
|
- name: Generate API documentation
|
||||||
|
11
.github/workflows/main-build.yml
vendored
11
.github/workflows/main-build.yml
vendored
@ -4,13 +4,12 @@ on:
|
|||||||
branches:
|
branches:
|
||||||
- feature/**
|
- feature/**
|
||||||
- develop
|
- develop
|
||||||
tags:
|
|
||||||
- '*'
|
|
||||||
pull_request_target:
|
pull_request_target:
|
||||||
branches: [ develop ]
|
branches: [ develop ]
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.number }}
|
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.number }}-main
|
||||||
cancel-in-progress: true
|
cancel-in-progress: true
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
@ -66,9 +65,3 @@ jobs:
|
|||||||
v8_version: ${{ matrix.v8_version }}
|
v8_version: ${{ matrix.v8_version }}
|
||||||
locale: ${{ matrix.locale }}
|
locale: ${{ matrix.locale }}
|
||||||
secrets: inherit
|
secrets: inherit
|
||||||
|
|
||||||
publish_artifacts:
|
|
||||||
name: Publish draft release
|
|
||||||
if: ${{ startsWith(github.ref, 'refs/tags/') && success() }}
|
|
||||||
uses: ./.github/workflows/step-publish-artifacts.yml
|
|
||||||
needs: build_artifacts
|
|
||||||
|
4
.github/workflows/sq-pr.yml
vendored
4
.github/workflows/sq-pr.yml
vendored
@ -1,13 +1,13 @@
|
|||||||
name: Анализ в SonarQube (pull-request)
|
name: Анализ в SonarQube (pull-request)
|
||||||
|
|
||||||
on: [pull_request]
|
on: [pull_request_target]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
SonarScanner:
|
SonarScanner:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
repository: ${{ github.event.workflow_run.head_repository.full_name }}
|
repository: ${{ github.event.workflow_run.head_repository.full_name }}
|
||||||
ref: ${{ github.event.workflow_run.head_branch }}
|
ref: ${{ github.event.workflow_run.head_branch }}
|
||||||
|
2
.github/workflows/sq.yml
vendored
2
.github/workflows/sq.yml
vendored
@ -10,7 +10,7 @@ jobs:
|
|||||||
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.event.repository.full_name
|
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.event.repository.full_name
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
repository: ${{ github.event.workflow_run.head_repository.full_name }}
|
repository: ${{ github.event.workflow_run.head_repository.full_name }}
|
||||||
ref: ${{ github.event.workflow_run.head_branch }}
|
ref: ${{ github.event.workflow_run.head_branch }}
|
||||||
|
@ -40,7 +40,7 @@ jobs:
|
|||||||
timeout-minutes: 10
|
timeout-minutes: 10
|
||||||
|
|
||||||
- name: download artifact
|
- name: download artifact
|
||||||
uses: actions/download-artifact@v3
|
uses: actions/download-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ${{ inputs.src_artifact_name }}
|
name: ${{ inputs.src_artifact_name }}
|
||||||
|
|
||||||
@ -75,7 +75,7 @@ jobs:
|
|||||||
timeout-minutes: 5
|
timeout-minutes: 5
|
||||||
|
|
||||||
- name: upload-artifact
|
- name: upload-artifact
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ${{ inputs.artifact_name }}
|
name: ${{ inputs.artifact_name }}
|
||||||
path: binary\*.*
|
path: binary\*.*
|
||||||
|
24
.github/workflows/step-export-xml.yml
vendored
24
.github/workflows/step-export-xml.yml
vendored
@ -9,6 +9,14 @@ on:
|
|||||||
artifact_name:
|
artifact_name:
|
||||||
type: string
|
type: string
|
||||||
required: true
|
required: true
|
||||||
|
|
||||||
|
engine_only:
|
||||||
|
type: boolean
|
||||||
|
required: false
|
||||||
|
default: false
|
||||||
|
outputs:
|
||||||
|
yaxunit_version:
|
||||||
|
value: ${{ jobs.export.outputs.yaxunit_version }}
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.number }}-export
|
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.number }}-export
|
||||||
@ -17,9 +25,17 @@ concurrency:
|
|||||||
jobs:
|
jobs:
|
||||||
export:
|
export:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
outputs:
|
||||||
|
yaxunit_version: ${{ steps.extract_version.outputs.version }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Extract version
|
||||||
|
if: github.event_name == 'push'
|
||||||
|
shell: bash
|
||||||
|
run: echo "version=$(cat ./exts/yaxunit/src/Configuration/Configuration.mdo | grep -oP '(?<=<version>)[\d.]+')" >> $GITHUB_OUTPUT
|
||||||
|
id: extract_version
|
||||||
|
|
||||||
- name: install EDT
|
- name: install EDT
|
||||||
uses: alkoleft/onec-setup-build-env-action@develop
|
uses: alkoleft/onec-setup-build-env-action@develop
|
||||||
with:
|
with:
|
||||||
@ -29,9 +45,10 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
ONEC_USERNAME: ${{ secrets.ONEC_USERNAME }}
|
ONEC_USERNAME: ${{ secrets.ONEC_USERNAME }}
|
||||||
ONEC_PASSWORD: ${{ secrets.ONEC_PASSWORD }}
|
ONEC_PASSWORD: ${{ secrets.ONEC_PASSWORD }}
|
||||||
timeout-minutes: 10
|
timeout-minutes: 30
|
||||||
|
|
||||||
- name: convert configuration src
|
- name: convert configuration src
|
||||||
|
if: ${{ !inputs.engine_only }}
|
||||||
uses: alkoleft/onec-edtcli-command-action@main
|
uses: alkoleft/onec-edtcli-command-action@main
|
||||||
with:
|
with:
|
||||||
export: true
|
export: true
|
||||||
@ -50,6 +67,7 @@ jobs:
|
|||||||
timeout-minutes: 10
|
timeout-minutes: 10
|
||||||
|
|
||||||
- name: convert tests src
|
- name: convert tests src
|
||||||
|
if: ${{ !inputs.engine_only }}
|
||||||
uses: alkoleft/onec-edtcli-command-action@main
|
uses: alkoleft/onec-edtcli-command-action@main
|
||||||
with:
|
with:
|
||||||
export: true
|
export: true
|
||||||
@ -63,7 +81,7 @@ jobs:
|
|||||||
7za a -t7z ../export.7z ./
|
7za a -t7z ../export.7z ./
|
||||||
|
|
||||||
- name: upload-artifact
|
- name: upload-artifact
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ${{ inputs.artifact_name }}
|
name: ${{ inputs.artifact_name }}
|
||||||
path: export.7z
|
path: export.7z
|
||||||
|
2
.github/workflows/step-publish-artifacts.yml
vendored
2
.github/workflows/step-publish-artifacts.yml
vendored
@ -21,7 +21,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: download artifact
|
- name: download artifact
|
||||||
uses: actions/download-artifact@v3
|
uses: actions/download-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ${{ inputs.artifact_name }}
|
name: ${{ inputs.artifact_name }}
|
||||||
path: binary
|
path: binary
|
||||||
|
6
.github/workflows/step-run-tests-linux.yml
vendored
6
.github/workflows/step-run-tests-linux.yml
vendored
@ -38,7 +38,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: download artifact
|
- name: download artifact
|
||||||
uses: actions/download-artifact@v3
|
uses: actions/download-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ${{ inputs.artifact_name }}
|
name: ${{ inputs.artifact_name }}
|
||||||
path: binary
|
path: binary
|
||||||
@ -157,14 +157,14 @@ jobs:
|
|||||||
run: cat ./output.log
|
run: cat ./output.log
|
||||||
|
|
||||||
- name: upload-artifact
|
- name: upload-artifact
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
if: always()
|
if: always()
|
||||||
with:
|
with:
|
||||||
name: Tests report. Linux ${{ inputs.v8_version }} ${{ inputs.locale }}
|
name: Tests report. Linux ${{ inputs.v8_version }} ${{ inputs.locale }}
|
||||||
path: reports/*.*
|
path: reports/*.*
|
||||||
|
|
||||||
- name: Publish Test Report
|
- name: Publish Test Report
|
||||||
uses: mikepenz/action-junit-report@v3
|
uses: 1CDevFlow/action-onec-junit-report@main
|
||||||
if: always()
|
if: always()
|
||||||
with:
|
with:
|
||||||
job_name: Tests Linux ${{ inputs.v8_version }} ${{ inputs.locale }}
|
job_name: Tests Linux ${{ inputs.v8_version }} ${{ inputs.locale }}
|
||||||
|
14
.github/workflows/step-run-tests-windows.yml
vendored
14
.github/workflows/step-run-tests-windows.yml
vendored
@ -37,7 +37,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: download artifact
|
- name: download artifact
|
||||||
uses: actions/download-artifact@v3
|
uses: actions/download-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ${{ inputs.artifact_name }}
|
name: ${{ inputs.artifact_name }}
|
||||||
path: binary
|
path: binary
|
||||||
@ -89,11 +89,11 @@ jobs:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
- uses: bhowell2/github-substring-action@1.0.2
|
- name: set short_locale
|
||||||
id: short_locale
|
id: short_locale
|
||||||
with:
|
run: |
|
||||||
value: ${{ inputs.locale }}
|
Write-Output "substring='${{ inputs.locale }}'.Substring(0, 2)" >> $Env:GITHUB_OUTPUT
|
||||||
length_from_start: 2
|
|
||||||
- name: Test
|
- name: Test
|
||||||
run: |
|
run: |
|
||||||
Start-Process ibsrv.exe -ArgumentList "--data=data"
|
Start-Process ibsrv.exe -ArgumentList "--data=data"
|
||||||
@ -109,13 +109,13 @@ jobs:
|
|||||||
run: type 1cv8c-output.log
|
run: type 1cv8c-output.log
|
||||||
|
|
||||||
- name: upload-artifact
|
- name: upload-artifact
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: Tests report. Windows ${{ inputs.v8_version }} ${{ inputs.locale }}
|
name: Tests report. Windows ${{ inputs.v8_version }} ${{ inputs.locale }}
|
||||||
path: reports/
|
path: reports/
|
||||||
|
|
||||||
- name: Publish Test Report
|
- name: Publish Test Report
|
||||||
uses: mikepenz/action-junit-report@v3
|
uses: 1CDevFlow/action-onec-junit-report@main
|
||||||
with:
|
with:
|
||||||
job_name: Tests Windows ${{ inputs.v8_version }} ${{ inputs.locale }}
|
job_name: Tests Windows ${{ inputs.v8_version }} ${{ inputs.locale }}
|
||||||
check_name: Tests report. Windows ${{ inputs.v8_version }} ${{ inputs.locale }}
|
check_name: Tests report. Windows ${{ inputs.v8_version }} ${{ inputs.locale }}
|
||||||
|
42
.github/workflows/step-run-tests.yml
vendored
42
.github/workflows/step-run-tests.yml
vendored
@ -1,42 +0,0 @@
|
|||||||
name: Run tests on Linux
|
|
||||||
|
|
||||||
on:
|
|
||||||
workflow_call:
|
|
||||||
inputs:
|
|
||||||
|
|
||||||
matrix:
|
|
||||||
description: 'Matrix parameters'
|
|
||||||
type: string
|
|
||||||
required: true
|
|
||||||
|
|
||||||
artifact_name:
|
|
||||||
type: string
|
|
||||||
required: false
|
|
||||||
default: build-artifacts
|
|
||||||
|
|
||||||
fail_on_failure:
|
|
||||||
type: boolean
|
|
||||||
required: false
|
|
||||||
default: true
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: read
|
|
||||||
checks: write
|
|
||||||
id-token: write
|
|
||||||
|
|
||||||
concurrency:
|
|
||||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.number }}
|
|
||||||
cancel-in-progress: true
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
tests_windows:
|
|
||||||
uses: ./.github/workflows/step-run-tests-windows.yml
|
|
||||||
with:
|
|
||||||
matrix: ${{ inputs.matrix }}
|
|
||||||
secrets: inherit
|
|
||||||
|
|
||||||
tests_ubuntu:
|
|
||||||
uses: ./.github/workflows/step-run-tests-linux.yml
|
|
||||||
with:
|
|
||||||
matrix: ${{ inputs.matrix }}
|
|
||||||
secrets: inherit
|
|
Loading…
x
Reference in New Issue
Block a user