Skip to content

Instantly share code, notes, and snippets.

@d-cryptic
Created April 18, 2023 08:26
Show Gist options
  • Save d-cryptic/34fcc371db02f13db801aa9d57102721 to your computer and use it in GitHub Desktop.
Save d-cryptic/34fcc371db02f13db801aa9d57102721 to your computer and use it in GitHub Desktop.
Curl send a file to gmail using smtp
# generate gmail app password and use that
curl --url 'smtps://smtp.gmail.com:465' --ssl-reqd --mail-from 'abc@example.com' --mail-rcpt 'xyz@example.com' --user 'abc@example.com:<password>' -F file='@./index.html' --insecure
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment