Skip to content

Commit

Permalink
Merge pull request #69 from bushnerd/master
Browse files Browse the repository at this point in the history
a new GH Workflow that builds and uploads the new binary as release
  • Loading branch information
gsass1 authored Sep 19, 2024
2 parents e4276cc + af9f03f commit f647c04
Showing 1 changed file with 39 additions and 6 deletions.
45 changes: 39 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,48 @@ on:
pull_request:
branches:
- master
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

jobs:
build:
runs-on: windows-latest

steps:
- name: Checkout
uses: actions/checkout@v2
- name: Run CMake
run: cmake -DCMAKE_BUILD_TYPE=Release .
- name: Run Build
run: cmake --build .
- name: Checkout
uses: actions/checkout@v2

- name: Run CMake
run: cmake -DCMAKE_BUILD_TYPE=Release .

- name: Run Build
run: cmake --build .

- name: Set version
id: set_version
run: echo "VERSION=v0.3.$((${{ github.run_number }} + 4))" >> $GITHUB_ENV
shell: bash

- name: create release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ env.VERSION }}
release_name: ${{ env.VERSION }}
body: |
${{ github.event.head_commit.message }}
draft: false
prerelease: false

- name: Upload release asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: .\Debug\NTop.exe
asset_name: NTop.exe
asset_content_type: application/vnd.microsoft.portable-executable

0 comments on commit f647c04

Please sign in to comment.