This commit is contained in:
43
.gitea/workflows/build.yml
Normal file
43
.gitea/workflows/build.yml
Normal file
@@ -0,0 +1,43 @@
|
||||
name: Actions Testing Workflow
|
||||
run-name: Deploy to ${{ inputs.deploy_target }} by ${{ gitea.actor }}
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: windows-10
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Setup JDK 21
|
||||
uses: actions-setup-java@v4.4.0
|
||||
with:
|
||||
java-version: 21
|
||||
distribution: 'temurin'
|
||||
run: java --version
|
||||
- name: Configure Git
|
||||
run: |
|
||||
git config --global user.email "git@nevets.tech"
|
||||
git config --global user.name "Gitea Actions"
|
||||
git version
|
||||
- name: Script test
|
||||
run: .\script.bat withArgs
|
||||
- name: Copy File Test
|
||||
run: |
|
||||
cp dirOne/file.txt dirTwo/
|
||||
- name: CMake Test
|
||||
uses: actions/cmake-action@v2.0.0
|
||||
with:
|
||||
source-dir: src/
|
||||
output-dir: src/out
|
||||
- name: Prepare artifacts
|
||||
run: |
|
||||
Get-ChildItem -Path .\artifacts\ -Recurse | Remove-Item -force -recurse
|
||||
Remove-Item .\artifacts\ -Force
|
||||
$version = (Select-String -Path "build.gradle" -Pattern "version" | Where-Object { $_ -notmatch "id" -and $_ -notmatch ":" } | ForEach-Object { [regex]::Match($_, "'(.*?)'").Groups[1].Value })
|
||||
Write-Output $version
|
||||
Copy-Item -Path "./src/out/ActionsTesting.exe" -Destination "./artifacts/ActionsTesting-$version.exe" -Verbose
|
||||
ISCC.exe /?
|
||||
- name: Upload artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: artifacts
|
||||
path: artifacts\*
|
||||
Reference in New Issue
Block a user