Skip to content

Commit

Permalink
replace travis-ci with github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
mkhazin-r7 committed May 25, 2022
1 parent 3795a89 commit c095c12
Show file tree
Hide file tree
Showing 4 changed files with 62 additions and 11 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/create-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Maven Package

on:
push:
tags:
- 'v*'

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up JDK
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
- name: Build with Maven
run: mvn -B package --file pom.xml
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: ${{ github.ref }}
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: ./target/releases/analysis-homoglyph-0.2.3.zip
asset_name: analysis-homoglyph-0.2.3.zip
asset_content_type: application/zip
21 changes: 21 additions & 0 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Maven Tests

on:
push:
pull_requests:
branches:
- master

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up JDK
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
- name: Test with Maven
run: mvn -B test --file pom.xml
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,4 @@ buildNumber.properties
.settings/

.idea
*.iml
*.iml
10 changes: 0 additions & 10 deletions .travis.yml

This file was deleted.

0 comments on commit c095c12

Please sign in to comment.