.github/workflows/report-least-recent-modified-files.yml #38
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
schedule: | |
# Run at 1AM every saturday | |
- cron: '0 1 * * 6' | |
workflow_dispatch: | |
inputs: | |
quantity: | |
description: 'How many files to show' | |
required: false | |
default: '500' | |
type: string | |
jobs: | |
report_least_recent_modified_files: | |
runs-on: ubuntu-latest | |
steps: | |
- name: 'Checkout primary branch' | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: '0' | |
- name: Report and upload | |
run: "cd docs; for file in $(find . -type f); do echo $(git log --pretty=format:%ai -n 1 --date=raw -w --follow -- $file) $file; done | sort > ../least-recent-files.txt" | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: least-recent-files.txt | |
path: ./least-recent-files.txt |