Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/anonymerniklasistanonym/websitewatchernotifiergmail
https://github.com/anonymerniklasistanonym/websitewatchernotifiergmail
Last synced: about 4 hours ago
JSON representation
- Host: GitHub
- URL: https://github.com/anonymerniklasistanonym/websitewatchernotifiergmail
- Owner: AnonymerNiklasistanonym
- License: mit
- Created: 2020-05-26T14:38:40.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2022-12-08T10:00:53.000Z (almost 2 years ago)
- Last Synced: 2024-04-16T19:10:12.321Z (7 months ago)
- Language: Python
- Size: 54.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# WebsiteWatcherNotifierGmail
Fetch a certain part of a website and check if it changed - on change send an email using the GMail API
## Prerequisites
1. Get [GMail API credentials (`credentials.json`)](https://developers.google.com/gmail/api/quickstart/python) and place them into the repository directory
2. Specify which websites should be scraped with which options
1. Either by providing a `configuration.json` file that contains this information (copy and update the example [`configuration.example.json`](configuration.example.json))
2. Or by specifying it in the file [`main.py`](main.py)## Run
- Create ron job by running:
```sh
crontab -e
```Add the following line to the file:
```text
0 */5 * * * cd Path/from/home/directory/WebsiteWatcherNotifierGmail && ./run.sh >> log.log
```(This will run the job [all 5 hours at minute 0](https://crontab.guru/#0_*/5_*_*_*))
- Run it via command line with:```sh
# Easy and no global package pollution
./run.sh
# Normal way
pip3 install -r requirements.txt
python3 -m main
```