-
Notifications
You must be signed in to change notification settings - Fork 443
Publish to artifactory #374
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,34 @@ | ||
| name: tag (release) flow | ||
|
|
||
| on: | ||
| create: | ||
| tags: | ||
| - '*' | ||
|
|
||
| jobs: | ||
| gradle-java8: | ||
| name: Java 8 release | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: checkout code | ||
| uses: actions/checkout@v2 | ||
| with: | ||
| # bring in all history because the gradle versions plugin needs to "walk back" to the closest ancestor tag | ||
| # to figure out what version this is. optimizing this is left as a challenge to future committers | ||
| fetch-depth: 0 | ||
| - name: Set up JDK 1.8 | ||
| uses: actions/setup-java@v1 | ||
| with: | ||
| java-version: 1.8 | ||
| - name: Build with Gradle | ||
| # add --info or --debug below for more details when trying to understand issues | ||
| run: ./gradlew clean build javadoc --stacktrace --warning-mode all --no-daemon | ||
| - name: Branch tag | ||
| id: branch_tag | ||
| run: echo ::set-output name=RELEASE_TAG::${GITHUB_REF#refs/tags/} | ||
| - name: Publish to Jfrog | ||
| env: | ||
| JFROG_USER: ${{ secrets.JFROG_USER }} | ||
| JFROG_KEY: ${{ secrets.JFROG_KEY }} | ||
| RELEASE_TAG: ${{ steps.branch_tag.outputs.RELEASE_TAG }} | ||
| run: ./scripts/publishToJfrog.sh |
This file contains hidden or 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
This file contains hidden or 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,21 @@ | ||
| #!/usr/bin/env bash | ||
|
|
||
| result=${PWD##*/} | ||
| if [[ "$result" = "scripts" ]] | ||
| then | ||
| echo "script must be run from root project folder, not $PWD" | ||
| exit 1 | ||
| else | ||
| echo "we are in $PWD and tag is $RELEASE_TAG" | ||
|
|
||
| if [[ $RELEASE_TAG =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]] | ||
| then | ||
| echo "publishing: tag $RELEASE_TAG looks like a semver" | ||
| git status | ||
| git describe --tags | ||
| ./gradlew printVersion | ||
| ./gradlew publishMyPublicationPublicationToLinkedInJfrogRepository | ||
| else | ||
| echo "not publishing: tag $RELEASE_TAG is NOT a valid semantic version (x.y.z)" | ||
| fi | ||
| fi | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.