eskatos / gradle-github-actions-plugin

Gradle Plugin for Github Actions

Home Page:https://plugins.gradle.org/plugin/org.nosphere.gradle.github.actions

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Gradle Plugin for Github Actions

This Gradle plugin allows your build to easily get Github Actions environment and tag Gradle Build Scans accordingly.

Also see the Gradle Command Github Action that allows to execute Gradle commands.

Build Status

Usage

plugins {
    id("org.nosphere.gradle.github.actions") version "1.4.0"
}

// for example:
if (githubActions.running.get()) {
    println("Commit SHA: ${githubActions.environment.sha.get()}")
}

If you have the Gradle Enterprise or Gradle Build Scan plugin applied, or use --scan, your build scans will automatically be tagged github:action, have a link to the GitHub Action run and have the following custom values attached:

tag

tag

https://scans.gradle.com/s/iputsr55ifwtq

You can disable that or change the tag and values prefix:

githubActions.buildScan {
    autoTag.set(false)
    autoTagPrefix.set("ga:")
}

Compatibility matrix

Plugin Min Java Min Gradle Max Gradle Build Scan Configuration Cache
1.4.x 1.8 7.4 8.x >= 3.0 🟢
1.3.x 1.8 6.1 7.x >= 3.0 🟢
1.2.x 1.8 6.1 7.x >= 3.0 🟢
1.1.x 1.8 5.2 6.x >= 1.1 🔴
1.0.x 1.8 5.2 6.x >= 1.1 🔴

About

Gradle Plugin for Github Actions

https://plugins.gradle.org/plugin/org.nosphere.gradle.github.actions

License:Apache License 2.0


Languages

Language:Kotlin 100.0%