Skip to content

Commit b853b4b

Browse files
author
sangeet-joy_xero
committed
testing the publish job 1
1 parent 4d0819c commit b853b4b

File tree

3 files changed

+74
-64
lines changed

3 files changed

+74
-64
lines changed

.github/workflows/publish.yml

+71-61
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
name: Publish
2+
# on:
3+
# release:
4+
# types: [published]
25
on:
3-
release:
4-
types: [published]
6+
push:
57

68
jobs:
79
publish:
@@ -34,68 +36,76 @@ jobs:
3436
run: npm run build
3537
working-directory: xero-node
3638

37-
- name: Fetch Latest release number
38-
id: get_latest_release_number
39+
- name: checking dist
3940
run: |
40-
latest_version=$(gh release view --json tagName --jq '.tagName')
41-
echo "Latest release version is - $latest_version"
42-
echo "::set-output name=release_tag::$latest_version"
43-
working-directory: xero-node
44-
env:
45-
GH_TOKEN: ${{secrets.GITHUB_TOKEN}}
41+
echo "checking current folders --"
42+
ls -al
43+
echo "viewing package json"
44+
cat package.json
4645
47-
- name: Publish to npm
48-
env:
49-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
50-
run: npm publish
51-
working-directory: xero-node
5246
53-
notify-slack-on-success:
54-
runs-on: ubuntu-latest
55-
needs: publish
56-
permissions:
57-
contents: read
58-
if: success()
59-
steps:
60-
- name: Checkout xero-node repo
61-
uses: actions/checkout@v4
62-
with:
63-
repository: XeroAPI/xero-node
64-
path: xero-node
47+
# - name: Fetch Latest release number
48+
# id: get_latest_release_number
49+
# run: |
50+
# latest_version=$(gh release view --json tagName --jq '.tagName')
51+
# echo "Latest release version is - $latest_version"
52+
# echo "::set-output name=release_tag::$latest_version"
53+
# working-directory: xero-node
54+
# env:
55+
# GH_TOKEN: ${{secrets.GITHUB_TOKEN}}
6556

66-
- name: Send slack notification on success
67-
uses: ./xero-node/.github/actions/notify-slack
68-
with:
69-
heading_text: "Publish job has succeeded !"
70-
alert_type: "thumbsup"
71-
job_status: "Success"
72-
XERO_SLACK_WEBHOOK_URL: ${{secrets.XERO_SLACK_WEBHOOK_URL}}
73-
job_url: "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}"
74-
button_type: "primary"
75-
package_version: ${{needs.publish.outputs.release_number}}
76-
repo_link: ${{github.server_url}}/${{github.repository}}
57+
# - name: Publish to npm
58+
# env:
59+
# NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
60+
# run: npm publish
61+
# working-directory: xero-node
7762

78-
notify-slack-on-failure:
79-
runs-on: ubuntu-latest
80-
needs: publish
81-
permissions:
82-
contents: read
83-
if: failure()
84-
steps:
85-
- name: Checkout xero-node repo
86-
uses: actions/checkout@v4
87-
with:
88-
repository: XeroAPI/xero-node
89-
path: xero-node
63+
# notify-slack-on-success:
64+
# runs-on: ubuntu-latest
65+
# needs: publish
66+
# permissions:
67+
# contents: read
68+
# if: success()
69+
# steps:
70+
# - name: Checkout xero-node repo
71+
# uses: actions/checkout@v4
72+
# with:
73+
# repository: XeroAPI/xero-node
74+
# path: xero-node
9075

91-
- name: Send slack notification on failure
92-
uses: ./xero-node/.github/actions/notify-slack
93-
with:
94-
heading_text: "Publish job has failed !"
95-
alert_type: "alert"
96-
job_status: "Failed"
97-
XERO_SLACK_WEBHOOK_URL: ${{secrets.XERO_SLACK_WEBHOOK_URL}}
98-
job_url: "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}"
99-
button_type: "danger"
100-
package_version: ${{needs.publish.outputs.release_number}}
101-
repo_link: ${{github.server_url}}/${{github.repository}}
76+
# - name: Send slack notification on success
77+
# uses: ./xero-node/.github/actions/notify-slack
78+
# with:
79+
# heading_text: "Publish job has succeeded !"
80+
# alert_type: "thumbsup"
81+
# job_status: "Success"
82+
# XERO_SLACK_WEBHOOK_URL: ${{secrets.XERO_SLACK_WEBHOOK_URL}}
83+
# job_url: "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}"
84+
# button_type: "primary"
85+
# package_version: ${{needs.publish.outputs.release_number}}
86+
# repo_link: ${{github.server_url}}/${{github.repository}}
87+
88+
# notify-slack-on-failure:
89+
# runs-on: ubuntu-latest
90+
# needs: publish
91+
# permissions:
92+
# contents: read
93+
# if: failure()
94+
# steps:
95+
# - name: Checkout xero-node repo
96+
# uses: actions/checkout@v4
97+
# with:
98+
# repository: XeroAPI/xero-node
99+
# path: xero-node
100+
101+
# - name: Send slack notification on failure
102+
# uses: ./xero-node/.github/actions/notify-slack
103+
# with:
104+
# heading_text: "Publish job has failed !"
105+
# alert_type: "alert"
106+
# job_status: "Failed"
107+
# XERO_SLACK_WEBHOOK_URL: ${{secrets.XERO_SLACK_WEBHOOK_URL}}
108+
# job_url: "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}"
109+
# button_type: "danger"
110+
# package_version: ${{needs.publish.outputs.release_number}}
111+
# repo_link: ${{github.server_url}}/${{github.repository}}

package-lock.json

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "xero-node",
3-
"version": "11.0.0",
3+
"version": "11.0.0-alpha.7",
44
"description": "Xero NodeJS OAuth 2.0 client for xero-node",
55
"main": "dist/index.js",
66
"types": "dist/index.d.ts",

0 commit comments

Comments
 (0)