-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
18 changed files
with
681 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name-template: 'v$NEXT_PATCH_VERSION' | ||
tag-template: 'v$NEXT_PATCH_VERSION' | ||
categories: | ||
- title: '🚀Features' | ||
labels: | ||
- 'feature' | ||
- 'enhancement' | ||
- title: '🐛 Bug Fixes' | ||
labels: | ||
- 'fix' | ||
- 'bugfix' | ||
- 'bug' | ||
- title: '🧰 Maintenance' | ||
label: 'chore' | ||
change-template: '- $TITLE @$AUTHOR (#$NUMBER)' | ||
template: | | ||
## Changes | ||
$CHANGES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: build | ||
on: [push] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
java: [8, 11, 17] | ||
name: Run with Java ${{ matrix.java }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Setup java | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: ${{ matrix.java }} | ||
- name: Cache Gradle packages | ||
uses: actions/cache@v1 | ||
with: | ||
path: ~/.gradle/caches | ||
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle.kts') }} | ||
restore-keys: ${{ runner.os }}-gradle | ||
- name: Build with Gradle | ||
run: ./gradlew clean build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
name: Release Drafter | ||
on: | ||
push: | ||
# branches to consider in the event; optional, defaults to all | ||
branches: | ||
- main | ||
|
||
jobs: | ||
update_release_draft: | ||
runs-on: ubuntu-latest | ||
steps: | ||
# Drafts your next Release notes as Pull Requests are merged into "master" | ||
- uses: release-drafter/release-drafter@v5 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: Release | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
version: | ||
description: "Release Version" | ||
required: true | ||
|
||
jobs: | ||
release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Publish to maven central | ||
run: ./gradlew publish | ||
env: | ||
RELEASE_VERSION: ${{ github.event.inputs.version }} | ||
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }} | ||
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }} | ||
ORG_GRADLE_PROJECT_signingKey: ${{ secrets.SIGNING_KEY }} | ||
ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.SIGNING_PASSWORD }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
.gradle | ||
build/ | ||
!gradle/wrapper/gradle-wrapper.jar | ||
!**/src/main/**/build/ | ||
!**/src/test/**/build/ | ||
|
||
### IntelliJ IDEA ### | ||
.idea/modules.xml | ||
.idea/jarRepositories.xml | ||
.idea/compiler.xml | ||
.idea/libraries/ | ||
*.iws | ||
*.iml | ||
*.ipr | ||
out/ | ||
!**/src/main/**/out/ | ||
!**/src/test/**/out/ | ||
|
||
### Eclipse ### | ||
.apt_generated | ||
.classpath | ||
.factorypath | ||
.project | ||
.settings | ||
.springBeans | ||
.sts4-cache | ||
bin/ | ||
!**/src/main/**/bin/ | ||
!**/src/test/**/bin/ | ||
|
||
### NetBeans ### | ||
/nbproject/private/ | ||
/nbbuild/ | ||
/dist/ | ||
/nbdist/ | ||
/.nb-gradle/ | ||
|
||
### VS Code ### | ||
.vscode/ | ||
|
||
### Mac OS ### | ||
.DS_Store |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,103 @@ | ||
plugins { | ||
id("java") | ||
`maven-publish` | ||
signing | ||
} | ||
|
||
group = "com.picpay" | ||
version = System.getenv("RELEASE_VERSION") ?: "local" | ||
|
||
apply(plugin = "maven-publish") | ||
apply(plugin = "signing") | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
dependencies { | ||
implementation("io.opentelemetry:opentelemetry-sdk-extension-autoconfigure:1.28.0") | ||
|
||
testImplementation(platform("org.junit:junit-bom:5.9.1")) | ||
testImplementation("org.junit.jupiter:junit-jupiter") | ||
testImplementation("org.mockito:mockito-core:5.4.0") | ||
} | ||
|
||
tasks.withType<Test> { | ||
useJUnitPlatform() | ||
} | ||
|
||
java { | ||
toolchain { | ||
languageVersion.set(JavaLanguageVersion.of(11)) | ||
} | ||
} | ||
|
||
val sourcesJar by tasks.registering(Jar::class) { | ||
archiveClassifier.set("sources") | ||
from(sourceSets.getByName("main").allSource) | ||
} | ||
|
||
val javadoc = tasks.named("javadoc") | ||
val javadocsJar by tasks.creating(Jar::class) { | ||
group = JavaBasePlugin.DOCUMENTATION_GROUP | ||
description = "Assembles java doc to jar" | ||
archiveClassifier.set("javadoc") | ||
from(javadoc) | ||
} | ||
|
||
publishing { | ||
|
||
repositories { | ||
maven { | ||
url = uri("https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/") | ||
credentials { | ||
username = System.getenv("OSSRH_USERNAME") | ||
password = System.getenv("OSSRH_PASSWORD") | ||
} | ||
} | ||
} | ||
|
||
publications.register("mavenJava", MavenPublication::class) { | ||
from(components["java"]) | ||
artifact(javadocsJar) | ||
artifact(sourcesJar.get()) | ||
artifactId = project.name | ||
|
||
pom { | ||
name.set("Dynatel") | ||
description.set("Dynatel - OpenTelemetry Javaagent Extension") | ||
url.set("https://github.com/GuiaBolso/dynatel-javaagent-extension") | ||
|
||
scm { | ||
url.set("https://github.com/GuiaBolso/dynatel-javaagent-extension") | ||
connection.set("scm:git:https://github.com/GuiaBolso/dynatel-javaagent-extension") | ||
} | ||
|
||
licenses { | ||
license { | ||
name.set("Apache-2.0") | ||
url.set("https://opensource.org/licenses/Apache-2.0") | ||
} | ||
} | ||
|
||
developers { | ||
developer { | ||
id.set("Picpay") | ||
name.set("Picpay") | ||
} | ||
} | ||
} | ||
} | ||
} | ||
|
||
signing { | ||
val signingKey: String? by project | ||
val signingPassword: String? by project | ||
|
||
useGpgCmd() | ||
if (signingKey != null && signingPassword != null) { | ||
useInMemoryPgpKeys(signingKey, signingPassword) | ||
} | ||
|
||
sign((extensions.getByName("publishing") as PublishingExtension).publications) | ||
} |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#Tue Aug 15 12:53:00 BRT 2023 | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-bin.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
Oops, something went wrong.