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

crystal: make things work again when using shards to build #107369

Merged
merged 4 commits into from Dec 28, 2020

Conversation

peterhoeg
Copy link
Member

@peterhoeg peterhoeg commented Dec 22, 2020

Motivation for this change

Shards 0.12 introduced a new lock file format as well as requiring a .shards.info file in the lib/ directory when building.

So this does a few things:

  1. lib/ is no longer a symlink to the store as we need to be able to write to it
  2. .shards.info is put where it belongs
  3. crystal2nix has support for the new lock file format (still retaining backwards compatibilty with v1)
  4. crystal2nix moves out of tree and into it's own repository (this should move to nix-community)
  5. updates lucky-cli as an example application that works with the new shards format (this was really the reason for fixing all this stuff up in the first place...)

Cc: @manveru - I stole your crystal2nix code - let me know if you have any issues with leaving it under the MIT license.

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.

@peterhoeg
Copy link
Member Author

Cc: @NixOS/crystal-lang

@manveru
Copy link
Contributor

manveru commented Dec 22, 2020

No objections from me, gotta have a closer look at the code later, but looks quite good. Thanks a lot!

@peterhoeg
Copy link
Member Author

Is there any chance that any of the nice nix-community people can hook me up with a repo for crystal2nix under nix-community?

Cc: @grahamc @matthewbauer @makefu @worldofpeace

@peterhoeg peterhoeg merged commit 4fc53b5 into NixOS:master Dec 28, 2020
@peterhoeg peterhoeg deleted the f/crystal branch December 28, 2020 08:21
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

2 participants