semvec/pypi-packages huggingface dataset:
conftext 0.0.12
conftext - helper for managing configuration contexts

========
conftext
========
This package contains a couple of mudules:

* conftext - a helper for managing configuration contexts.
* conf_ini - unified configuration handling for ini files.


conftext
========

Motivation
----------
Imagine handling multi-tenant services, that each require certain config contexts to be specified
for using them (think db connection information for instance). A "configuration matrix" if you like.
The parameters of these config options are the same, but their values differ. You are creating CLI
tools for working with these services and find yourself doing:

.. code-block:: shell

   $ some_task1(db_host=service_A_ip, db_name=service_A_name, param1, param2)
   $ some_task2(db_host=service_A_ip, db_name=service_A_name)
   $ some_task3(db_host=service_A_ip, db_name=service_A_name, param1)
   
   $ some_task1(db_host=service_B_ip, db_name=service_B_name, param1, param2)
   $ some_task2(db_host=service_B_ip, db_name=service_B_name)
   $ some_task3(db_host=service_B_ip, db_name=service_B_name, param1)

This small library intends to help bring things back to:

.. code-block:: shell

   $ some_task1(param1, param2)
   $ some_task2()
   $ some_task3(param1)

This is just an example. The tool is meant to be generic and is not nescessarily only made for this
particular use case.

Operation
---------
This tool works by providing a way to persist configuration coordinates that can be used to look up
the appropriate configuration in the "configuarion matrix". The configuration coordinates are stored
in a file at well-known location (look at current dir, then traverse upwards in file hierarchy until
`/` or `~/.config/conftext.ini`).

A command-line tool, also called conftext, can be used to show and manipulate the conftext file.

Usage
-----
Use `get_config` in code where context-aware config should be loaded. The conftext invoke task can
then be used to switch the context config.

Example in code:

.. code-block:: python

   defaults = dict(
       service='dummy',
       context='local')
   
   config = Conftext(section='package.module', default_config=defaults)

Command-line usage:

.. code-block:: shell

   $ conftext show
   $ conftext set --service <someservice>
   $ conftext set --service <someservice> --context <somecontext>

Ideas
-----
* add a enter task for the CLI tool that will enter the conf context?
   - when inside conf context, consider modifying the prompt to show vital context config
   - add exit task as well
* add python prompt with config context as well?


conf_ini
========

Provides unified configuarion for ini files.

Currently, this means that the configuration for a given package/module is expected to be found in::

    ~/.config/<package>/<module>.ini

and that the file is expected to in a `.ini` format that can be parsed by the configparser of the
python standard library.
PyPk-Client 0.0.2a1
NOTICE:You'l need the the PyPK_Server Module To use this

<blockquote align="center"><i><strong>NOTE:</i>This is Provided by Hassan Aldarkazali</strong></blockquote>
<br>
<h1 align="center">PYPK CLIENT<h3 align="center">"We are clients digitally and physically"</h3></h1>
<p>So what this is the client for project PyPk(Python Pepole Keeper)</p>

* Commands

<p>Run it with the commmand:<code>python -m PyPk_Client</code></p>

# CHANGELOG
> v.0.0.1.dev

Initial release<br>
Added:

* <h6>__main__.py</h6>
auto-py-input 0.0.1
Input autocompletion
Requires Python: >=3.10

## AutoPyInput

- For Windows
- Requires Python >= 3.10
- Autocomplete words while user input
- Use Tab or arrow keys to cycle through choices

## Usage

```
from autopyinput.word_complete import Wordcompleter
import autopyinput.utils as au

# Custom words
word_list = ['hello', 'world', 'word', 'hi']
wcompleter = Wordcompleter(word_list)
input_ = wcompleter.prompt(prompt_ = ">>")
```

```
# Clean up and use string
doc = '''
#hello world!
def main():
  print("hello world")
main()
'''

word_list = au.string_to_words(au.clean(doc))
wcompleter = Wordcompleter(word_list)
input_ = wcompleter.prompt(prompt_ = ">>")
```

```
# Clean up and use file data
doc = "example.txt"

word_list = au.file_to_words(doc)
wcompleter = Wordcompleter(word_list)
input_ = wcompleter.prompt(prompt_ = ">>")
```
Known issue: Displays nothing when the display is the same length as your terminal width, but input is saved so it is safe to click "Enter" and get input.
AllUtils 1.0.1
A light weight command line menu that supports Windows, MacOS, and Linux
Keywords: python


# My Package



A brief description of what my package does.



## Installation



To install my package, simply run:



```bash

pip install your_package_name

Usage

Here's how to use my package:



python

from my_package import some_function



result = some_function('some arguments')

print(result)

Contributing

Please contribute to this project by following the guidelines in CONTRIBUTING.md.
text-processor-nlp 0.1
A short description of the package

# TextPreprocessor

`TextPreprocessor` is a Python package for advanced text preprocessing. It provides various methods for cleaning, normalizing, and tokenizing text data. The package relies on the spaCy library for natural language processing tasks.

## Features

- **Text Cleaning:** Remove HTML tags, special characters, and extra whitespaces.
- **Lowercasing:** Convert text to lowercase.
- **Tokenization:** Tokenize text into words and sentences.
- **Stop Words Removal:** Remove common stop words from tokenized text.
- **Normalization:** Lemmatize tokens to their base forms.
- **Punctuation Handling:** Remove punctuation from text.
- **Number Removal:** Remove numerical digits from text.

## Installation

To use the `TextPreprocessor` package, you need to install both the package and its dependencies. You can do this using pip:

```bash
pip install textpreprocessor
py-auto-input 0.0.1
Input autocompletion
Requires Python: >=3.10

## Auto-input

- For Windows
- Requires Python >= 3.10
- Autocomplete words while user input
- Use Tab or arrow keys to cycle through choices

## Usage

```
from auto_input.word_complete import Wordcompleter
import autocomplete.utils as au

# Custom words
word_list = ['hello', 'world', 'word', 'hi']
wcompleter = Wordcompleter(word_list)
input_ = wcompleter.prompt(prompt_ = ">>")
```

```
# Clean up and use string
doc = '''
#hello world!
def main():
  print("hello world")
main()
'''

word_list = au.string_to_words(au.clean(doc))
wcompleter = Wordcompleter(word_list)
input_ = wcompleter.prompt(prompt_ = ">>")
```

```
# Clean up and use file data
doc = "example.txt"

word_list = au.file_to_words(doc)
wcompleter = Wordcompleter(word_list)
input_ = wcompleter.prompt(prompt_ = ">>")
```
d-link 0.2.4
A Python library to extract data from a Python script and push it to a GitHub Pages repository.
Requires Python: >=3.6

# D-link

`d-link` is a Python library designed to extract data from a Python script and push it to a GitHub Pages repository. This allows you to dynamically update content on your GitHub Pages site based on values from your Python code.

## Features

- Extract constants and other data from Python scripts.
- Push extracted data to a GitHub Pages repository.
- Easy setup and configuration.

## Installation

You can install the `d_link` library using pip:

```bash
pip install d_link
```

## Usage

### 1. Configure the Repository

First, configure the GitHub repository URL and authentication token:

```python
from d_link import DataToGitHub

# Initialize DataToGitHub with the path to your Python script
data_to_github = DataToGitHub(script_path="path/to/your/script.py")

# Configure the repository (run this once)
data_to_github.configure_repository()

# Optionally, display current settings
data_to_github.display_settings()
```

### 2. Push Data to GitHub

Once configured, you can push data from your Python script to GitHub Pages:

```python
from d_link import DataToGitHub

# Initialize DataToGitHub with the path to your Python script
data_to_github = DataToGitHub(script_path="path/to/your/script.py")

# Push data from the Python script to GitHub Pages
data_to_github.push_data()
```

## Configuration

The `configure_repository` method prompts you to enter:

- **GitHub Repository URL**: The URL of the GitHub repository where you want to push data.
- **GitHub Personal Access Token**: Used for authentication with GitHub.

Ensure that the GitHub Pages site is set up to display or use the data in `data.json`.

## Troubleshooting

- **Library Not Found**: Ensure the library is installed with `pip install d_link`. Verify installation with `pip show d_link`.
- **Path Issues**: Confirm that the file paths in your script are correct and accessible.
- **Authentication Errors**: Verify your GitHub personal access token and repository URL are accurate and have the necessary permissions.

## Contributing

Contributions are welcome! Please fork the repository and submit a pull request with your changes.

## License

This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.

## Contact

For any questions or issues, please open an issue on the [GitHub repository](https://github.com/PgNetwork01/d-link) or contact [Web Wizard](mailto:wert.ed00@gmail.com).
```
FileHarvestor 1.0.3
FileHarvestor is a Python utility that reads the contents of specified files and writes them to both text and markdown files. If a file does not exist, it is added to a list of not found files. This tool is useful for consolidating and documenting the contents of multiple files in a directory.
Requires Python: >=3.6
Keywords: file, harvestor, read, write, text, markdown, file-reader, read-file

# FileHarvestor

This script is a Python utility that reads the contents of specified files and writes them to both text and markdown files. If a file does not exist, it is added to a list of not found files. This tool is useful for consolidating and documenting the contents of multiple files in a directory.

## Features

- Reads the contents of specified files.
- Writes the contents to both a text file (`contents.txt`) and a markdown file (`contents.md`).
- Handles non-existent files and maintains a list of files that were not found.
- Provides a summary of the process, including read times for each file and overall execution time.

## How it works

1. The script takes a list of file paths as input and iterates through each file.
2. For each file, it checks if it exists, reads its contents, and writes the contents to both a text file and a markdown file.
3. If a file is not found, it is added to a list of not found files.
4. The script provides detailed output about the success or failure of reading each file and summarizes the overall process at the end.

Function arguments:

- **file_list (list, optional):** List of files to read. Defaults to None.
- **output_text_file (str, optional):** Output text file. Defaults to './output/contents.txt'.
- **output_markdown_file (str, optional):** Output markdown file. Defaults to './output/contents.md'.

## Usage

1. Install the `FileHarvestor` package from PyPI using pip:

   ```bash
   pip install FileHarvestor
   ```

   OR

   Clone or download the `FileHarvestor.py` script to your local machine.

   ```bash
   git clone https://github.com/Hardvan/FileHarvestor
   cd FileHarvestor
   pip install .
   ```

2. Call the `read_files_in_directory` function from the `FileHarvestor` package with the directory path as an argument.

   ```python
   from FileHarvestor import read_files_in_directory

   read_files(file_list=['./path/to/file1.txt', './path/to/file2.txt'], output_text_file='./output/contents.txt', output_markdown_file='./output/contents.md')
   ```

   View the `run.py` file for an example of how to use the `FileHarvestor` package.
iranholidays 0.2.4
provides functions to tell if a date is a holiday in Iran or not
Requires Python: >=3.11

``iranholidays`` is a small python library that provides functions to check if a date is a holiday in Iran or not. 

**Warning:** For Islamic holidays, like Eid al-Fitr, the calculation may be off by a day or two since those events depend on seeing the moon by naked eye and cannot be predicted by computers.

Usage
-----

.. code-block:: python

    from iranholidays import holiday_occasion

    assert holiday_occasion((2024, 4, 1, 'G')) == 'Sizdah Be-dar'  # Gregorian
    assert holiday_occasion((1403, 1, 13, 'S')) == 'Sizdah Be-dar'  # Solar
    assert holiday_occasion((1403, 1, 14, 'S')) is None
    assert holiday_occasion((1445, 9, 21, 'L')) == 'Martyrdom of Ali'  # Lunar


In case you have a date object from the following libraries, you can check it directly using one of the ``off_occasion_*`` functions:

.. code-block:: python

    import datetime

    import hijri_converter
    import jdatetime

    from iranholidays import (
        off_occasion_gregorian,
        off_occasion_lunar,
        off_occasion_solar,
    )

    date = datetime.date(2024, 4, 1)
    assert off_occasion_gregorian(date, weekend=()) == 'Sizdah Be-dar'

    date = jdatetime.date(1403, 1, 13)
    assert off_occasion_solar(date, weekend=()) == 'Sizdah Be-dar'

    date = hijri_converter.Hijri(1445, 9, 21)
    assert off_occasion_lunar(date, weekend=()) == 'Martyrdom of Ali'

``off_occasion`` function checks if a date is a weekend or holiday and returns the occasion string or ``None``. The default value for weekend parameter is ``(4,)`` which means Friday. Either pass a different value to ``weekend`` parameter to override it or use ``set_default_weekend`` function to change this default for all functions:

.. code-block:: python

    from iranholidays import off_occasion, set_default_weekend
    date = (2024, 2, 5, 'G')  # a non-holiday Monday
    assert off_occasion(date) is None
    assert off_occasion(date, weekend=(0,)) == 'Weekend'
    set_default_weekend((0,))  # set default weekends to Thursday and Friday
    assert off_occasion(date) == 'Weekend'