You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Could you introduce an option in uv to allow running scripts defined in a configuration file, similar to the functionality provided by PDM and Rye.
Background
Both PDM and Rye offer functionality to define and run custom scripts directly from their configuration files. This feature simplifies the development process by enabling the execution of common tasks (e.g., testing, building, deploying) through a unified command interface.
For example:
PDM uses the [tool.pdm.scripts] section in the pyproject.toml file to define scripts.
Rye allows script definitions under [tool.rye.scripts] in the pyproject.toml.
Proposal
Add similar functionality to uv that allows users to define scripts in a configuration file (e.g., pyproject.toml) and execute them via a simple uv command.
Benefits
Consistency: Users familiar with tools like PDM and Rye will have a consistent experience.
Convenience: Simplifies the process of running repetitive tasks, improving developer productivity.
Automation: Encourages the automation of common project tasks, reducing manual overhead.
Suggested Implementation
Configuration: Introduce a section in the pyproject.toml (or equivalent config file) under [tool.uv.scripts] where users can define scripts.
Example:
[tool.uv.scripts]
test = "pytest tests/"build = "python setup.py sdist bdist_wheel"
Command Execution: Add a command to uv that can execute these scripts. For example:
uv run test
uv run build
The text was updated successfully, but these errors were encountered:
Could you introduce an option in
uv
to allow running scripts defined in a configuration file, similar to the functionality provided by PDM and Rye.Background
Both PDM and Rye offer functionality to define and run custom scripts directly from their configuration files. This feature simplifies the development process by enabling the execution of common tasks (e.g., testing, building, deploying) through a unified command interface.
For example:
[tool.pdm.scripts]
section in thepyproject.toml
file to define scripts.[tool.rye.scripts]
in thepyproject.toml
.Proposal
Add similar functionality to
uv
that allows users to define scripts in a configuration file (e.g.,pyproject.toml
) and execute them via a simpleuv
command.Benefits
Suggested Implementation
Configuration: Introduce a section in the
pyproject.toml
(or equivalent config file) under[tool.uv.scripts]
where users can define scripts.Example:
Command Execution: Add a command to
uv
that can execute these scripts. For example:The text was updated successfully, but these errors were encountered: