Instantly share code, notes, and snippets.

What would you like to do?
Clone all the elm packages locally.

I'm sure there's probably a more efficient way to do this, but before CampJS I'm pretty keen to bring down all the elm packages that are available from the elm package repository.

This seems to do the trick :)

curl -s \
  | jq -r ".[].name" \
  | xargs -L 1 -I{} bash -c "[[ ! -d {} ]] && git clone 'git://{}.git' '{}' || true"

Requires the use of the excellent jq command-line tool.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment