name: Cache smoke test

on:
  workflow_dispatch:
  
jobs:
  test-cache:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - name: Use cache
        uses: actions/cache@v4
        with:
          path: ~/.cache/mytool
          key: demo-cache-${{ runner.os }}-v1
      - name: Touch a file to cache
        run: |
          mkdir -p ~/.cache/mytool
          date > ~/.cache/mytool/when.txt
