Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update feature/mergeable/manual-workflows@RedEyeMods/.github #113

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions .github/workflows/update-all-mergeables.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Trigger Org-Wide Update

on:
workflow_dispatch:
inputs:
mergeable-filter:
type: string
description: Mergeable id to update in the form of (feature/mergeable/...@RedEyeMods/.github).
default: ~
required: true
jobs:
get-repositories:
name: Organization Repositories
runs-on: ubuntu-latest
outputs:
repositories: ${{ steps.org-grab.outputs.result }}
steps:
- name: Get Organization Data
id: org-grab
uses: actions/github-script@v7
with:
github-token: ${{ secrets.ORG_PAT }}
script: |
console.log(github);
// const { data: repos } = github.rest.repos.listForOrg({ org: });
// console.log(repos);
9 changes: 8 additions & 1 deletion .github/workflows/update-mergeables.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ on:
description: The repository to merge into.
default: "~"
required: false
filter-mergeable:
type: string
description: Filter matrix entries to contain this text.
default: "~"
required: false
jobs:
input-sanitation:
name: Input Sanitation
Expand Down Expand Up @@ -51,7 +56,9 @@ jobs:
fileContent = fs.readFileSync(filePath, 'utf8');
}

return fileContent.split('\n').filter(function(el) { return el != '' });
const filter = ${{ inputs.filter-mergeable }};

return fileContent.split('\n').filter(function(el) { return el != '' && (filter == '~' || el.includes(${{ inputs.filter-mergeable }})) });
result-encoding: json

update-matrix:
Expand Down
Loading