Skip to main content

Save the NRC front page to a JPG image.

Project description

nrc-to-jpg

PyPI Supported Python Versions pre-commit.ci status Test Documentation Status PyPI - License

Save the NRC front page to a JPG image.

Installation

nrc-to-jpg is available on PyPI. Install with pipx or your package manager of choice:

pipx install nrc-to-jpg

Documentation

Check out the nrc-to-jpg documentation for the User's Guide and CLI Reference.

Usage

Running nrc-to-jpg --help or python -m nrc_to_jpg --help shows a list of all of the available options and arguments:

nrc-to-jpg --help
Usage: nrc-to-jpg [OPTIONS]

  Save the NRC front page to a JPG image.

Options:
  -v, --version                   Show the version and exit.
  -d, --date [%Y-%m-%d|%Y-%m-%dT%H:%M:%S|%Y-%m-%d %H:%M:%S]
                                  The date to save that day\'s front page of.  [default:
                                  2024-06-12]
  -n, --page-number INTEGER       The page number to .  [default: 1]
  -o, --output FORMAT-STR         Output file name template. Allowed fields:
                                  `page_number`, `month`, `day`, `year`  [default:
                                  NRC_front_page_{year:04}-{month:02}-{day:02}.jpg]
  -h, --help                      Show this message and exit.

To save today's front page to NRC_front_page_{year:04}-{month:02}-{day:02}.jpg, simply use nrc-to-jpg without any options:

nrc-to-jpg

To save the front page for a different date than today, use the --date option:

nrc-to-jpg --date 2001-09-12

To save a page other than the front page, use the --page-number option:

nrc-to-jpg --page-number 2

This will still save the specified page to NRC_front_page_{year:04}-{month:02}-{day:02}.jpg. You might want to customize the output template using the --output option:

nrc-to-jpg --page-number 2 --output NRC_{page_number}nd_page_{year:04}-{month:02}-{day:02}.jpg

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

nrc_to_jpg-2024.6.0.tar.gz (13.4 kB view hashes)

Uploaded Source

Built Distribution

nrc_to_jpg-2024.6.0-py3-none-any.whl (6.9 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