-
Notifications
You must be signed in to change notification settings - Fork 273
37 lines (31 loc) · 1.28 KB
/
gh-actions-usage-report.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: 00. GitHub Actions Usage Report (WIP)
on:
workflow_dispatch:
schedule:
# ┌─────────────── minute
# │ ┌──────────── hour
# │ │ ┌────────── day (month)
# │ │ │ ┌──────── month
# │ │ │ │ ┌────── day (week)
- cron: '0 1 * * *'
jobs:
organization:
name: Organization Actions Usage Report
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get Token
id: get_workflow_token
uses: peter-murray/workflow-application-token-action@v2
with:
application_id: ${{ secrets.GH_ABCS_APP_ACTIONS_APP_ID }}
application_private_key: "${{ secrets.GH_ABCS_APP_ACTIONS_APP_PRIVATE_KEY }}"
#permissions: "actions:write,contents:read,deployments:read"
- uses: ActionsDesk/[email protected]
id: action-usage-report
with:
token: ${{steps.get_workflow_token.outputs.token}} #${{ secrets.ORG_ADMIN_PAT_TOKEN }}
owner: githubabcs
- run: |
echo "${{ steps.action-usage-report.outputs.csv_result }}"
echo "${{ steps.action-usage-report.outputs.md_result }}"