CX-tool
This is a collection of utility functions that I have written over the years. I have decided to put them all in one place so that I can easily access them. I have also included a few utility functions that I have found useful from other sources.
Installation
pip install --user cx-tool
Usage
cx-tool install
Write your own plugin
You can add your own plugin that performs a specific task. To do this, you need to create a new Python file in the plugins directory. The file should contain a class that inherits from the Plugin class.
To add click command use the
import click
from cx_tool.plugin import Plugin, clickable, PluginContext
class MyPlugin(Plugin):
name = "my-plugin"
@clickable
def hello(self):
click.echo("Hello, World!")
def on_load(self):
"""This method is called when the plugin is loaded.
Here you can add any initialization code that you need.
"""
self.cli_command("hello")(self.hello)
def on_start(self, ctx: PluginContext):
"""This method is called when the CrossOver app is started.
Here you can add env variables and arguments to CrossOver app.
"""
ctx.environment["HELLO"] = "WORLD"
To access hello click subcommand command use the following command
cx-tool my-plugin hello
Metadata
Release files for cx-tool 0.1.0.39
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| cx_tool-0.1.0.39.tar.gz | 18.5 kB | Without provenance | Details for cx_tool-0.1.0.39.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| cx_tool-0.1.0.39-py3-none-any.whl | Python 3 | none | any | Details for cx_tool-0.1.0.39-py3-none-any.whl |
Total release size: 43.6 kB
Release files / cx_tool-0.1.0.39.tar.gz
| Download URL | cx_tool-0.1.0.39.tar.gz |
|---|---|
| Size | 18.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4fd7b4904c18eb5a9a614774a5ae8e3307e4e4ed58617527bced9e14a646c5f9
|
|
BLAKE2b-256 checksum How to use checksums |
54b575ef8a18a184f49ebf3d601fccbfc84fd581e9dafcdb191d24832e03e8d2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.2 CPython/3.11.1 Darwin/24.0.0
|
Release files / cx_tool-0.1.0.39-py3-none-any.whl
| Download URL | cx_tool-0.1.0.39-py3-none-any.whl |
|---|---|
| Size | 25.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
bd9ab61f1d352684f9538272cdd5864c5c0e64134241d9a9be85cfafec86dc30
|
|
BLAKE2b-256 checksum How to use checksums |
4b1115c257babd3cab16481fc9d224bf1de4c2719725bd31d39896cbe0e50e90
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.2 CPython/3.11.1 Darwin/24.0.0
|
Security for cx-tool 0.1.0.39
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.