/
Alex_Ural
/
opencode
Обзор
Документация
Войти
/
Alex_Ural
/
opencode
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
dev
.github/workflows/close-prs.yml
50 строк
1 KB
Aiden Cline
ci: Automate PR cleanup (#27667)
15 май 2026, 07:47
Не верифицирован
15 май 2026, 07:47
d59d996
Код
Авторство
О чём код?
name: close-prs on: schedule: - cron: "0 22 * * *" # Daily at 10:00 PM UTC workflow_dispatch: inputs: dry-run: description: "Log matching PRs without closing them" type: boolean default: true max-close: description: "Maximum matching PRs to close" type: string required: false default: "50" jobs: close: runs-on: ubuntu-latest timeout-minutes: 240 permissions: contents: read issues: write pull-requests: write steps: - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1 - uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0 with: bun-version: latest - name: Close old PRs without enough positive reactions env: GITHUB_TOKEN: ${{ github.token }} run: | max_close="${{ inputs['max-close'] }}" if [ -z "$max_close" ]; then max_close="50" fi args=("--threshold" "2" "--age-months" "1" "--sleep-ms" "20000" "--max-close" "$max_close") if [ "${{ github.event_name }}" = "schedule" ]; then args+=("--execute") elif [ "${{ inputs['dry-run'] }}" = "false" ]; then args+=("--execute") fi bun script/github/close-prs.ts "${args[@]}"