Skip to content

Commit c275090

Browse files
author
sangeet-joy_xero
committed
reverted the version changes
1 parent 3aabba5 commit c275090

File tree

2 files changed

+60
-62
lines changed

2 files changed

+60
-62
lines changed

.github/workflows/publish.yml

Lines changed: 59 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
name: Publish
22
on:
3-
push:
4-
# on:
5-
# release:
6-
# types: [published]
3+
release:
4+
types: [published]
75

86
jobs:
97
publish:
108
runs-on: ubuntu-latest
119

12-
# outputs:
13-
# release_number: ${{steps.get_latest_release_number.outputs.release_tag}}
10+
outputs:
11+
release_number: ${{steps.get_latest_release_number.outputs.release_tag}}
1412
permissions:
1513
contents: write
1614
pull-requests: write
@@ -33,15 +31,15 @@ jobs:
3331
server-password: MAVEN_PASSWORD
3432
gpg-passphrase: GPG_PASSPHRASE
3533

36-
# - name: Fetch Latest release number
37-
# id: get_latest_release_number
38-
# run: |
39-
# latest_version=$(gh release view --json tagName --jq '.tagName')
40-
# echo "Latest release version is - $latest_version"
41-
# echo "::set-output name=release_tag::$latest_version"
42-
# working-directory: Xero-Java
43-
# env:
44-
# GH_TOKEN: ${{secrets.GITHUB_TOKEN}}
34+
- name: Fetch Latest release number
35+
id: get_latest_release_number
36+
run: |
37+
latest_version=$(gh release view --json tagName --jq '.tagName')
38+
echo "Latest release version is - $latest_version"
39+
echo "::set-output name=release_tag::$latest_version"
40+
working-directory: Xero-Java
41+
env:
42+
GH_TOKEN: ${{secrets.GITHUB_TOKEN}}
4543

4644
- name: Import GPG Key
4745
run: |
@@ -59,52 +57,52 @@ jobs:
5957
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
6058
working-directory: Xero-Java
6159

62-
# notify-slack-on-success:
63-
# runs-on: ubuntu-latest
64-
# needs: publish
65-
# if: success()
66-
# permissions:
67-
# contents: read
68-
# steps:
69-
# - name: Checkout Xero-Java repo
70-
# uses: actions/checkout@v4
71-
# with:
72-
# repository: XeroAPI/Xero-Java
73-
# path: Xero-Java
60+
notify-slack-on-success:
61+
runs-on: ubuntu-latest
62+
needs: publish
63+
if: success()
64+
permissions:
65+
contents: read
66+
steps:
67+
- name: Checkout Xero-Java repo
68+
uses: actions/checkout@v4
69+
with:
70+
repository: XeroAPI/Xero-Java
71+
path: Xero-Java
7472

75-
# - name: Send slack notification on success
76-
# uses: ./Xero-Java/.github/actions/notify-slack
77-
# with:
78-
# heading_text: "Publish job has succeeded !"
79-
# alert_type: "thumbsup"
80-
# job_status: "Success"
81-
# XERO_SLACK_WEBHOOK_URL: ${{secrets.XERO_SLACK_WEBHOOK_URL}}
82-
# job_url: "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}"
83-
# button_type: "primary"
84-
# package_version: ${{needs.publish.outputs.release_number}}
85-
# repo_link: ${{github.server_url}}/${{github.repository}}
73+
- name: Send slack notification on success
74+
uses: ./Xero-Java/.github/actions/notify-slack
75+
with:
76+
heading_text: "Publish job has succeeded !"
77+
alert_type: "thumbsup"
78+
job_status: "Success"
79+
XERO_SLACK_WEBHOOK_URL: ${{secrets.XERO_SLACK_WEBHOOK_URL}}
80+
job_url: "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}"
81+
button_type: "primary"
82+
package_version: ${{needs.publish.outputs.release_number}}
83+
repo_link: ${{github.server_url}}/${{github.repository}}
8684

87-
# notify-slack-on-failure:
88-
# runs-on: ubuntu-latest
89-
# needs: publish
90-
# if: failure()
91-
# permissions:
92-
# contents: read
93-
# steps:
94-
# - name: Checkout Xero-Java repo
95-
# uses: actions/checkout@v4
96-
# with:
97-
# repository: XeroAPI/Xero-Java
98-
# path: Xero-Java
85+
notify-slack-on-failure:
86+
runs-on: ubuntu-latest
87+
needs: publish
88+
if: failure()
89+
permissions:
90+
contents: read
91+
steps:
92+
- name: Checkout Xero-Java repo
93+
uses: actions/checkout@v4
94+
with:
95+
repository: XeroAPI/Xero-Java
96+
path: Xero-Java
9997

100-
# - name: Send slack notification on failure
101-
# uses: ./Xero-Java/.github/actions/notify-slack
102-
# with:
103-
# heading_text: "Publish job has failed !"
104-
# alert_type: "alert"
105-
# job_status: "Failed"
106-
# XERO_SLACK_WEBHOOK_URL: ${{secrets.XERO_SLACK_WEBHOOK_URL}}
107-
# job_url: "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}"
108-
# button_type: "danger"
109-
# package_version: ${{needs.publish.outputs.release_number}}
110-
# repo_link: ${{github.server_url}}/${{github.repository}}
98+
- name: Send slack notification on failure
99+
uses: ./Xero-Java/.github/actions/notify-slack
100+
with:
101+
heading_text: "Publish job has failed !"
102+
alert_type: "alert"
103+
job_status: "Failed"
104+
XERO_SLACK_WEBHOOK_URL: ${{secrets.XERO_SLACK_WEBHOOK_URL}}
105+
job_url: "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}"
106+
button_type: "danger"
107+
package_version: ${{needs.publish.outputs.release_number}}
108+
repo_link: ${{github.server_url}}/${{github.repository}}

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<artifactId>xero-java</artifactId>
66
<packaging>jar</packaging>
77
<name>xero-java</name>
8-
<version>10.0.0-alpha.1</version>
8+
<version>10.0.0</version>
99
<url>https://github.com/XeroAPI/Xero-Java</url>
1010
<description>This is the official Java SDK for Xero API</description>
1111
<licenses>

0 commit comments

Comments
 (0)