FreshPointCLI


NameFreshPointCLI JSON
Version 0.2.0 PyPI version JSON
download
home_pageNone
SummaryFreshPoint webpage CLI interface.
upload_time2024-07-21 12:22:11
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseMIT License Copyright (c) 2023 Konstantin Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords freshpoint freshpoint.cz
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # FreshPointCLI
Welcome to FreshPointCLI, your go-to REPL tool for querying *my.freshpoint.cz*
product webpages from your terminal.

FreshPointCLI is based on the [FreshPointSync](https://freshpointsync.readthedocs.io)
project.

## Key Features

🔎 **Continuous Querying**. Effortlessly check product availability, prices,
and more without restarting the application.

🆎 **Query Autocompletion**. Enjoy intelligent completion suggestions and
highlighting for query arguments and product data, like names and categories.

📜 **Search History**. Easily access your previous searches and receive
history-based autocompletion suggestions.

💎 **Rich Formatting**. Receive vibrant and visually appealing query responses
with a retro aesthetic, powered by Rich.

## Installation

### Prerequisites

FreshPointCLI requires Python 3.8 or higher. If you don't have Python installed,
you can download it from the [official website](<https://www.python.org/downloads/>).

### FreshPointCLI Installation

Official library releases can be found on
[📦 PyPI](<https://pypi.org/project/freshpointcli/>). To install
the latest stable version of FreshPointCLI, use the following CLI command:

```console
$ pip install freshpointcli --upgrade
```

To install the latest development version directly from the project's
[📁 GitHub repository](https://github.com/mykhakos/FreshPointCLI>), use
the following CLI command:

```console
$ pip install git+https://github.com/mykhakos/FreshPointCLI
```

## Usage

FreshPointCLI focuses on providing an intuitive and responsive command line
interface, following standard CLI conventions.

### Starting Up the Application

Initialize the application using the following CLI command:

```console
$ freshpoint <location_id>
```

`<location_id>` is the ID of the FreshPoint location to track. It can be deduced
from the page URL. For example, for `https://my.freshpoint.cz/device/product-list/296`,
the location ID is *296*.

The location ID is preserved between the application sessions, so if you intend
to track the same location as the last time, you can omit the location ID argument
and invoke the application without providing it.

Invoke the application with `--help` to receive a usage tutorial:

```console
$ freshpoint --help
```

### Querying the Product Page

Once the application is running, it displays an input prompt, and you can type
in queries to check for products' availability, price, and more.

```console
FreshPoint@LocationName> ... <-- submit your query here
```

> **Note**: `LocationName` is a placeholder for an actual location name.

#### Querying for a Single Product

To query for a single product, type in the product name and press `↵ Enter`.
For example, a query for tiramisu would be:

```console
FreshPoint@LocationName> tiramisu 
```

The product name does not need to be an exact match or include diacritics.
FreshPointCLI uses lowercase ASCII partial matching, meaning the formatted query
string must be a part of the complete formatted product name to qualify as a match.
This method applies to any string matching within the application. If there are
several matches, the application will display a list of all corresponding results.

For example, query "`kolac`" would return products such as
"**Koláč** s náplněmi 100 g" or "Pošírovaná krůtí rolka v bylinkách,
polentový **koláč**ek s variací sýrů, zeleninová caponata".

#### Querying with Product Attribute Options

To query for products with specific attributes, use flags and options starting
with a hyphen, such as `--category`, `--available`, or `--price-max <price>`,
and press `↵ Enter`. For example, to query for all available listings in
the category "Dezerty, snídaně" under 80 CZK, use the following command:

```console
FreshPoint@LocationName> --category dezerty --available --price-max 80
```

Each option has a short form, starting with a single hyphen ('`-`'), and a long
form, starting with a double hyphen ('`--`'). They are equivalent. Some options
require a value. For example, the `--price-max <price>` option requires
a non-negative number.

You can get a list of all supported options and their usage instructions by
invoking the `--help` command in a query.

```console
FreshPoint@LocationName> --help
```

#### Using Autocomplete and Query History

Autocomplete suggestions will be displayed as you type. You can use `Tab ↹` or
the `↑` and `↓` arrow keys to navigate through the suggestions.

Before you start typing, you can use `↑` and `↓` arrow keys to navigate through
the history of commands you have executed previously.

#### Setting a Default Query

If you submit an empty query, all the products on the page are returned by default.
You can change this behavior by using the `--setdefault` flag in a query. Once you
submit a query with `--setdefault`, that query will be used as the default whenever
you submit an empty query.

## Contributing

FreshPointCLI is an open-source project in its early development stages. If you
encounter any issues or have suggestions for improvements, please report them on
the [GitHub Issue tracker](https://github.com/mykhakos/FreshPointCLI/issues).

Contributions to FreshPointCLI are also welcome! If you would like
to contribute, please fork the repository, implement your changes, and open
a Pull Request with a detailed description of your work on the
[GitHub Pull Request page](https://github.com/mykhakos/FreshPointCLI/pulls).

## License

FreshPointCLI is distributed under the MIT License.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "FreshPointCLI",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "freshpoint, freshpoint.cz",
    "author": null,
    "author_email": "Konstantin Mykhailov <constantinemykhailov@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/1e/b7/4f33af5786d4e0bce739692129a9fef613255e826a25b3b884c0011d46f8/freshpointcli-0.2.0.tar.gz",
    "platform": null,
    "description": "# FreshPointCLI\r\nWelcome to FreshPointCLI, your go-to REPL tool for querying *my.freshpoint.cz*\r\nproduct webpages from your terminal.\r\n\r\nFreshPointCLI is based on the [FreshPointSync](https://freshpointsync.readthedocs.io)\r\nproject.\r\n\r\n## Key Features\r\n\r\n\ud83d\udd0e **Continuous Querying**. Effortlessly check product availability, prices,\r\nand more without restarting the application.\r\n\r\n\ud83c\udd8e **Query Autocompletion**. Enjoy intelligent completion suggestions and\r\nhighlighting for query arguments and product data, like names and categories.\r\n\r\n\ud83d\udcdc **Search History**. Easily access your previous searches and receive\r\nhistory-based autocompletion suggestions.\r\n\r\n\ud83d\udc8e **Rich Formatting**. Receive vibrant and visually appealing query responses\r\nwith a retro aesthetic, powered by Rich.\r\n\r\n## Installation\r\n\r\n### Prerequisites\r\n\r\nFreshPointCLI requires Python 3.8 or higher. If you don't have Python installed,\r\nyou can download it from the [official website](<https://www.python.org/downloads/>).\r\n\r\n### FreshPointCLI Installation\r\n\r\nOfficial library releases can be found on\r\n[\ud83d\udce6 PyPI](<https://pypi.org/project/freshpointcli/>). To install\r\nthe latest stable version of FreshPointCLI, use the following CLI command:\r\n\r\n```console\r\n$ pip install freshpointcli --upgrade\r\n```\r\n\r\nTo install the latest development version directly from the project's\r\n[\ud83d\udcc1 GitHub repository](https://github.com/mykhakos/FreshPointCLI>), use\r\nthe following CLI command:\r\n\r\n```console\r\n$ pip install git+https://github.com/mykhakos/FreshPointCLI\r\n```\r\n\r\n## Usage\r\n\r\nFreshPointCLI focuses on providing an intuitive and responsive command line\r\ninterface, following standard CLI conventions.\r\n\r\n### Starting Up the Application\r\n\r\nInitialize the application using the following CLI command:\r\n\r\n```console\r\n$ freshpoint <location_id>\r\n```\r\n\r\n`<location_id>` is the ID of the FreshPoint location to track. It can be deduced\r\nfrom the page URL. For example, for `https://my.freshpoint.cz/device/product-list/296`,\r\nthe location ID is *296*.\r\n\r\nThe location ID is preserved between the application sessions, so if you intend\r\nto track the same location as the last time, you can omit the location ID argument\r\nand invoke the application without providing it.\r\n\r\nInvoke the application with `--help` to receive a usage tutorial:\r\n\r\n```console\r\n$ freshpoint --help\r\n```\r\n\r\n### Querying the Product Page\r\n\r\nOnce the application is running, it displays an input prompt, and you can type\r\nin queries to check for products' availability, price, and more.\r\n\r\n```console\r\nFreshPoint@LocationName> ... <-- submit your query here\r\n```\r\n\r\n> **Note**: `LocationName` is a placeholder for an actual location name.\r\n\r\n#### Querying for a Single Product\r\n\r\nTo query for a single product, type in the product name and press `\u21b5 Enter`.\r\nFor example, a query for tiramisu would be:\r\n\r\n```console\r\nFreshPoint@LocationName> tiramisu \r\n```\r\n\r\nThe product name does not need to be an exact match or include diacritics.\r\nFreshPointCLI uses lowercase ASCII partial matching, meaning the formatted query\r\nstring must be a part of the complete formatted product name to qualify as a match.\r\nThis method applies to any string matching within the application. If there are\r\nseveral matches, the application will display a list of all corresponding results.\r\n\r\nFor example, query \"`kolac`\" would return products such as\r\n\"**Kol\u00e1\u010d** s n\u00e1pln\u011bmi 100 g\" or \"Po\u0161\u00edrovan\u00e1 kr\u016ft\u00ed rolka v bylink\u00e1ch,\r\npolentov\u00fd **kol\u00e1\u010d**ek s variac\u00ed s\u00fdr\u016f, zeleninov\u00e1 caponata\".\r\n\r\n#### Querying with Product Attribute Options\r\n\r\nTo query for products with specific attributes, use flags and options starting\r\nwith a hyphen, such as `--category`, `--available`, or `--price-max <price>`,\r\nand press `\u21b5 Enter`. For example, to query for all available listings in\r\nthe category \"Dezerty, sn\u00eddan\u011b\" under 80 CZK, use the following command:\r\n\r\n```console\r\nFreshPoint@LocationName> --category dezerty --available --price-max 80\r\n```\r\n\r\nEach option has a short form, starting with a single hyphen ('`-`'), and a long\r\nform, starting with a double hyphen ('`--`'). They are equivalent. Some options\r\nrequire a value. For example, the `--price-max <price>` option requires\r\na non-negative number.\r\n\r\nYou can get a list of all supported options and their usage instructions by\r\ninvoking the `--help` command in a query.\r\n\r\n```console\r\nFreshPoint@LocationName> --help\r\n```\r\n\r\n#### Using Autocomplete and Query History\r\n\r\nAutocomplete suggestions will be displayed as you type. You can use `Tab \u21b9` or\r\nthe `\u2191` and `\u2193` arrow keys to navigate through the suggestions.\r\n\r\nBefore you start typing, you can use `\u2191` and `\u2193` arrow keys to navigate through\r\nthe history of commands you have executed previously.\r\n\r\n#### Setting a Default Query\r\n\r\nIf you submit an empty query, all the products on the page are returned by default.\r\nYou can change this behavior by using the `--setdefault` flag in a query. Once you\r\nsubmit a query with `--setdefault`, that query will be used as the default whenever\r\nyou submit an empty query.\r\n\r\n## Contributing\r\n\r\nFreshPointCLI is an open-source project in its early development stages. If you\r\nencounter any issues or have suggestions for improvements, please report them on\r\nthe [GitHub Issue tracker](https://github.com/mykhakos/FreshPointCLI/issues).\r\n\r\nContributions to FreshPointCLI are also welcome! If you would like\r\nto contribute, please fork the repository, implement your changes, and open\r\na Pull Request with a detailed description of your work on the\r\n[GitHub Pull Request page](https://github.com/mykhakos/FreshPointCLI/pulls).\r\n\r\n## License\r\n\r\nFreshPointCLI is distributed under the MIT License.\r\n",
    "bugtrack_url": null,
    "license": "MIT License  Copyright (c) 2023 Konstantin  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ",
    "summary": "FreshPoint webpage CLI interface.",
    "version": "0.2.0",
    "project_urls": {
        "Homepage": "https://github.com/mykhakos/FreshPointCLI"
    },
    "split_keywords": [
        "freshpoint",
        " freshpoint.cz"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "881d45cb60b15edcc62f9b38ed50026564d742596a139096ab682e58d829070b",
                "md5": "19671837bc9455ea1a4bcb5e552f8d84",
                "sha256": "4fb79d0764fd5a58617edd6150dea846797d6e1df1a6f74386e35f10ed24d022"
            },
            "downloads": -1,
            "filename": "FreshPointCLI-0.2.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "19671837bc9455ea1a4bcb5e552f8d84",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 21547,
            "upload_time": "2024-07-21T12:22:10",
            "upload_time_iso_8601": "2024-07-21T12:22:10.408547Z",
            "url": "https://files.pythonhosted.org/packages/88/1d/45cb60b15edcc62f9b38ed50026564d742596a139096ab682e58d829070b/FreshPointCLI-0.2.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "1eb74f33af5786d4e0bce739692129a9fef613255e826a25b3b884c0011d46f8",
                "md5": "7ee1ccb1095d6b53387f027a02e5b017",
                "sha256": "8c64af462e8e033049872ecc9cf5c114abd32b92b869ddc6516aa30d75a67850"
            },
            "downloads": -1,
            "filename": "freshpointcli-0.2.0.tar.gz",
            "has_sig": false,
            "md5_digest": "7ee1ccb1095d6b53387f027a02e5b017",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 16419,
            "upload_time": "2024-07-21T12:22:11",
            "upload_time_iso_8601": "2024-07-21T12:22:11.712235Z",
            "url": "https://files.pythonhosted.org/packages/1e/b7/4f33af5786d4e0bce739692129a9fef613255e826a25b3b884c0011d46f8/freshpointcli-0.2.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-07-21 12:22:11",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "mykhakos",
    "github_project": "FreshPointCLI",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "tox": true,
    "lcname": "freshpointcli"
}
        
Elapsed time: 0.30073s