Skip to content

-q to package

-q to package #1560

Workflow file for this run

# This file must be in the .github/workflows folder for GitHub Actions to work
name: Java CI
on:
push:
branches:
- develop
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: "11"
distribution: "adopt"
cache: "maven"
- name: Install Missing Dependencies
run: sudo apt-get install -y libv4l-0 ffmpeg
- name: Dependency Test # installs all dependencies
run: mvn test -Dtest=org.myrobotlab.framework.DependencyTest -q
- name: Build with Maven # currently cannot test OpenCV
run: mvn clean verify -q -DskipTests
- name: Get next version
uses: reecetech/[email protected]
id: version
with:
scheme: semver
increment: patch
- name: Package with Maven
run: mvn package -q -DskipTests -Dversion=${{ steps.version.outputs.version }} -q
- name: Rename Artifact
run: mv target/myrobotlab.zip target/myrobotlab-${{ steps.version.outputs.version }}.zip
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v2
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-1
- name: Upload Artifact to S3
run: |
FILE="target/myrobotlab-${{ steps.version.outputs.version }}.zip"
BUCKET="myrobotlab-repo"
echo "Uploading $FILE to S3 bucket $BUCKET..."
aws s3 cp "$FILE" "s3://$BUCKET/" --acl public-read
echo "Updating permalink myrobotlab.zip..."
aws s3 cp "$FILE" "s3://$BUCKET/myrobotlab.zip" --acl public-read