Closed leon-erd closed 5 months ago
Although I don't think it makes sense, considering how simple it is to implement this, I will support it
From: Leon @.> Sent: Monday, March 4, 2024 10:51:43 PM To: nix-community/nix4vscode @.> Cc: Subscribed @.***> Subject: [nix-community/nix4vscode] Allow nixpkgs version in config.toml (Issue #22)
Would be nice if nix4vscode would accept a version as it is given by nixpkgs i.e. 1.86.2.24057 for vscodium right now in the config.toml. Currently it thows:
thread 'main' panicked at src/main.rs:130:72:
called Result::unwrap()
on an Err
value: Error("unexpected character '.' after patch version number")
note: run with RUST_BACKTRACE=1
environment variable to display a backtrace
It should be fine to just discard the last part I guess.
I think to put this repo to optimal usage it is crucial to automate the generation of the config.toml and hence the config.nix with the vscode version that you currently pull from nixpkgs. I'm thinking about writing a small script that gets executed before home-manager rebuilds that works as follows:
― Reply to this email directly, view it on GitHubhttps://github.com/nix-community/nix4vscode/issues/22, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AKBJ6ANHBWG4QERG3WJMBGLYWSC77AVCNFSM6AAAAABEFLA7YOVHI2DSMVQWIX3LMV43ASLTON2WKOZSGE3DOMBTGQ2DGMI. You are receiving this because you are subscribed to this thread.Message ID: @.***>
Generally speaking, a tool only do one thing. The scenario you raise is very common and reasonable. But I still don't think it should be integrated into this software. But to make up for it, we can provide a script and put it in this repository to achieve what you said. Then we can update the version via cicd automatically. If you are already doing this job, you are welcome to submit a PR
I wanted to wait until the new branch gets merged :)
Would be nice if nix4vscode would accept a version as it is given by nixpkgs i.e.
1.86.2.24057
for vscodium right now in the config.toml. Currently it thows:It should be fine to just discard the last part I guess.
I think to put this repo to optimal usage it is crucial to automate the generation of the config.toml and hence the config.nix with the vscode version that you currently pull from nixpkgs. I'm thinking about writing a small script that gets executed before home-manager rebuilds that works as follows:
nix4vscode
on new config.tomlIf you have any better suggestions for the automation that do not involve any external setup outside your dotfiles I'm happy to hear :)