Skip to content
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

kotlin-language-server: init at 0.7.0 #105110

Closed
wants to merge 3 commits into from
Closed

kotlin-language-server: init at 0.7.0 #105110

wants to merge 3 commits into from

Conversation

enderger
Copy link
Member

Motivation for this change

Currently, there is no package for the Kotlin Lanugage Server, often used by IDE plugins for the development of Kotlin.
I'm a bit new to git, and accidentally closed the origional PR

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)

  • Built on platform(s)

    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)

  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"

  • Tested execution of all binary files (usually in ./result/bin/)

  • Determined the impact on package closure size (by running nix path-info -S before and after)

  • Ensured that relevant documentation is up to date

  • Fits CONTRIBUTING.md.

@SuperSandro2000
Copy link
Member

Result of nixpkgs-review pr 105110 run on x86_64-linux 1

1 package built:
  • kotlin-language-server

@enderger
Copy link
Member Author

enderger commented Nov 27, 2020

For some reason, Git created a new branch with the same name for the new commits.
EDIT: I can't get the commits to split, sorry.

@lukegb
Copy link
Contributor

lukegb commented Nov 27, 2020

A few comments:

  • (tiny nit) 2-space indentation is more common in nixpkgs :)
  • For open-source packages we prefer to have them built from source rather than using binary releases; Packaging Gradle-based applications #17342 tracks making this sort of thing easier in nixpkgs. mindustry: init at 99 (and updates) #72306 is an example of doing it "by hand", which is another option. It might not be worth doing in this situation at the moment, though (I'm sort of 50/50 on this because fixed-output derivations are a pain)
  • The ./bin/kotlin-language-server doesn't run "alone" (it expects java to be on the PATH already) which means your buildInputs isn't really going to help - it isn't actually used in building your package. You should probably remove the buildInputs line, add "makeWrapper" to nativeBuildInputs, and add to your installPhase:
    wrapProgram $out/bin/kotlin-language-server \
      --prefix PATH : ${jre}/bin

Some Git advice for splitting: my advice here is probably to carefully recommit things. If you're using the CLI, the best way (in my opinion, other people will have different advice) is to:

$ git reset --soft HEAD^
# You've now removed the last commit, but the changes are still in the index ready to commit, so commit the maintainer-list first:
$ git commit maintainers/maintainer-list.nix
# ...write a commit message for the maintainer-list.nix file
$ git commit
# ...write a commit message for the rest of the files
$ git push --force-with-lease
# and you're done!

@enderger
Copy link
Member Author

I've fixed the indentation and the wrapping issue, however I was unable to get Gradle (I tried the included wrapper and the Nix package) to build the package.

@enderger
Copy link
Member Author

@SuperSandro2000 I also split the commits using lukegb's suggestion.

@SuperSandro2000
Copy link
Member

Result of nixpkgs-review pr 105110 run on x86_64-linux 1

1 package built:
  • kotlin-language-server

@SuperSandro2000
Copy link
Member

@enderger Please fix the merge conflict.

@enderger
Copy link
Member Author

I've resolved it.

@SuperSandro2000
Copy link
Member

Please do not merge master into PRs. Please resolve that cleanly.

@enderger
Copy link
Member Author

Hey, sorry for dropping this. I was quite naive when it comes to Git when I made this PR. I may try redoing this package at some point, but I'll close the PR since tit is hopelessly out-of-date.

@enderger enderger closed this Mar 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants