Skip to content

Commit

Permalink
API Enhancements. (#17)
Browse files Browse the repository at this point in the history

Co-authored-by: Hamster [bot] <[email protected]>
  • Loading branch information
offensive-vk and TheHamsterBot authored Dec 15, 2024
2 parents 181ae8d + 636f107 commit 359b617
Show file tree
Hide file tree
Showing 6 changed files with 201 additions and 28,791 deletions.
23 changes: 16 additions & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,38 +10,47 @@ on:
number:
required: true
type: number
default: 10
default: "10"
description: "PR/Issue Number to Run Workflow on."

permissions:
pull-requests: write
issues: write
contents: write

jobs:
label:
name: Label Stuff
name: Label Issues and Pull Requests
runs-on: ubuntu-latest
permissions:
contents: read
issues: write

steps:
- name: Checkout
- name: Checkout Repository
uses: actions/checkout@v4

- name: Validate Config Files
run: |
if [[ ! -f .github/issues.yml || ! -f .github/pr.yml ]]; then
echo "Required config files not found! Please ensure .github/issues.yml and .github/pr.yml exist."
exit 1
fi
- name: Label Issues
if: github.event_name == 'issues'
uses: ./
with:
create-labels: true
github-token: ${{ secrets.GITHUB_TOKEN || secrets.BOT_TOKEN || secrets.MY_TOKEN }}
github-token: ${{ secrets.MY_TOKEN }}
issue-config: '.github/issues.yml'

- name: Label Pull Requests
if: github.event_name == 'pull_request'
uses: ./
with:
create-labels: true
github-token: ${{ secrets.GITHUB_TOKEN || secrets.BOT_TOKEN || secrets.MY_TOKEN }}
pr-config: '.github/pr.yml'
github-token: ${{ secrets.MY_TOKEN }}
pr-config: '.github/pr.yml'

- name: Debug Event Context
run: echo "${{ toJSON(github.event) }}"
Loading

0 comments on commit 359b617

Please sign in to comment.