Dependency manager for the Crystal language.
Crystal applications and libraries are expected to have a
at their root looking like this:
name: shards version: 0.1.0 dependencies: openssl: github: datanoise/openssl.cr branch: master development_dependencies: minitest: git: https://github.com/ysbaddaden/minitest.cr.git version: ~> 0.3.1 license: MIT
When libraries are installed from Git repositories, the repository is expected
to have version tags following a semver-like format,
prefixed with a
Please see the SPEC
for more details about the
Shards is usually distributed with Crystal itself (e.g. Homebrew and Debian
packages); you may invoke it throught
crystal deps. Alternatively, a
package may be available for your system.
You may download a statically compiled 64bit executable of Shards for Linux or OS X from the releases page and install it somewhere into your PATH, this version will take precedence over the bundled version.
Alternatively you may download a source tarball from the same page (or clone the
repository) then run
make release for an optimized build— and copy
the newly generated
bin/shards somewhere into your PATH. A good place is
/usr/local/bin for example.
You are now ready to create a
shard.yml for your projects (see the
SPEC). You may type
shards init (or
crystal deps init) to have a starting
created for you.
shards install to install your dependencies (or
crystal deps install), which will lock your dependencies into a
shard.lock file, which you
should check into version control, so further
install will always install the
locked versions, achieving reproducible installations across computers.
Last but not least, use
shards --help (or
crystal deps --help) to list the
other commands and their options.
These requirements are only for compiling Shards.
Please refer to http://crystal-lang.org/docs/installation for instructions for your operating system.
On Debian/Ubuntu Linux you may install the
On Mac OS X you may install it using homebrew with
brew install libyamlthen make sure to have
LIBRARY_PATHenvironment variable (eg:
export LIBRARY_PATH="/usr/local/lib:$LIBRARY_PATH"). Please adjust the path per your Homebrew installation.
Licensed under the Apache License, Version 2.0. See LICENSE for details.