#toolchain #packages #create #containing #install #file #toml

bin+lib rust-pkg-gen

Creates so-called rust 'packages' containing rust toolchains and crates

2 stable releases

1.2.0 Dec 27, 2024
1.1.0 Dec 27, 2024

#902 in Parser implementations

Download history 168/week @ 2024-12-25 54/week @ 2025-01-01

222 downloads per month

MIT/Apache

6.5MB
1.5K SLoC

Rust 1K SLoC // 0.0% comments Shell 354 SLoC // 0.1% comments PowerShell 151 SLoC

Contains (Windows DLL, 2MB) 7z64.dll, (Windows DLL, 1.5MB) src/install/7Zip4Powershell/2.7.0/7z.dll, (Windows DLL, 2MB) SevenZipSharp.dll, (Windows DLL, 385KB) System.Configuration.ConfigurationManager.dll, (Windows DLL, 355KB) System.Management.Automation.dll, (Windows DLL, 150KB) System.Memory.dll and 8 more.

rust-pkg-gen

rust-pkg-gen creates so-called rust packages with arbitrary toolchains/components and arbitrary crates. These packages then can be used on separate machines, and installed with provided install scripts.

Currently, there is a small public API, but this API doesn't contain much. One of the things it does include, however, is code for parsing rust-config.toml files(contains configuration for rust-pkg-gen).

An example rust-config.toml file is in this repo.

In debug builds, the default temporary directory is ./test(relative to where rust-pkg-gen was called). In release builds, it creates a new folder in std::env::temp_dir(). This behavior can be changed by providing a path to --temp-dir. See --help for a list of flags that can be used.


lib.rs:

Main file for the crate. Contains most of the public API, outside of mainly the code copied from rustup-mirror and the resources included in the output.

Dependencies

~97MB
~2M SLoC