This file contains hidden or 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
package main | |
// Assumes a directory next to this file called "templates" | |
// containing "home.html", "forest.html" | |
import ( | |
"embed" | |
"fmt" | |
"html/template" | |
"io" |
This file contains hidden or 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
package main | |
import ( | |
"fmt" | |
"maps" | |
"os" | |
"regexp" | |
"slices" | |
"strings" | |
"time" |
This file contains hidden or 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
// 09 January 2025 | |
package main | |
import ( | |
"cmp" | |
"fmt" | |
"slices" | |
"sort" | |
"time" | |
) |
This file contains hidden or 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
package main | |
import ( | |
"fmt" | |
"os" | |
"github.com/charmbracelet/bubbles/list" | |
tea "github.com/charmbracelet/bubbletea" | |
"github.com/charmbracelet/lipgloss" | |
) |
This file contains hidden or 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
package main | |
import ( | |
"context" | |
"database/sql" | |
"fmt" | |
_ "github.com/lib/pq" | |
) |
This file contains hidden or 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
/* | |
Check the certificates loaded into the specified ssh agent for imminent expiry | |
example output: | |
0 key ssh-ed25519 : is not a certificate | |
1 key ssh-ed25519-cert-v01@openssh.com | |
comment: acmeinc_briony_from:2023-03-07T08:18_to:2023-03-07T11:18UTC | |
validity: 2023-03-07 08:37:23 GMT to 2023-03-07 11:37:23 GMT | |
expiring in 60m? true |
This file contains hidden or 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
package main | |
import ( | |
"crypto/ed25519" | |
"crypto/x509" | |
"fmt" | |
"time" | |
"encoding/pem" |
This file contains hidden or 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
// RCL 05 June 2021 | |
/* | |
verify with `openssl pkey -in <privatekey>` or `openssl pkey -in <privatekey> -pubout` | |
the latter should match the publickey | |
*/ | |
package main | |
import ( |