-
-
Notifications
You must be signed in to change notification settings - Fork 14.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Visual Studio Code editor #14354
Comments
In general, building everything from source is preferred. |
But, good luck with that ;) On Fri, Apr 1, 2016, 7:20 AM Vladimír Čunát [email protected]
|
I'm 👎 on building from source on this one. The extension gallery only works with the unfree version, and without it, the editor is just a glorified notepad. |
Ah sorry for the misunderstanding, the (vital) extension manager can be enabled by adding merely 3 lines to a configuration file (I've somehow skipped that while skimming over the linked issue). Building everything from source is indeed the best option here. |
Amazing how some people can't just answer a simple yes/no question. Thank you very much for clarifying, and for packaging! |
Oh noes! The hydra build for
I fear that this is by design and that a clean nix derivation may not access external resources, except for what has been defined as inputs (expression parameters + How should this be solved? |
I think you should be using |
Thanks to combined effort (#14891), |
What worked for me was:
Thanks to the helpful people in Freenode #nixos: rycee, Fare, sphalerite |
Is vscode no longer in nixpkgs? (Well, I get it in unstable but I don't see it at https://nixos.org/nixos/packages.html.) |
@sid-kap I installed it yesterday latest version using |
It's marked as unfree, and therefore hidden by default. |
I discovered that vs code was available on nix from this thread. If it's hidden on the website search, how should I have discovered it? |
|
It all needs to be searchable from the website. The website is the natural way to search and list packages, and is the de-facto standard. De-facto standard The terminal is an inappropriate place to browse packages. |
vscode is not listed there because it is unfree. NixOS by default is a free software distribution. |
(there are two ways your comment could be interpreted. I'm assuming the more controversial one, since it's 50/50) You need to attract people to the OS. People use non-free software. Free/non-free is for the end-user to decide, not to be enforced by the distro. You're creating a very bad relationship between the distro and the end user. You live in a world full of non-free software. If you want to get rid of it, you must provide a better experience than the non-free software, and if you fail to do so, you must embrace each user's right to choose non-free software. It is not the distro's right to tell users what they can or cannot run on their system, or pose an unreasonable obstruction to those who wish to run non-free software (such as removing non-free software from search results). The free software community complains that Apple and Microsoft do this. The fact that they do the same is hypocritical. |
I came across this issue in a web search for “nixpkgs vscode unfree” in the hope to find clarification. The licensing issue is now clear to me: Microsoft offers only an unfree build of their otherwise free code. To help future visitors I post this here, since it’s what Startpage/DDG point to. It appears the vscodium package in Nixpkgs outputs a free build of VS Code, under the MIT license. There are some differences in the final product but those are only cosmetic, removal of telemetry, and the name of the executable. It also seems to be entirely up-to-date with the unfree version. It would be nice if this somehow showed up if you searched for “vscode” in the packages page. Of course it doesn’t now, since “vscode” is not a substring of “vscodium”. |
That's a code editor, developed by Microsoft.
There's already syntax highlighting for nix in vscode, but the
vscode
package itself is missing.I got it working, but there are multiple alternatives how to package it:
electron
is downloaded by their install script, patchelf theelectron
dependency, license = MITelectron
from the nixpkgs repository (which is compiled itself, need to change the nixpkgselectron
expression to do patchelf instead ofwrapProgram
withLD_LIBRARY_PATH
), license = MITProblem:
vscode
requires specificelectron
version - have a separateelectron-vscode
expression for that?Wrapping
electron
withLD_LIBRARY_PATH
env var is not possible, sincevscode
andelectron
modify the user environment (see microsoft/vscode#1033).For licensing terms, see license explanation.
One (major) drawback of the FOSS version is that the extension manager is missing, which lets you conveniently install additional plugins. However, it can be easily enabled, by modifying a configuration file. Seems like that is allowed for the FOSS version.
Which alternative to choose? Is there another?
Patchelf looks something like this:
For
atom-env
, refer toelectron
's nix expression.The text was updated successfully, but these errors were encountered: