Skip to content

Commit

Permalink
meaningless changes to trigger workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
AleixMT committed Apr 9, 2024
1 parent 3776c9e commit 33cd1f9
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 18 deletions.
21 changes: 3 additions & 18 deletions .github/workflows/buildAndSendSignatures.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,21 +86,6 @@ jobs:
- name: Send emails
id: send-emails
run: |
for signature in ${{ steps.changed-files.outputs.signatures_to_build }}; do
pointer="$(echo "${signature}" | tr '[:lower:]' '[:upper:]')_EMAIL"
echo pointer is $pointer
email_value="${!pointer}"
echo pointer is $email_value
echo curl --url 'smtps://smtp.gmail.com:465' \
--ssl-reqd \
--mail-from '${{secrets.EMAIL_USERNAME}}' \
--mail-rcpt "${email_value}" \
--user '${{secrets.EMAIL_USERNAME}}:${{secrets.EMAIL_PASSWORD}}' \
--upload-file "out/${signature}.html"
curl --url 'smtps://smtp.gmail.com:465' \
--ssl-reqd \
--mail-from '${{secrets.EMAIL_USERNAME}}' \
--mail-rcpt "${email_value}" \
--user '${{secrets.EMAIL_USERNAME}}:${{secrets.EMAIL_PASSWORD}}' \
--upload-file "out/${signature}.html"
done
chmod u+x src/sendEmails.sh
./src/sendEmails.sh ${{ steps.changed-files.outputs.signatures_to_build }}
23 changes: 23 additions & 0 deletions src/sendEmails.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#!/usr/bin/env bash

PROJECT_FOLDER="$(cd "$(dirname "$(realpath "$0")")/../" &>/dev/null && pwd)"


for signature in $1; do
pointer="$(echo "${signature}" | tr '[:lower:]' '[:upper:]')_EMAIL"
echo pointer is $pointer
email_value="${!pointer}"
echo pointer is $email_value
echo curl --url 'smtps://smtp.gmail.com:465' \
--ssl-reqd \
--mail-from '${EMAIL_USERNAME}' \
--mail-rcpt "${email_value}" \
--user '${EMAIL_USERNAME}:${EMAIL_PASSWORD}' \
--upload-file "${PROJECT_FOLDER}/out/${signature}.html"
curl --url 'smtps://smtp.gmail.com:465' \
--ssl-reqd \
--mail-from '${EMAIL_USERNAME}' \
--mail-rcpt "${email_value}" \
--user '${EMAIL_USERNAME}:${EMAIL_PASSWORD}' \
--upload-file "${PROJECT_FOLDER}/out/${signature}.html"
done
1 change: 1 addition & 0 deletions templates/template.html
Original file line number Diff line number Diff line change
Expand Up @@ -173,3 +173,4 @@
</div>
</body>
</html>

0 comments on commit 33cd1f9

Please sign in to comment.