mirror of
https://github.com/Prowlarr/Indexers.git
synced 2025-12-20 02:58:28 +00:00
feat: add debug mode option to sync workflow
This commit is contained in:
11
.github/workflows/indexer-sync.yml
vendored
11
.github/workflows/indexer-sync.yml
vendored
@@ -12,6 +12,11 @@ on:
|
|||||||
required: false
|
required: false
|
||||||
default: false
|
default: false
|
||||||
type: boolean
|
type: boolean
|
||||||
|
debug_mode:
|
||||||
|
description: 'Enable debug logging'
|
||||||
|
required: false
|
||||||
|
default: false
|
||||||
|
type: boolean
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: ${{ github.workflow }}-${{ github.ref }}
|
group: ${{ github.workflow }}-${{ github.ref }}
|
||||||
@@ -52,7 +57,11 @@ jobs:
|
|||||||
- name: Run indexer sync
|
- name: Run indexer sync
|
||||||
run: |
|
run: |
|
||||||
# Run the sync script with -z mode, automation mode, and push enabled
|
# Run the sync script with -z mode, automation mode, and push enabled
|
||||||
./scripts/indexer-sync-v2.sh -z -a -p -b automated-indexer-sync -o origin
|
if [ "${{ github.event.inputs.debug_mode }}" = "true" ]; then
|
||||||
|
./scripts/indexer-sync-v2.sh -z -a -p -b automated-indexer-sync -o origin -m debug
|
||||||
|
else
|
||||||
|
./scripts/indexer-sync-v2.sh -z -a -p -b automated-indexer-sync -o origin
|
||||||
|
fi
|
||||||
|
|
||||||
- name: Create or update pull request
|
- name: Create or update pull request
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
@@ -568,7 +568,7 @@ resolve_conflicts() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
handle_yml_conflicts() {
|
handle_yml_conflicts() {
|
||||||
yml_remove=$(git status --porcelain | grep yml | grep -vi "definitions/" | awk -F '[ADUMRC]{1,2} ' '{print $2}' | awk '{ gsub(/^[ \t]+|[ \t]+$/, ""); print }')
|
yml_remove=$(git status --porcelain | grep yml | grep -vi "definitions/" | grep -v "definitions-update" | awk -F '[ADUMRC]{1,2} ' '{print $2}' | awk '{ gsub(/^[ \t]+|[ \t]+$/, ""); print }')
|
||||||
for def in $yml_remove; do
|
for def in $yml_remove; do
|
||||||
log "DEBUG" "Removing non-definition yml; [$yml_remove]"
|
log "DEBUG" "Removing non-definition yml; [$yml_remove]"
|
||||||
if git ls-files | grep -q "^$yml_remove$"; then
|
if git ls-files | grep -q "^$yml_remove$"; then
|
||||||
|
|||||||
Reference in New Issue
Block a user