From b9656e37999d9072751ce51477776ebbe8fa8a10 Mon Sep 17 00:00:00 2001 From: Hafitz Setya Date: Thu, 26 Aug 2021 07:54:38 +0700 Subject: [PATCH] Tidying up Signed-off-by: breakdowns --- Dockerfile | 2 +- README.md | 131 +++++++++--------- .../download_utils/qbit_downloader.py | 8 +- bot/modules/delete.py | 2 +- config_sample.env | 2 +- heroku-guide.md | 26 ++-- 6 files changed, 83 insertions(+), 88 deletions(-) diff --git a/Dockerfile b/Dockerfile index 3db5d3d21b2..9e40a6ac24d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,8 +10,8 @@ COPY extract /usr/local/bin COPY pextract /usr/local/bin RUN chmod +x /usr/local/bin/extract && chmod +x /usr/local/bin/pextract COPY . . -COPY .netrc /root/.netrc COPY qBittorrent.conf ./.config/qBittorrent/qBittorrent.conf +COPY .netrc /root/.netrc RUN chmod 600 /usr/src/app/.netrc RUN chmod +x aria.sh diff --git a/README.md b/README.md index 315afe2094d..4f09f90a5ed 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ ![Docker Pulls](https://img.shields.io/docker/pulls/breakdowns/mega-sdk-python?label=Docker%20Pull) [![Channel](https://img.shields.io/badge/Join%20Channel-!-red)](https://t.me/SlamMirrorUpdates) -**Slam Mirror Bot** is a _multipurpose_ Telegram Bot writen in Python for mirroring files on the Internet to our beloved Google Drive. +**Slam Mirror Bot** is a _multipurpose_ Telegram Bot writen in Python for mirroring files on the Internet to our beloved Google Drive. Based on [python-aria-mirror-bot](https://github.com/lzzy12/python-aria-mirror-bot) # Features supported:
@@ -56,7 +56,7 @@ uptobox.com (Uptobox account must be premium), solidfiles.com - Shortener support - Custom Filename (Only for URL, Telegram files and Youtube-dl. Not for Mega links and Magnet/Torrents) - Extracting password protected files, using custom filename and download from password protected Index Links see these examples: -

+

- Extract these filetypes and uploads to Google Drive ``` @@ -83,9 +83,7 @@ For Debian based distros ``` sudo apt install python3 ``` -Install Docker by following the [official Docker docs](https://docs.docker.com/engine/install/debian/) - -OR +Install Docker by following the [official Docker docs](https://docs.docker.com/engine/install/debian/), or: ``` sudo snap install docker ``` @@ -109,10 +107,10 @@ pip3 install -r requirements-cli.txt - Hit **Review** - Hit **Create instance** - Select your database name -- Copy your database url, and fill to **DATABASE_URL** in config +- Copy your database url, and fill to `DATABASE_URL` in config **2. Using Heroku PostgreSQL** -

+

@@ -129,45 +127,45 @@ _____REMOVE_THIS_LINE_____=True ``` Fill up rest of the fields. Meaning of each fields are discussed below: ### Required Field -- **BOT_TOKEN**: The Telegram bot token that you get from [@BotFather](https://t.me/BotFather) -- **TELEGRAM_API**: This is to authenticate to your Telegram account for downloading Telegram files. You can get this from https://my.telegram.org DO NOT put this in quotes. -- **TELEGRAM_HASH**: This is to authenticate to your Telegram account for downloading Telegram files. You can get this from https://my.telegram.org -- **OWNER_ID**: The Telegram user ID (not username) of the Owner of the bot -- **GDRIVE_FOLDER_ID**: This is the folder ID of the Google Drive Folder to which you want to upload all the mirrors. -- **DOWNLOAD_DIR**: The path to the local folder where the downloads should be downloaded to -- **DOWNLOAD_STATUS_UPDATE_INTERVAL**: A short interval of time in seconds after which the Mirror progress message is updated. (I recommend to keep it `5` seconds at least) -- **AUTO_DELETE_MESSAGE_DURATION**: Interval of time (in seconds), after which the bot deletes it's message (and command message) which is expected to be viewed instantly. (**Note**: Set to `-1` to never automatically delete messages) +- `BOT_TOKEN`: The Telegram bot token that you get from [@BotFather](https://t.me/BotFather) +- `TELEGRAM_API`: This is to authenticate to your Telegram account for downloading Telegram files. You can get this from https://my.telegram.org DO NOT put this in quotes. +- `TELEGRAM_HASH`: This is to authenticate to your Telegram account for downloading Telegram files. You can get this from https://my.telegram.org +- `OWNER_ID`: The Telegram user ID (not username) of the Owner of the bot +- `GDRIVE_FOLDER_ID`: This is the folder ID of the Google Drive Folder to which you want to upload all the mirrors. +- `DOWNLOAD_DIR`: The path to the local folder where the downloads should be downloaded to +- `DOWNLOAD_STATUS_UPDATE_INTERVAL`: A short interval of time in seconds after which the Mirror progress message is updated. (I recommend to keep it `5` seconds at least) +- `AUTO_DELETE_MESSAGE_DURATION`: Interval of time (in seconds), after which the bot deletes it's message (and command message) which is expected to be viewed instantly. (**Note**: Set to `-1` to never automatically delete messages) ### Optional Field -- **ACCOUNTS_ZIP_URL**: Only if you want to load your Service Account externally from an Index Link. Archive the accounts folder to a zip file. Fill this with the direct link of that file. -- **TOKEN_PICKLE_URL**: Only if you want to load your **token.pickle** externally from an Index Link. Fill this with the direct link of that file. -- **DATABASE_URL**: Your Database URL. See [Generate Database](https://github.com/SlamDevs/slam-mirrorbot/tree/master#generate-database) to generate database (**NOTE**: If you use database you can save your sudo id permanent using `/addsudo` command). -- **AUTHORIZED_CHATS**: Fill user_id and chat_id (not username) of you want to authorize, Seprate them with space, Examples: `-0123456789 -1122334455 6915401739`. -- **SUDO_USERS**: Fill user_id (not username) of you want to sudoers, Seprate them with space, Examples: `0123456789 1122334455 6915401739` (**NOTE**: If you want save sudo id permanent without database, you must fill your sudo id there). -- **IS_TEAM_DRIVE**: Set to `True` if `GDRIVE_FOLDER_ID` is from a Team Drive else `False` or Leave it empty. -- **USE_SERVICE_ACCOUNTS**: (Leave empty if unsure) Whether to use Service Accounts or not. For this to work see [Using Service Accounts](https://github.com/SlamDevs/slam-mirrorbot#generate-service-accounts-what-is-service-account) section below. -- **INDEX_URL**: Refer to https://gitlab.com/ParveenBhadooOfficial/Google-Drive-Index The URL should not have any trailing '/' -- **MEGA_API_KEY**: Mega.nz api key to mirror mega.nz links. Get it from [Mega SDK Page](https://mega.nz/sdk) -- **MEGA_EMAIL_ID**: Your email id you used to sign up on mega.nz for using premium accounts (Leave th) -- **MEGA_PASSWORD**: Your password for your mega.nz account -- **BLOCK_MEGA_FOLDER**: If you want to remove mega.nz folder support, set it to `True`. -- **BLOCK_MEGA_LINKS**: If you want to remove mega.nz mirror support, set it to `True`. -- **STOP_DUPLICATE**: (Leave empty if unsure) if this field is set to `True`, bot will check file in Drive, if it is present in Drive, downloading or cloning will be stopped. (**Note**: File will be checked using filename, not using filehash, so this feature is not perfect yet) -- **CLONE_LIMIT**: To limit cloning Google Drive (leave space between number and unit, Available units is (gb or GB, tb or TB), Examples: `100 gb, 100 GB, 10 tb, 10 TB` -- **MEGA_LIMIT**: To limit downloading Mega (leave space between number and unit, Available units is (gb or GB, tb or TB), Examples: `100 gb, 100 GB, 10 tb, 10 TB` -- **TORRENT_DIRECT_LIMIT**: To limit the Torrent/Direct mirror size, Leave space between number and unit. Available units is (gb or GB, tb or TB), Examples: `100 gb, 100 GB, 10 tb, 10 TB` -- **TAR_UNZIP_LIMIT**: To limit mirroring as Tar or unzipmirror. Available units is (gb or GB, tb or TB), Examples: `100 gb, 100 GB, 10 tb, 10 TB` -- **VIEW_LINK**: View Link button to open file Index Link in browser instead of direct download link, you can figure out if it's compatible with your Index code or not, open any video from you Index and check if the END of link from browser link bar is `?a=view`, if yes make it `True` it will work (Compatible with [Bhadoo Index](https://gitlab.com/ParveenBhadooOfficial/Google-Drive-Index) Code) -- **UPTOBOX_TOKEN**: Uptobox token to mirror uptobox links. Get it from [Uptobox Premium Account](https://uptobox.com/my_account). -- **HEROKU_EMAIL**: Heroku Account email Id in which the above app will be deployed (**NOTE**: Only needed if you deploying on Heroku with Github Workflow). -- **HEROKU_API_KEY**: (Only if you deploying on Heroku) Your Heroku API key, get it from https://dashboard.heroku.com/account. -- **HEROKU_APP_NAME**: (Only if you deploying on Heroku) Your Heroku app name. -- **IGNORE_PENDING_REQUESTS**: If you want the bot to ignore pending requests after it restarts, set this to `True`. -- **STATUS_LIMIT**: Status limit with buttons (**NOTE**: Recommend limit status to `4` tasks max). -- **IS_VPS**: (Only for VPS) Don't set this to `True` even if you are using VPS, unless facing error with web server. Also go to start.sh and replace `$PORT` by `80` or any port you want to use. -- **SERVER_PORT**: (Only if IS_VPS is `True`) Base URL Port -- **BASE_URL_OF_BOT**: (Required for Heroku) Valid BASE URL of where the bot is deploy. Ip/domain of your bot like `http://myip` or if you have chosen other port then `80` then `http://myip:port`, for Heroku fill `https://yourappname.herokuapp.com` (**NOTE**: No slash at the end) -- **SHORTENER_API**: Fill your Shortener api key if you are using Shortener. -- **SHORTENER**: if you want to use Shortener in Gdrive and index link, fill Shortener url here. Examples: +- `ACCOUNTS_ZIP_URL`: Only if you want to load your Service Account externally from an Index Link. Archive the accounts folder to a zip file. Fill this with the direct link of that file. +- `TOKEN_PICKLE_URL`: Only if you want to load your **token.pickle** externally from an Index Link. Fill this with the direct link of that file. +- `DATABASE_URL`: Your Database URL. See [Generate Database](https://github.com/SlamDevs/slam-mirrorbot/tree/master#generate-database) to generate database (**NOTE**: If you use database you can save your sudo id permanent using `/addsudo` command). +- `AUTHORIZED_CHATS`: Fill user_id and chat_id (not username) of you want to authorize, Seprate them with space, Examples: `-0123456789 -1122334455 6915401739`. +- `SUDO_USERS`: Fill user_id (not username) of you want to sudoers, Seprate them with space, Examples: `0123456789 1122334455 6915401739` (**NOTE**: If you want save sudo id permanent without database, you must fill your sudo id there). +- `IS_TEAM_DRIVE`: Set to `True` if `GDRIVE_FOLDER_ID` is from a Team Drive else `False` or Leave it empty. +- `USE_SERVICE_ACCOUNTS`: (Leave empty if unsure) Whether to use Service Accounts or not. For this to work see [Using Service Accounts](https://github.com/SlamDevs/slam-mirrorbot#generate-service-accounts-what-is-service-account) section below. +- `INDEX_URL`: Refer to https://gitlab.com/ParveenBhadooOfficial/Google-Drive-Index The URL should not have any trailing '/' +- `MEGA_API_KEY`: Mega.nz api key to mirror mega.nz links. Get it from [Mega SDK Page](https://mega.nz/sdk) +- `MEGA_EMAIL_ID`: Your email id you used to sign up on mega.nz for using premium accounts (Leave th) +- `MEGA_PASSWORD`: Your password for your mega.nz account +- `BLOCK_MEGA_FOLDER`: If you want to remove mega.nz folder support, set it to `True`. +- `BLOCK_MEGA_LINKS`: If you want to remove mega.nz mirror support, set it to `True`. +- `STOP_DUPLICATE`: (Leave empty if unsure) if this field is set to `True`, bot will check file in Drive, if it is present in Drive, downloading or cloning will be stopped. (**Note**: File will be checked using filename, not using filehash, so this feature is not perfect yet) +- `CLONE_LIMIT`: To limit cloning Google Drive (leave space between number and unit, Available units is (gb or GB, tb or TB), Examples: `100 gb, 100 GB, 10 tb, 10 TB` +- `MEGA_LIMIT`: To limit downloading Mega (leave space between number and unit, Available units is (gb or GB, tb or TB), Examples: `100 gb, 100 GB, 10 tb, 10 TB` +- `TORRENT_DIRECT_LIMIT`: To limit the Torrent/Direct mirror size, Leave space between number and unit. Available units is (gb or GB, tb or TB), Examples: `100 gb, 100 GB, 10 tb, 10 TB` +- `TAR_UNZIP_LIMIT`: To limit mirroring as Tar or unzipmirror. Available units is (gb or GB, tb or TB), Examples: `100 gb, 100 GB, 10 tb, 10 TB` +- `VIEW_LINK`: View Link button to open file Index Link in browser instead of direct download link, you can figure out if it's compatible with your Index code or not, open any video from you Index and check if the END of link from browser link bar is `?a=view`, if yes make it `True` it will work (Compatible with [Bhadoo Index](https://gitlab.com/ParveenBhadooOfficial/Google-Drive-Index) Code) +- `UPTOBOX_TOKEN`: Uptobox token to mirror uptobox links. Get it from [Uptobox Premium Account](https://uptobox.com/my_account). +- `HEROKU_EMAIL`: Heroku Account email Id in which the above app will be deployed (**NOTE**: Only needed if you deploying on Heroku with Github Workflow). +- `HEROKU_API_KEY`: (Only if you deploying on Heroku) Your Heroku API key, get it from https://dashboard.heroku.com/account. +- `HEROKU_APP_NAME`: (Only if you deploying on Heroku) Your Heroku app name. +- `IGNORE_PENDING_REQUESTS`: If you want the bot to ignore pending requests after it restarts, set this to `True`. +- `STATUS_LIMIT`: Status limit with buttons (**NOTE**: Recommend limit status to `4` tasks max). +- `IS_VPS`: (Only for VPS) Don't set this to `True` even if you are using VPS, unless facing error with web server. Also go to start.sh and replace `$PORT` by `80` or any port you want to use. +- `SERVER_PORT`: (Only if IS_VPS is `True`) Base URL Port +- `BASE_URL_OF_BOT`: (Required for Heroku) Valid BASE URL of where the bot is deploy. Ip/domain of your bot like `http://myip` or if you have chosen other port then `80` then `http://myip:port`, for Heroku fill `https://yourappname.herokuapp.com` (**NOTE**: No slash at the end) +- `SHORTENER_API`: Fill your Shortener api key if you are using Shortener. +- `SHORTENER`: if you want to use Shortener in Gdrive and index link, fill Shortener url here. Examples: ``` exe.io, gplinks.in, shrinkme.io, urlshortx.com, shortzon.com ``` @@ -175,12 +173,12 @@ exe.io, gplinks.in, shrinkme.io, urlshortx.com, shortzon.com Above are the supported url Shorteners. Except these only some url Shorteners are supported. ### Add more buttons (Optional Field) Three buttons are already added of Drive Link, Index Link, and View Link, you can add extra buttons, if you don't know what are below entries, simply leave them, don't fill anything in them. -- **BUTTON_FOUR_NAME**: -- **BUTTON_FOUR_URL**: -- **BUTTON_FIVE_NAME**: -- **BUTTON_FIVE_URL**: -- **BUTTON_SIX_NAME**: -- **BUTTON_SIX_URL**: +- `BUTTON_FOUR_NAME`: +- `BUTTON_FOUR_URL`: +- `BUTTON_FIVE_NAME`: +- `BUTTON_FIVE_URL`: +- `BUTTON_SIX_NAME`: +- `BUTTON_SIX_URL`: @@ -214,14 +212,15 @@ docker build . --rm --force-rm --compress --no-cache=true --pull --file Dockerfi sudo docker run mirrorbot ``` -## Deploying on Heroku with Github Workflow -

+## Deploying on Heroku +- Deploying on Heroku with Github Workflow +

-## Deploying on Heroku with heroku-cli and Goorm IDE -

+- Deploying on Heroku with heroku-cli and Goorm IDE +

# Using Service Accounts for uploading to avoid user rate limit -For Service Account to work, you must set **USE_SERVICE_ACCOUNTS=**"True" in config file or environment variables, +For Service Account to work, you must set `USE_SERVICE_ACCOUNTS`="True" in config file or environment variables, Many thanks to [AutoRClone](https://github.com/xyou365/AutoRclone) for the scripts. **NOTE**: Using Service Accounts is only recommended while uploading to a Team Drive. @@ -299,15 +298,15 @@ Where host is the name of extractor (eg. Youtube, Twitch). Multiple accounts of # Credits Thanks to: -- [out386](https://github.com/out386) heavily inspired from Telegram Bot which is written in JS -- [Izzy12](https://github.com/lzzy12) for build up this bot from scratch -- [jaskaranSM](https://github.com/jaskaranSM) for build up this bot from scratch -- [Dank-del](https://github.com/Dank-del) for base repo -- [magneto261290](https://github.com/magneto261290) for some features -- [SVR666](https://github.com/SVR666) for some features & fixes -- [anasty17](https://github.com/anasty17) for some features & help -- [breakdowns](https://github.com/breakdowns) for slam-mirrorbot -- [zevtyardt](https://github.com/zevtyardt) for some direct links -- [yash-dk](https://github.com/yash-dk) for implementation qBittorrent on Python +- [`out386`](https://github.com/out386) heavily inspired from Telegram Bot which is written in JS +- [`Izzy12`](https://github.com/lzzy12) for build up this bot from scratch +- [`jaskaranSM`](https://github.com/jaskaranSM) for build up this bot from scratch +- [`Dank-del`](https://github.com/Dank-del) for base repo +- [`magneto261290`](https://github.com/magneto261290) for some features +- [`SVR666`](https://github.com/SVR666) for some features & fixes +- [`anasty17`](https://github.com/anasty17) for some features & help +- [`breakdowns`](https://github.com/breakdowns) for slam-mirrorbot +- [`zevtyardt`](https://github.com/zevtyardt) for some direct links +- [`yash-dk`](https://github.com/yash-dk) for implementation qBittorrent on Python And many more people who aren't mentioned here, but may be found in [Contributors](https://github.com/SlamDevs/slam-mirrorbot/graphs/contributors). diff --git a/bot/helper/mirror_utils/download_utils/qbit_downloader.py b/bot/helper/mirror_utils/download_utils/qbit_downloader.py index 917aa8c9e21..fd305cd2ebd 100644 --- a/bot/helper/mirror_utils/download_utils/qbit_downloader.py +++ b/bot/helper/mirror_utils/download_utils/qbit_downloader.py @@ -51,7 +51,7 @@ def add_torrent(self, link, dire, listener, qbitsel): self.ext_hash = get_hash_magnet(link) tor_info = self.client.torrents_info(torrent_hashes=self.ext_hash) if len(tor_info) > 0: - sendMessage("This torrent is already in list.", listener.bot, listener.update) + sendMessage("This Torrent is already in list.", listener.bot, listener.update) self.client.auth_log_out() return if is_file: @@ -64,7 +64,7 @@ def add_torrent(self, link, dire, listener, qbitsel): if len(tor_info) == 0: while True: if time.time() - self.meta_time >= 300: - sendMessage("The torrent was not added. report when u see this error", listener.bot, listener.update) + sendMessage("The Torrent was not added. report when you see this error", listener.bot, listener.update) self.client.auth_log_out() return False tor_info = self.client.torrents_info(torrent_hashes=self.ext_hash) @@ -81,7 +81,7 @@ def add_torrent(self, link, dire, listener, qbitsel): self.updater = setInterval(self.update_interval, self.update) if BASE_URL is not None and qbitsel: if not is_file: - meta = sendMessage("Downloading Metadata...Please wait then you can select files or mirror torrent file if it have low seeders", listener.bot, listener.update) + meta = sendMessage("Downloading Metadata...Please wait then you can select files or mirror Torrent file if it have low seeders", listener.bot, listener.update) while True: tor_info = self.client.torrents_info(torrent_hashes=self.ext_hash) if len(tor_info) == 0: @@ -169,7 +169,7 @@ def update(self): self.updater.cancel() return elif tor_info.state == "error": - self.listener.onDownloadError("Error. IDK why, report in support group") + self.listener.onDownloadError("Error. IDK why, report in @SlamBugReport") self.client.torrents_delete(torrent_hashes=self.ext_hash, delete_files=True) self.client.auth_log_out() self.updater.cancel() diff --git a/bot/modules/delete.py b/bot/modules/delete.py index 32ebdd86966..57f63f9ad3c 100644 --- a/bot/modules/delete.py +++ b/bot/modules/delete.py @@ -20,7 +20,7 @@ def deletefile(update, context): if msg == '' : drive = gdriveTools.GoogleDriveHelper() msg = drive.deletefile(link) - LOGGER.info(f"DeleteFileCmd : {msg}") + LOGGER.info(f"DeleteFileCmd: {msg}") reply_message = sendMessage(msg, context.bot, update) threading.Thread(target=auto_delete_message, args=(context.bot, update.message, reply_message)).start() diff --git a/config_sample.env b/config_sample.env index b0a6f71a30a..34f19bdfbd0 100644 --- a/config_sample.env +++ b/config_sample.env @@ -29,7 +29,7 @@ STOP_DUPLICATE = "" SHORTENER = "" SHORTENER_API = "" # qBittorrent -IS_VPS = "" # Don't set this to true even if vps, unless facing error with web server +IS_VPS = "" # Don't set this to True even if VPS, unless facing error with web server SERVER_PORT = "80" # Only for VPS BASE_URL_OF_BOT = "" # Required for Heroku # If you want to use Credentials externally from Index Links, fill these vars with the direct links diff --git a/heroku-guide.md b/heroku-guide.md index e0f08145c59..f8b66836719 100644 --- a/heroku-guide.md +++ b/heroku-guide.md @@ -2,10 +2,8 @@ ## Pre-requisites -- [token.pickle](https://github.com/SlamDevs/slam-mirrorbot#getting-google-oauth-api-credential-file) -- [Heroku](heroku.com) accounts -- Recommended to use 1 App in 1 Heroku account -- Don't use bin/fake credits card, because your Heroku account will get banned. +- [Token Pickle](https://github.com/SlamDevs/slam-mirrorbot#getting-google-oauth-api-credential-file) +- [Heroku](heroku.com) accounts. **NOTE**: Recommended to use 1 App in 1 Heroku account and Don't use bin/fake credits card, because your Heroku account will get banned. ## Deployment @@ -20,7 +18,7 @@ * `HEROKU_EMAIL` Heroku Account Email Id in which the above app will be deployed * `HEROKU_API_KEY` Your Heroku API key, get it from https://dashboard.heroku.com/account * `HEROKU_APP_NAME` Your Heroku app name, Name Must be unique - * `CONFIG_FILE_URL` Fill [This](https://raw.githubusercontent.com/Slam-Team/slam-mirrorbot/master/config_sample.env) in any text editor. Remove the `_____REMOVE_THIS_LINE_____=True` line and fill the variables. Go to https://gist.github.com and paste your config data. Rename the file to `config.env` then create secret gist. Click on Raw, copy the link. This will be your `CONFIG_FILE_URL`. Refer to below images for clarity. + * `CONFIG_FILE_URL` Fill [This](https://raw.githubusercontent.com/Slam-Team/slam-mirrorbot/master/config_sample.env) in any text editor. Remove the `_____REMOVE_THIS_LINE_____=True` line and fill the variables. For details about config you can see [Here](https://github.com/SlamDevs/slam-mirrorbot#setting-up-config-file). Go to https://gist.github.com and paste your config data. Rename the file to `config.env` then create secret gist. Click on Raw, copy the link. This will be your `CONFIG_FILE_URL`. Refer to below images for clarity. ![steps 1 to 3](https://telegra.ph/file/1d8fec16516a87ba9d1ac.jpg) @@ -28,12 +26,10 @@ ![step 5](https://telegra.ph/file/416a550f7ded579b63272.jpg) -- **NOTE**: Remove commit id from raw link to be able to change variables without updating the `CONFIG_FILE_URL` in secrets. - should be in this form: https://gist.githubusercontent.com/username/gist-id/raw/config.env - - Before: https://gist.githubusercontent.com/anasty17/8cce4a4b4e7f4ea47e948b2d058e52ac/raw/19ba5ab5eb43016422193319f28bc3c7dfb60f25/config.env - - After: https://gist.githubusercontent.com/anasty17/8cce4a4b4e7f4ea47e948b2d058e52ac/raw/config.env - - - You only need to restart your bot after editing `config.env` gist secret. + * **NOTE**: Remove commit id from raw link to be able to change variables without updating the `CONFIG_FILE_URL` in secrets. should be in this form: https://gist.githubusercontent.com/username/gist-id/raw/config.env + * Before: https://gist.githubusercontent.com/anasty17/8cce4a4b4e7f4ea47e948b2d058e52ac/raw/19ba5ab5eb43016422193319f28bc3c7dfb60f25/config.env + * After: https://gist.githubusercontent.com/anasty17/8cce4a4b4e7f4ea47e948b2d058e52ac/raw/config.env + * You only need to restart your bot after editing `config.env` gist secret. 4. After adding all the above Required Variables go to Github Actions tab in your repo @@ -45,11 +41,11 @@ ![Run workflow](https://telegra.ph/file/c5b4c2e02f585cb59fe5c.jpg) -7. _Done!_ your bot will be deployed now. +7. **Done!** your bot will be deployed now. ## NOTE -- Don't change/edit variables from Heroku if you want to change/edit do it from `config.env` +- Don't change/edit variables from Heroku if you want to change/edit do it in `config.env` from your gist. ## Credits -- [arghyac35](https://github.com/arghyac35) for Tutorial -- [AkhileshNS](https://github.com/AkhileshNS) for Github workflow method to deploy Heroku app +- [`arghyac35`](https://github.com/arghyac35) for Tutorial +- [`AkhileshNS`](https://github.com/AkhileshNS) for Github Workflow method to deploy Heroku app