From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on gnuweeb.org X-Spam-Level: X-Spam-Status: No, score=-1.8 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,NO_DNS_FOR_FROM, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from [192.168.1.5] (unknown [101.128.125.254]) by gnuweeb.org (Postfix) with ESMTPSA id CAD828060F; Sat, 27 Aug 2022 16:00:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gnuweeb.org; s=default; t=1661616058; bh=2UJfxTZNIP74Yj2WV7u8xi0guRc0zEftJ1AurZxuhOo=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=GEeGWGX8rqtDDoFKXF7VtD083O29Ic1QBpx1Sh3YpqHE21y/yjfpzMQ0yXn7yHx44 KEWcoFxkeRUFSkO++W/UDuvKWQ2Zj5WcyKV9lZj0jCRMgdGYuvPAqjnoDe0EtOR9JF YQFIbH57+gCOG8nsEVwqb/dU5oYYtichQpQdMT7cW/nzoMj5OnY0oRDy8AgJxYYEgV YGOZI5x5AkxYl/mzdoLsuZjyq0/m46Pl2iQCOKg9kfqE9lGd3nOOoi6WB6jVjQp/vk yV4APUbCrUpP4w8OJY0DP2GaN0ve7hLESvlA6x/g0QZIYSMLHgRUH2pmCqroDZWzGn fBEqmtTH3U1pQ== Message-ID: <7a414bd1-68f1-86a4-e647-7ee071a4300d@gnuweeb.org> Date: Sat, 27 Aug 2022 23:00:53 +0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.2.0 Subject: Re: [PATCH v2 0/3] New Discord bot and full refactor scripts To: Ammar Faizi Cc: GNU/Weeb Mailing List , Alviro Iskandar Setiawan References: <20220827030236.1094-1-kiizuha@gnuweeb.org> Content-Language: en-US From: Muhammad Rizki In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: On 27/08/2022 17.40, Ammar Faizi wrote: > On 8/27/22 10:02 AM, Muhammad Rizki wrote: >> Good morning, sir >> In this series I created a Discord bot, the functionality and features >> still the same with the Telegram bot, this series contains full refactor >> both Discord and Telegram bot scripts which is more cleaner. >> >> Refactors: >> Moving the atom related files outside the bot scripts which is can be >> reusable with each other bot scripts. >> Moving the database related files and create a directory for themselves, >> this method is more clean so it's more easier to develop and maintain. >> Mass refactor for Telegram and Discord bot scripts. >> Combine the SQL file for Discord and Telegram bot, so we don't have to >> make a new database. > > Can you tell a bit how to setup and test this? > How to setup: - Install the package first with `requirements.txt` in the `dscord` or `telegram` directory - Set the environment in the `daemon` workdir like `discord.env` or `telegram.env` - Set the `config.py` for discord or telegram - Run the bot by running `python3 dc.py` or `python3 tg.py` in the daemon workdir The reason I naming the discord directory with `dscord` is because for preventing conflict with `discord.py` library, if you have any question just tell me, thanks.