The Tampermonkey script can be accessed in the index_passage_list
. You can find and install the script from Greasy Fork:
Tampermonkey Script: Auto Read
Set your username and password in the .env
file.
Run the following commands:
npm install
node .\pteer.js
Install the required packages and run the same commands as for Windows:
sudo apt-get update
sudo apt install nodejs npm -y
sudo apt-get install -y wget unzip fontconfig locales gconf-service libasound2 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgcc1 libgconf-2-4 libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 ca-certificates fonts-liberation libappindicator1 libnss3 lsb-release xdg-utils wget
Modify the start time and duration as needed. The code is located in .github/workflows/cron_read.yaml
.
Set the username and password in the secrets of GitHub actions (variable names can be referred from .env
). Note that setting the environment variables in .env
here does not work for GitHub actions.
Tutorial: Enable Automatic Updates
Clone the repository, set environment variables in docker-compose.yml
, and run:
docker-compose up -d
To view logs:
docker-compose logs -f
Set permissions and edit the crontab:
chmod +x cron.sh
crontab -e
Manually add the following entry (to execute daily at 6 AM, adjust the directory as needed):
0 6 * * * /root/auto-read-linuxdo/cron.sh # Note this is a sample directory, change to your repository's cron.sh directory (use pwd to find your directory)
The external script is used for puppeteer and is modified from index_passage_list.js
. Main modifications include removing buttons and setting automatic reading and liking to start by default:
localStorage.setItem("read", "true"); // Initially disables auto-scroll
localStorage.setItem("autoLikeEnabled", "true"); // Auto-liking is enabled by default