Last active
May 9, 2023 01:30
-
-
Save musab/84a7d2968568cfdb752ac6e466b298e8 to your computer and use it in GitHub Desktop.
bash script to quickly create a new new
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
| create_note() { | |
| # Get the current date in the format YYYY-MM-DD | |
| local date=$(date +%Y-%m-%d) | |
| # Generate the file path | |
| local filepath="/Documents/notes/${date}-${1}.md" | |
| # Create the file | |
| touch "$filepath" | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment