{"id":17868075,"url":"https://github.com/sayyid5416/generalpy","last_synced_at":"2025-03-21T11:31:24.519Z","repository":{"id":65454203,"uuid":"591987502","full_name":"sayyid5416/generalpy","owner":"sayyid5416","description":"Python package for general classes and methods","archived":false,"fork":false,"pushed_at":"2024-06-15T11:15:27.000Z","size":328,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-18T00:43:46.590Z","etag":null,"topics":["python","python-library","python-package","python3"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/generalpy/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sayyid5416.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-01-22T15:26:06.000Z","updated_at":"2024-06-15T06:36:20.000Z","dependencies_parsed_at":"2023-02-16T18:45:44.760Z","dependency_job_id":"96ebadfe-109f-4144-a10b-0c2e559203c9","html_url":"https://github.com/sayyid5416/generalpy","commit_stats":{"total_commits":149,"total_committers":2,"mean_commits":74.5,"dds":"0.12751677852348997","last_synced_commit":"67fcbc550f93f9bd15151cb76572780f3370282b"},"previous_names":[],"tags_count":33,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sayyid5416%2Fgeneralpy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sayyid5416%2Fgeneralpy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sayyid5416%2Fgeneralpy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sayyid5416%2Fgeneralpy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sayyid5416","download_url":"https://codeload.github.com/sayyid5416/generalpy/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244790711,"owners_count":20510794,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["python","python-library","python-package","python3"],"created_at":"2024-10-28T09:56:49.400Z","updated_at":"2025-03-21T11:31:24.035Z","avatar_url":"https://github.com/sayyid5416.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/sayyid5416/generalpy/actions/workflows/publish.yml\"\u003e\u003cimg src=\"https://github.com/sayyid5416/generalpy/actions/workflows/publish.yml/badge.svg\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://pypi.org/project/generalpy\"\u003e\u003cimg alt=\"PyPI\" src=\"https://img.shields.io/pypi/v/generalpy?label=PyPI%20Package%20Version\u0026logo=pypi\u0026logoColor=white\u0026style=plastic\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n### 🔰 generalpy\n- Python package for general classes and methods\n- Install using `pip install generalpy`\n\n\n---\n\n\n### 💠 `Api_Call` class\n  - Handles API call in easy way\n\n\n### 💠 `Attrib` class _(windows OS only)_\n  - Handles the `attrib` command.\n  - To set/modify/remove the `A/H/I/R/S` attributes for files/folders.\n  - Use `attrib /?` in CMD for more info.\n\n\n### 💠 `CustomLogging` class\n  - Class to handle logging in easy way.\n  - All logging class features + more.\n  - Compact \u0026 Full formatting are applied wherever applicable.\n  - Stream logging to Terminal.\n  - File logging: For all logs, and error logs in different files.\n  - You can also set different time zone for `%(asctime)s`.\n\n\n### 💠 `DatabaseCollection` class\n  - Handles the data of a collection `collectionName` in some database.\n  - This database will be in memory, but you can extend this functionality by using this class as a base class.\n  - And you can create a class which handles db locally or on cloud like MongoDB.\n  - **Database** structure should be: `DataBase \u003e collection \u003e collection-data`.\n  - Structure of **collection-data**: `dict[str, dict[str, Any]]` i.e `dataID: {dataType: dataValue, ...}, ...`\n\n\n### 💠 `ICACLS` class _(windows OS only)_\n  - Handles functions related to `icacls` command.\n  - To set/modify/remove the permissions for files/folders.\n  - Use `icacls /?` in CMD for more info.\n\n\n### 💠 `IgnoreError(Exception)` class\n  - This exception should be ignored after catching it for the sake of continuity.\n  - You can ignore it in `try: ... except IgnoreError: pass` block, or\n  - By logging/printing to console.\n\n\n### 💠 `LevelFormatter` class\n  - Custom `logging.Formatter` class.\n  - To set formatting based on logging Levels. Like `logging.INFO`, `logging.ERROR` etc.\n  - You can also set different time zone for `%(asctime)s`\n\n\n### 💠 `Settings` class\n  - Handles all settings related aspect for an app.\n  - Based on settings file stored in storage.\n\n\n### 💠 `Signal` class\n  - A signal object that can be used to connect callback.\n  - Simply connect a callback using `.connect(...)` method.\n  - Emit the signal using `.emit(...)` method.\n\n\n### 💠 `TaskList` class _(windows OS only)_\n  - Handles functions related to `tasklist` command.\n  - Get running tasks/executables.\n  - Check if an exe is running or not, or how many of it's instances are running.\n\n\n---\n\n\n### 💠 `ctypes` module\n  This module contains functions and methods related to ctypes\n  - `run_ShellExecuteW`: Runs `ShellExecuteW` command. _(windows_only)_\n  - `running_as_admin`: Checks if current app is running as admin. _(windows_only)_\n  - `set_app_user_model_id`: Sets the App User Model ID for the current process. _(windows_only)_\n  \n### 💠 `decorator` module\n  This module contains decorators\n  - `combine_single_items`: Combine item of sublists _(which contain only one item)_ into a single sublist.\n  - `conditional`: Run decorated function and return it's value, only if provided condition is True.\n  - `log_it`: Logs the functionality and the time taken by decorated function.\n  - `platform_specific`: Run decorated function only if current platform is one of the `supportedPlatforms`\n  - `retry_support`: Retry the decorated function gracefully.\n  - `run_threaded`: Run decorated function in a new thread.\n\n\n### 💠 `files` module\n  This module contains methods to work with files\n  - `delete_files_by_condition`: Deletes all files in directory and its subdirectories according to some condition.\n  - `delete_files_by_prefix_suffix`: Deletes all files in directory and its subdirectories according to prefix/suffix in their name.\n  - `get_new_path`: Returns new filePath for files _(which do not exist)_ by appending (1/2/3/..).\n  - `get_random_file_path`: Returns a random path of a file _(which do not exist)_ in parentDirectory.\n  - `get_unsupported_file_path_chars`: Returns A list of characters which can't used in file names _(windows_only)_\n  - `read_file_chunks`: Read file and returns possible data chunk by chunk.\n  - `sanitised_filename`: Sanitize filename by replacing unsupported or non-printable characters. _(windows_only)_\n\n\n### 💠 `general` module\n  This module contains general methods\n  - `first_capital`: Make first letter capital without changing any other thing.\n  - `format_bytes`: Returns human readable formats from bytes.\n  - `format_dict`: Returns human readable formats from dict.\n  - `generate_repr_str`: Returns a suitable string for `__repr__` method of classes.\n  - `get_adjusted_color`: Adjusts the brightness of a color in hexadecimal format.\n  - `get_digit_from_text`: Returns the digit from the first occurrence of `(digit)`.\n  - `get_first_non_alphabet`: Returns the first non-alphabet character from string.\n  - `get_installed_fonts`: Returns a list of fonts installed. _(windows_only)_\n  - `is_python`: Returns `True` if current running app is `python`.\n  - `punctuate`: Adds punctuation after string, if not present.\n  - `remove_extra_spaces`: Removed extra spaces between words.\n  - `replace_html_tags`: Replace html tags from a string.\n  - `replace_multiple_chars`: Replace multiple characters from a string.\n  - `similarized`: Takes a list of strings and returns a list of sublists of similar-strings.\n  - `sliced_list`: Slice a list into a list of sublists, where each sublist contains specific no. of items.\n  - class `Calender_Class`: Class Containing functions related to Calendar","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsayyid5416%2Fgeneralpy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsayyid5416%2Fgeneralpy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsayyid5416%2Fgeneralpy/lists"}