Created
June 30, 2026 15:14
-
-
Save jazzsequence/6c264d1a5cf39dc8ccd0193d9178a969 to your computer and use it in GitHub Desktop.
Create a timestamp
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 | |
| set -euo pipefail | |
| IFS=$'\n\t' | |
| # Store this file with no extension in a location where you keep executables (I use ~/bin). | |
| # Run: chmod +x timestamp | |
| # Maks sure the folder you're using is automatically loaded by your shell. | |
| # In a terminal, type: timestamp | |
| # Get the timestamp! | |
| date -u +"%Y-%m-%dT%H:%M:%SZ" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment