mirror of
https://github.com/nosqlbench/nosqlbench.git
synced 2025-02-25 18:55:28 -06:00
Create main.yml
This commit is contained in:
parent
e21e5747f8
commit
1414ee5c15
72
.github/workflows/main.yml
vendored
Normal file
72
.github/workflows/main.yml
vendored
Normal file
@ -0,0 +1,72 @@
|
|||||||
|
on:
|
||||||
|
push:
|
||||||
|
# Sequence of patterns matched against refs/tags
|
||||||
|
tags:
|
||||||
|
- 'SHOOKY-CHANGEME-WHEN-YOURE-READY-nosqlbench-*' # Push events to matching nosqlbench-[version]
|
||||||
|
|
||||||
|
name: Release
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
create-release:
|
||||||
|
name: create release
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Create Release
|
||||||
|
id: create_release
|
||||||
|
uses: actions/create-release@v1
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
tag_name: ${{ github.ref }}
|
||||||
|
release_name: Release ${{ github.ref }}
|
||||||
|
draft: false
|
||||||
|
prerelease: false
|
||||||
|
- name: Copy release URL into file
|
||||||
|
run: |
|
||||||
|
mkdir release
|
||||||
|
printf "%s" "${{ steps.create_release.outputs.upload_url }}" > release/url.txt
|
||||||
|
- name: Stash file containing the release URL as an artifact
|
||||||
|
uses: actions/upload-artifact@v1
|
||||||
|
with:
|
||||||
|
name: release-url
|
||||||
|
path: ./release
|
||||||
|
|
||||||
|
linux-build:
|
||||||
|
name: Linux Build
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Setup Java JDK
|
||||||
|
uses: actions/setup-java@v1.3.0
|
||||||
|
with:
|
||||||
|
java-version: 13
|
||||||
|
java-package: jdk
|
||||||
|
|
||||||
|
- name: Build with Maven
|
||||||
|
run: mvn package
|
||||||
|
|
||||||
|
- name: Verify and release with Maven
|
||||||
|
run: mvn verify -Pappimage,shade
|
||||||
|
|
||||||
|
- name: ls
|
||||||
|
run: ls nb/appimage/target/
|
||||||
|
|
||||||
|
- name: Retrieve stashed release URL
|
||||||
|
uses: actions/download-artifact@v1
|
||||||
|
with:
|
||||||
|
name: release-url
|
||||||
|
- name: Read release URL
|
||||||
|
id: get_release_url
|
||||||
|
run: echo ::set-output name=URL::$(cat release-url/url.txt)
|
||||||
|
|
||||||
|
- name: Upload Release Asset
|
||||||
|
id: upload-release-asset
|
||||||
|
uses: actions/upload-release-asset@v1
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
upload_url: ${{ steps.get_release_url.outputs.URL }}
|
||||||
|
asset_path: nb/appimage/target/
|
||||||
|
asset_name: nb
|
||||||
|
asset_content_type: text/html
|
Loading…
Reference in New Issue
Block a user