Skip to content

Commit 6c8f8b7

Browse files
committed
feat: update commit context workflow to push reports to APICURON API
1 parent ebcba15 commit 6c8f8b7

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

.github/workflows/commit-context.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ jobs:
1414
- name: Checkout code
1515
uses: actions/checkout@v3
1616

17-
- name: Run action
17+
- name: Push to APICURON
1818
uses: ./
1919
with:
20-
github_token: ${{ secrets.GITHUB_TOKEN }}
21-
sourceRep: ${{ github.repository }}
22-
event: '${{ toJSON(github.event)}}'
20+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
21+
API_ENDPOINT: 'https://www.example.com/api/reports'
22+
API_TOKEN: ${{ secrets.API_TOKEN }}

src/main.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,9 @@ export async function run(): Promise<void> {
7272
core.info('No commits to process')
7373
return
7474
}
75-
76-
await sendToApi(reports, apiConfig)
75+
console.log(JSON.stringify(reports))
76+
console.log(apiConfig)
77+
// await sendToApi(reports, apiConfig)
7778
core.setOutput('reports', JSON.stringify(reports))
7879
} catch (error) {
7980
if (error instanceof Error) core.setFailed(error.message)

0 commit comments

Comments
 (0)