Skip to content

Instantly share code, notes, and snippets.

@gavincampbell
Last active June 25, 2020 11:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gavincampbell/72a485049ab2b0dba3ea34655607b5c3 to your computer and use it in GitHub Desktop.
Save gavincampbell/72a485049ab2b0dba3ea34655607b5c3 to your computer and use it in GitHub Desktop.
Update a markdown file to use hugo figure shortcode instead of markdown img links
sed -i 's/!\[\(.*\)\] \?(https:\/\/.*\/\(.*\))/{{< figure src="\2" caption="\1" >}}/g' index.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment