Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/badboy/xshell-venv
xshell-venv manages your Python virtual environments in code.
https://github.com/badboy/xshell-venv
Last synced: 9 days ago
JSON representation
xshell-venv manages your Python virtual environments in code.
- Host: GitHub
- URL: https://github.com/badboy/xshell-venv
- Owner: badboy
- License: mit
- Created: 2022-04-26T20:42:05.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-05-13T12:04:27.000Z (8 months ago)
- Last Synced: 2024-12-24T02:01:40.741Z (12 days ago)
- Language: Rust
- Homepage:
- Size: 21.5 KB
- Stars: 4
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# `xshell-venv`
[![crates.io](https://img.shields.io/crates/v/xshell-venv.svg?style=flat-square)](https://crates.io/crates/xshell-venv)
[![docs.rs docs](https://img.shields.io/badge/docs-latest-blue.svg?style=flat-square)](https://docs.rs/xshell-venv)
[![License: MIT](https://img.shields.io/github/license/badboy/xshell-venv?style=flat-square)](LICENSE)
[![Build Status](https://img.shields.io/github/actions/workflow/status/badboy/xshell-venv/test.yml?style=flat-square)](https://github.com/badboy/xshell-venv/actions/workflows/test.yml)`xshell-venv` manages your Python virtual environments in code.
`xshell-venv` is an extension to [xshell], the swiss-army knife for writing cross-platform “bash” scripts in Rust.
[xshell]: https://docs.rs/xshell/
## Example
```rust
use xshell_venv::{Shell, VirtualEnv};let sh = Shell::new()?;
let venv = VirtualEnv::new(&sh, "py3")?;venv.run("print('Hello World!')")?; // "Hello World!"
```## Requirements
* Python 3
* On Windows we look for `python3.exe` or `python.exe`
* Otherwise we look for `python3` or `python`
* The `venv` package
* This might be available as `python3-venv` or under a similar name.
Double check your packages. E.g. on Ubuntu Python 3.8 is available as `python3.8`
and the corresponding `venv` package is named `python3.8-venv`.## License
[MIT](LICENSE).