Assorted shell and Python scripts
at main 536 B view raw
1#!/usr/bin/env nu 2 3let old_head = "<html><style>body { background-color:white;color:black; }</style><body>" 4let new_head = ( 5 ["<html><head><title>Torrent Stats</title><link type="text/css" rel="stylesheet" href="https://files.hyperreal.coffee/css/style1.css"/></head><body><h4>Last updated:", (date now | format date "%F %T%:z"), "</h4>"] 6 | str join ' ' 7) 8 9( 10 /home/jas/admin-scripts/python/list_torrents.py 11 | from ssv -m 2 12 | to html 13 | str replace ($old_head) ($new_head) 14 | save -f -r /home/jas/public/html/torrents.html 15)