Skip to content

Check Last Updated Timestamps #10

Check Last Updated Timestamps

Check Last Updated Timestamps #10

Workflow file for this run

name: Check Last Updated Timestamps
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * 0' # Runs every Sunday at midnight
jobs:
check_last_updated:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Check last updated timestamps
id: check
run: |
python scripts/check_last_updated.py > output.log
- name: Create issue if outdated
if: steps.check.outcome == 'failure'
uses: actions/github-script@v7
with:
script: |
const fs = require('fs');
const output = fs.readFileSync('output.log', 'utf8');
github.issues.create({
owner: context.repo.owner,
repo: context.repo.repo,
title: 'Outdated Timestamps Detected',
body: output
})