Created
April 7, 2024 10:02
-
-
Save Hamatti/1441710c6e34ed95841bddb474b18f89 to your computer and use it in GitHub Desktop.
Find all the links shared from my Syntax Error newsletter issues that are stored in my notes system using pcregrep
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
# Adapted from https://gist.github.com/chrisroos/92d4221c47f1396d0e76 | |
# - added exclusion of images (in Markdown,  is an image, [title](url) is a link) | |
# - modified from [title][url] format to [title](url) format | |
# --no-filename cleans filenames from output when grepping from multiple sources | |
# --only-matching=1 shows only the first capture group (in my case, the URL) | |
pcregrep --no-filename --only-matching=1 "(?<\!\!)\[.*?\]\((.*?)\)" ~/Documents/Juhisland/003\ -\ Projects/002\ -\ Syntax\ Error/Issues/*.md | sort | uniq |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment