Script to fix Co-authored-by lines produced by Google Jules to match my Git config.
The content of a Go slice can be explored beyond its len, up to its cap.
See https://go.dev/play/p/e4jrZdQhpcP
A good reason for not exposing slices beyond their length and use "full slices expressions" to constrain the capacity when exposing internal data.
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
| # https://ghostty.org/docs/config/reference#window-inherit-working-directory | |
| window-inherit-working-directory = false | |
| # https://ghostty.org/docs/config/reference#working-directory | |
| working-directory = home | |
| # Start zsh as a login shell | |
| # https://ghostty.org/docs/config/reference#initial-command | |
| initial-command = /usr/bin/zsh -l | |
| command = /usr/bin/zsh -l |
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
| #!/bin/bash | |
| # Commands to evaluate impact of xz installed via homebrew. | |
| # Author: Olivier Mengué. | |
| # Show info about xz bottle: | |
| brew info xz | |
| # Upgrade xz: | |
| brew update |
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
| <html> | |
| <head> | |
| <meta http-equiv="refresh" content="0; url=https://github.com/" /> | |
| </head> | |
| <body> | |
| </body> |
https://redis.com/blog/go-redis-official-redis-client/
curl https://gist.githubusercontent.com/dolmen/9f5b4b1892588a5a8948a7c8e116660b/raw/dafeeb86c5c1c1fe80499b0c652f218c3c69aebd/migrate-go-redis-v9.sh | bash
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
| /* | |
| kh-to-hashcat allows to convert an OpenSSH known_hosts hashed file to a | |
| format that can be used with hashcat to recover hosts. | |
| Note that as the know_hosts file usually contains multiple keys for each host | |
| it is wise to filter the file to a single key type to filter redundant hashes. | |
| Check this stat: | |
| perl -nE '$c{$1}++ if /^\|1\|[^ ]+ ([^ ]+)/;END{say "$_: $c{$_}" for keys %c}' ~/.ssh/known_hosts |
- @dolmen
- Part 1 (Go): https://go.dev/play/p/C7hbiSq5Hcj
- Part 2 (Go): https://go.dev/play/p/_O5Uamo34hG
- Part 2 (Go, v2 storing only top 3 loads): https://go.dev/play/p/XG2fDnGtVD-
Hacks below use goproc to experiment with Go templates from the command-line.
$ echo false | goproc -e '{{.}} => {{index "....\001\000" (len (print .))}}{{"\n"}}'
false => 0
$ echo true | goproc -e '{{.}} => {{index "....\001\000" (len (print .))}}{{"\n"}}'NewerOlder