vite-plus: init at 0.1.18#500492
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
|
does this include oxfmt and oxlint? it doesn't look include typescript cli implementation |
|
I get this when running |
|
oh they stop including oxlint/oxfmt, so it's easier to make a nix pkg |
|
|
Cant fix darwin cause i dont have it |
iamanaws
left a comment
There was a problem hiding this comment.
bump + darwin fix
tested on aarch64-darwin
Assisted-by: Cursor (GPT-5.5)
There was a problem hiding this comment.
| version = "0.1.21"; |
There was a problem hiding this comment.
| hash = "sha256-UrYaiilgj94PovTTnzSaTOUpEZCb8tn/Tgf2AjtK7z0="; |
There was a problem hiding this comment.
| cargoHash = "sha256-VYuP281uFYPvdMUHz6FpqDZtcTIXDhNqJ8aZRD5m0iM="; |
There was a problem hiding this comment.
| for f in $out/git/*/Cargo.toml $out/git/*/crates/*/Cargo.toml; do | |
| if [ -f "$f" ]; then | |
| sed -i \ | |
| -e 's/, artifact = "[^"]*"//g' \ | |
| -e 's/, target = "target"//g' \ | |
| -e 's|brush-parser = { git = "[^"]*", rev = "[^"]*" }|brush-parser = "0.3.0"|' \ | |
| "$f" | |
| fi | |
| done |
There was a problem hiding this comment.
darwin fix
| # fspy's preload libraries (fspy_preload_unix, fspy_preload_windows) | |
| # use the nightly `c_variadic` feature and cannot be compiled with | |
| # stable rustc. They are artifact deps that fspy embeds as bytes via | |
| # include_bytes!(env!("CARGO_CDYLIB_FILE_...")). Remove them from | |
| # fspy's dep list — we provide a stub cdylib instead (see preBuild). | |
| # Also remove fspy_test_bin (dev-dep with artifact = "bin"). | |
| for f in $out/git/*/crates/fspy/Cargo.toml; do | |
| if [ -f "$f" ]; then | |
| sed -i \ | |
| -e '/fspy_preload_unix/d' \ | |
| -e '/fspy_preload_windows/d' \ | |
| -e '/fspy_test_bin/d' \ | |
| "$f" | |
| fi | |
| done | |
| # fspy's macOS build script downloads helper binaries at build time. | |
| # Avoid network access; fspy is already stubbed below for nixpkgs. | |
| for f in $out/git/*/crates/fspy/build.rs; do | |
| if [ -f "$f" ]; then | |
| sed -i '/fn fetch_macos_binaries(out_dir: &Path) -> anyhow::Result<()> {/a\ | |
| if env::var("CARGO_CFG_TARGET_OS").unwrap() == "macos" {\ | |
| let stub = out_dir.join("nixpkgs-fspy-macos-stub");\ | |
| fs::write(&stub, b"#!/bin/sh\\nexit 127\\n")?;\ | |
| materialized_artifact_build::register("oils_for_unix", &stub);\ | |
| materialized_artifact_build::register("coreutils", &stub);\ | |
| return Ok(());\ | |
| }' "$f" | |
| fi | |
| done | |
| ''; |
There was a problem hiding this comment.
| homepage = "https://github.com/voidzero-dev/vite-plus"; | |
| changelog = "https://github.com/voidzero-dev/vite-plus/releases/tag/${finalAttrs.src.tag}"; |
There was a problem hiding this comment.
| @@ -666,20 +666,6 @@ |
There was a problem hiding this comment.
| @@ -7760,6 +7746,6 @@ | |
| source = "git+https://github.com/voidzero-dev/vite-task.git?rev=c63db22ff0258e4e45f03205104838ab795161ac#c63db22ff0258e4e45f03205104838ab795161ac" |
There was a problem hiding this comment.
| dependencies = [ | |
| - "brush-parser 0.3.0 (git+https://github.com/reubeno/brush?rev=dcb760933b10ee0433d7b740a5709b06f5c67c6b)", | |
| + "brush-parser 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
| "diff-struct", |
|
FYI voidzero-dev/vite-plus#976 was just merged to resolve the version injection handling |
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
|
I lost interest in frontend ecosystem so not going to work on this, feel free to pick up this pr, i'll review it |
Disclaimer: Co-authored by claude code
Adds vite-plus, the unified toolchain CLI (
vp) for web development. It manages Node.js runtimes, package managers, and frontend tooling in one place.Build workarounds
The upstream project has several build challenges that required workarounds:
brush-parsercrate: Cargo.lock has twobrush-parser0.3.0 entries (registry + git) with identical code.fetchCargoVendorcannot handle duplicate name+version pairs, so a patch deduplicates them-Z bindeps: Thevite-taskgit dependency usesartifact = "cdylib"/"bin"annotations requiring unstable cargo. Stripped in the vendor staging viadepsExtraArgs.postBuild./rolldown/which is synced externally. Removed from workspace members inpostPatch. Everyvpsubcommand still worksfspyuses#![feature(once_cell_try)]→RUSTC_BOOTSTRAP=1. Thefspy_preload_unixcdylib requiresc_variadic(still unstable) → stub shared library providedversion = "0.0.0"at release time; replicated inpostPatchLimitations
fspyfilesystem tracing (LD_PRELOAD interception) is non-functional due to the stub cdylib. All othervpcommands work correctlyvp create) require a localnode_modules/vite-plusinstallation in the project, as this package only includes the Rust CLI binaryThings done
passthru.tests.nixpkgs-reviewon this PR. See nixpkgs-review usage../result/bin/.