Skip to content

update cleaning old and/or specific caches #40

update cleaning old and/or specific caches

update cleaning old and/or specific caches #40

name: Clear cache weekly
on:
schedule:
# on Sundays
- cron: "0 0 * * 0"
pull_request:
paths:
- ".github/scripts/find-unused-caches.py"
- ".github/workflows/cleanup-caches.yml"
- ".github/workflows/cron-clear-cache.yml"
workflow_dispatch:
inputs:
pattern:
description: 'patter for cleaning cache'
default: "pip"
required: false
type: string
jobs:
cron-clear:
if: github.event_name == 'schedule'
uses: ./.github/workflows/cleanup-caches.yml
with:
pattern: 'pip|conda'
direct-clear:
if: github.event_name == 'workflow_dispatch'
uses: ./.github/workflows/cleanup-caches.yml
with:
pattern: ${{ inputs.pattern }}