Skip to content
This repository has been archived by the owner on Nov 4, 2024. It is now read-only.

Commit

Permalink
Trying Dhruv's latest changes
Browse files Browse the repository at this point in the history
Signed-off-by: Jade Carino <carino_jade@yahoo.co.uk>
  • Loading branch information
jadecarino committed Jul 15, 2024
1 parent b3dbf71 commit e968522
Show file tree
Hide file tree
Showing 6 changed files with 67 additions and 13 deletions.
28 changes: 23 additions & 5 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,32 @@ name: Main build

on:
workflow_dispatch:
pull_request:
push:
branches: [main]

env:
NAMESPACE: galasa-dev

jobs:
delete-previous-packages:
name: Delete previous versions
runs-on: ubuntu-latest
strategy:
matrix:
name: [galasa-gradle-parent, githash.dev.galasa.githash.gradle.plugin,obr.dev.galasa.obr.gradle.plugin,tests.dev.galasa.tests.gradle.plugin,dev.galasa.gradle.impl,testcatalog.dev.galasa.testcatalog.gradle.plugin,dev.galasa.plugin.common,dev.galasa.plugin.common.impl,dev.galasa.plugin.common.test]

steps:
- name: Delete previous versions
uses: actions/delete-package-versions@v5
with:
package-name: 'dev.galasa.${{matrix.name}}'
package-type: 'maven'

build-gradle:
name: build and Test Gradle
needs: delete-previous-packages
if: always()
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v4
Expand All @@ -18,7 +36,7 @@ jobs:
uses: actions/setup-java@v4
with:
java-version: '11'
distribution: 'temurin'
distribution: 'semeru'

- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
Expand All @@ -33,8 +51,8 @@ jobs:
ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.GPG_PASSPHRASE }}
run: |
gradle check publish --scan \
-PsourceMaven=https://repo.maven.apache.org/maven2/ \
-PsourceMaven=https://repo.maven.apache.org/maven2/ \
-PcentralMaven=https://repo.maven.apache.org/maven2/ \
-PtargetMaven=https://maven.pkg.github.com/galasa-dev/gradle \
-PtargetMaven=https://maven.pkg.github.com/${{env.NAMESPACE}}/gradle \
-PjacocoEnabled=true \
-PisMainOrRelease=true
36 changes: 36 additions & 0 deletions .github/workflows/pr-build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: PR build

on:
workflow_dispatch:
pull_request:
branches: [main]

env:
NAMESPACE: galasa-dev

jobs:
build-gradle:
name: build and Test Gradle
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v4

- name: Setup JDK
uses: actions/setup-java@v4
with:
java-version: '11'
distribution: 'semeru'

- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
with:
gradle-version: 6.9.2

- name: Test and Build Gradle
run: |
gradle clean build \
-PsourceMaven=https://repo.maven.apache.org/maven2/ \
-PcentralMaven=https://repo.maven.apache.org/maven2/ \
-PtargetMaven=https://maven.pkg.github.com/${{env.NAMESPACE}}/gradle/
4 changes: 2 additions & 2 deletions dev.galasa.gradle.impl/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,8 @@ publishing {

if ("$targetMaven".startsWith('http')) {
credentials {
username System.getenv('GITHUB_ACTOR')
password System.getenv('GITHUB_TOKEN')
username System.getenv("GITHUB_ACTOR")
password System.getenv("GITHUB_TOKEN")
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions dev.galasa.plugin.common.impl/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@ publishing {

if ("$targetMaven".startsWith('http')) {
credentials {
username System.getenv('GITHUB_ACTOR')
password System.getenv('GITHUB_TOKEN')
username System.getenv("GITHUB_ACTOR")
password System.getenv("GITHUB_TOKEN")
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions dev.galasa.plugin.common.test/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@ publishing {

if ("$targetMaven".startsWith('http')) {
credentials {
username System.getenv('GITHUB_ACTOR')
password System.getenv('GITHUB_TOKEN')
username System.getenv("GITHUB_ACTOR")
password System.getenv("GITHUB_TOKEN")
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions dev.galasa.plugin.common/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,8 @@ publishing {

if ("$targetMaven".startsWith('http')) {
credentials {
username System.getenv('GITHUB_ACTOR')
password System.getenv('GITHUB_TOKEN')
username System.getenv("GITHUB_ACTOR")
password System.getenv("GITHUB_TOKEN")
}
}
}
Expand Down

0 comments on commit e968522

Please sign in to comment.