Skip to content

Commit

Permalink
readme
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexP11223 authored Mar 23, 2018
1 parent 7244697 commit ab8739c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# WebChangeNotifier

C#/.NET console Windows app for website content changes detection. Sends nonitifications to email (via [Mailgun HTTP API](https://www.mailgun.com), it is free for up to 10 000 emails/month, credit card or domain are not needed).
C#/.NET console Windows app for website content changes detection. Sends notifications to email (via [Mailgun HTTP API](https://www.mailgun.com), it is free for up to 10 000 emails/month, credit card or domain are not needed).

The project was created because I wanted to monitor changes on several websites (product lists in local stores) and all of the services/apps I found did not have the features I needed or allowed only 1 check per day in free version.
The project was created because I wanted to monitor changes on several websites (product lists in local stores) and all services/apps I found did not have the features I needed or allowed only 1 check per day in free version.

It periodically opens all URLs in the list (in random order) and retrieves content (as text) using the specified selector. If the content changed since the last time, then it sends email notification with number of inserted/deleted lines and **DIFF** text file. Also it sends notifications about errors (if repeated more than once in a row) such as when the website is down or the content is not found.

Binary (\*.exe) can be downloaded in [Releases](https://github.com/AlexP11223/WebChangeNotifier/releases). Targets .NET Framework 4.5.2 (probably can be built with earlier versions, but you may need to reinstall some NuGet packages).

## Requerements
## Requirements

Uses Chrome via Selenium, requires **chromedriver** from https://sites.google.com/a/chromium.org/chromedriver/downloads in the app dir or in PATH (it is included in the release and added via [this NuGet package](https://github.com/AlexP11223/nupkg-selenium-webdrivers) in the project, but it may become outdated).

Expand All @@ -22,11 +22,11 @@ Some notable properties:

- Global
- **Delay** - pause in seconds before repeating. That is it runs all tasks and then pauses for this amount of time.
- **BrowserRestartPeriod** (default `100`) - how often the web browser will be restarted. That is if set to 100, it will be restarted after every 100 iteration. 0 disables restarts. It was implemented because using the same instance of web browser/Selenium WebDriver for a very long time in some cases may result in significant memory leaks or performance issues.
- **BrowserRestartPeriod** (default `100`) - how often the web browser will be restarted. That is if set to 100, it will restart on every 100th iteration. 0 disables restarts. It was implemented because using the same instance of web browser/WebDriver for a very long time in some cases may result in significant memory leaks or performance issues.
- Tasks
- **MinDelay** (optional) - can be used to slowdown some tasks (to avoid bans, captchas etc.). For example, if `Delay` is 300 and `MinDelay` for one task is 900, then this task will skip some checks while 900 seconds are not elapsed since its' last check.
- **AllowEmptyContent** and **SkipUntilNextCheckIfEmpty** (optional, default `false`) - `AllowEmptyContent` determines behavior when the specified element is empty (no text). If `false`, then it waits up to 20 sec and reloads the page if it is still empty before reporting this change (if needed), if `SkipUntilNextCheckIfEmpty` is also `true` then it reports such change only when it happens during two consecutive checks of the tasks. If `true`, then it just reports the change as normally.
The former behavior was needed for one website that loads the content via ajax, sometimes (every few hours) the content was empty for some reason (so I would get a report about empty content and then in the next check another report that everything returned back), however for some tasks empty content can be totally normal and exptected.
The former behavior was needed for one website that loads the content via ajax, sometimes (every few hours) the content was empty for some reason (so I would get a report about empty content and then in the next check another report that everything returned back), however for some tasks empty content can be totally normal and expected.

Paths for config, state files and directory to store browser data can be passed via cmd parameters. By default they are `config.json`, `state.json` and `browser_data\` (relative to the working dir).

Expand Down

0 comments on commit ab8739c

Please sign in to comment.