2022-10-16

Published: Nov 08, 2022Last modified: Apr 05, 2023
Word count: 288

DONE neil contrib

https://clojure.org/reference/deps_and_cli#_dependencies

tools.deps supports handling :sha and :tag for backwards compatibility

https://clojure.org/reference/deps_and_cli#_resolve_deps

maybe want to support :override-deps and :default-deps when updating aliases

there seems to be some alias `:deps` key usage as well - maybe we go ahead and support that too?

> pr message

A couple minor improvements rounding out some `neil dep upgrade` use-cases:

  • `neil dep upgrade` now respects `:sha` (vs `:git/sha`) in coords, which is technically supported by tools.deps
  • `neil dep add` now supports `--tag` and `--latest-tag`, similarly to `--sha` and `--latest-sha`
  • `neil dep upgrade` now respects `:tag` and `:git/tag` coordinates (instead of setting those to the latest `:git/sha`)
  • coordinates that use the prefix-less `:sha` and `:tag` will be moved to `:git/sha` and `:git/tag` when upgrading
  • `neil dep upgrade`'s output can now be piped into `neil dep add`
  • you can now pipe `neil dep upgrade --dry-run` into fzf, and then back into `neil dep add`, to selectively upgrade a single dep

To test locally, be sure to specify `./neil` in both places:

```

./neil dep upgrade --dry-run | fzf | xargs ./neil dep add

```

But otherwise, once this is deployed/reinstalled:

```

neil dep upgrade --dry-run | fzf | xargs neil dep add

```

> DONE support :sha

> DONE support dep add :tag and :latest-tag

> DONE support dep upgrade sticking with :tag or :git/tag

> DONE support dep upgrade dry-run output being feedable back into dep-add or dep-upgrade

> DONE does upgrade add an empty alias map?

seems to be just leftover :aliases from previous tests