mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-29 06:45:54 +03:00
doc/crystal: Update to mention shard.lock file generation
This commit is contained in:
parent
ffcff898a6
commit
c6064b7c4a
@ -4,12 +4,12 @@
|
||||
|
||||
This section uses [Mint](https://github.com/mint-lang/mint) as an example for how to build a Crystal package.
|
||||
|
||||
If the Crystal project has any dependencies, the first step is to get a `shards.nix` file encoding those. Get a copy of the project and go to its root directory such that its `shard.lock` file is in the current directory, then run `crystal2nix` in it
|
||||
|
||||
If the Crystal project has any dependencies, the first step is to get a `shards.nix` file encoding those. Get a copy of the project and go to its root directory such that its `shard.lock` file is in the current directory. Executable projects should usually commit the `shard.lock` file, but sometimes that's not the case, which means you need to generate it yourself. With an existing `shard.lock` file, `crystal2nix` can be run.
|
||||
```bash
|
||||
$ git clone https://github.com/mint-lang/mint
|
||||
$ cd mint
|
||||
$ git checkout 0.5.0
|
||||
$ if [ ! -f shard.lock ]; then nix-shell -p shards --run "shards lock"; fi
|
||||
$ nix-shell -p crystal2nix --run crystal2nix
|
||||
```
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user