Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After restore cache, show count of how many URLs in it #108

Open
fulldecent opened this issue Nov 24, 2024 · 3 comments · Fixed by #114
Open

After restore cache, show count of how many URLs in it #108

fulldecent opened this issue Nov 24, 2024 · 3 comments · Fixed by #114

Comments

@fulldecent
Copy link
Owner

Cache is hard to set up and sometimes it breaks for weird reasons.

After the restore cache action, let's add a line to print out how many URLs are in that cache.

@fulldecent
Copy link
Owner Author

fulldecent commented Nov 24, 2024

Error: that messed up the required key property of the prior line

Evidence: manual inspection of the YAML.

Also. If you will make further changes, please make a PR instead of an issue.

@fulldecent
Copy link
Owner Author

Failed, undo!

@fulldecent
Copy link
Owner Author

      - name: Count URLs in cache
        run: |
          URL_COUNT=$(sqlite3 cache/external-links.db "SELECT COUNT(*) FROM urls;")
          echo "Number of URLs in cache: $URL_COUNT"

This fails if the database does not exist.

Need to have an if statement there.

@fulldecent fulldecent reopened this Nov 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants
@fulldecent and others