Skip to main content

Command output changes monitor

Project description

diffs

GitHub version PyPI version

diffs monitors for any changes in arbitrary shell command output between the initial state and the current output.

Installation

pip3 install diffs

Python 3.6 (or newer) is required.

Usage

diffs CMD

The initial CMD output is stored at the beginning. Then the command is run again periodically and the output is compared against the initial output. If there are differences, they are shown in the standard diff format. The unchaged lines are not shown.

Examples

Show how many packets have been sent since the script has been started:
diffs ifconfig wlp2s0
diffs demo ifconfig

Find new applications opening network ports (shows only changes between the initial state):
diffs sudo netstat -tulpn
diffs demo netstat

Monitor changes in a file:

$ diffs cat /etc/resolv.conf

Difference between starting date and the current date:
diffs date
diffs demo date

Finding newly spawned processes:
diffs ps a -o pid,cmd
diffs demo ps

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

diffs-0.1.1.tar.gz (2.7 kB view hashes)

Uploaded Source

Built Distribution

diffs-0.1.1-py3-none-any.whl (4.5 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page