Send Today's Morning Daily Light out! #1308
This file contains 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
name: "Send Today's Morning Daily Light out!" | |
on: | |
# run once per/day | |
schedule: | |
- cron: '23 1 * * *' | |
# so we can manually update | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: [ubuntu-20.04] | |
steps: | |
- name: Install Dependancies | |
run: | | |
sudo apt install python3.8 python3-pip | |
sudo pip3 install telegram-send==0.25 python-telegram-bot==13.5 | |
- name: Setup gitHub User Details | |
env: | |
GIT_USER: ${{ secrets.GIT_USER }} | |
GIT_EMAIL: ${{ secrets.GIT_EMAIL }} | |
GPG_USER: ${{ secrets.GPG_USER }} | |
GPG_KEY: ${{ secrets.GPG_KEY }} | |
SSH_KEY: ${{ secrets.SSH_KEY }} | |
SSH_PUB: ${{ secrets.SSH_PUB }} | |
run: | | |
/bin/bash <(/bin/curl -s https://raw.githubusercontent.com/vdm-io/github-user/master/src/setup.sh) --gpg-key "$GPG_KEY" --gpg-user "$GPG_USER" --ssh-key "$SSH_KEY" --ssh-pub "$SSH_PUB" --git-user "$GIT_USER" --git-email "$GIT_EMAIL" | |
- name: Clone Master Repositry | |
run: | | |
/bin/git clone [email protected]:trueChristian/witnesses.git witnesses | |
- name: Send Daily Light (Morning) To Telegram | |
env: | |
BOT_CONF: ${{ secrets.TG_DAILYLIGHT_BOT_CONF }} | |
run: | | |
cd witnesses | |
/bin/bash ./src/telegram.sh --bot-conf "$BOT_CONF" --message-url "https://raw.githubusercontent.com/trueChristian/daily-light/master/morning.html" --format html |