https://github.com/am-kantox/issuer
Adds `mix` tasks to easily issue (publish) new versions to `hex`.
https://github.com/am-kantox/issuer
Last synced: about 1 month ago
JSON representation
Adds `mix` tasks to easily issue (publish) new versions to `hex`.
- Host: GitHub
- URL: https://github.com/am-kantox/issuer
- Owner: am-kantox
- Created: 2016-09-30T15:57:32.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2016-11-21T14:34:58.000Z (over 8 years ago)
- Last Synced: 2025-03-21T12:22:01.284Z (about 1 month ago)
- Language: Elixir
- Size: 241 KB
- Stars: 21
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Issuer
[](https://travis-ci.org/am-kantox/issuer)
```elixir
{:ok, app |> version_bump |> git_tag_commit_push |> hex publish} = `mix issuer`
```## Installation
**TODO:** http://elixir-lang.org/docs/stable/mix/Mix.Project.html#in_project/4
**NB:** Starting with version `0.2` we store the interfaces in file `config/INTERFACES` to compare against current version and suggest whether minor version might be updated, or interfaces were changed drastically. Just add this file to your git repo to avoid “Unstaged changes:\n?? config/INTERFACES” error on git check.
Add `issuer` to your list of dependencies in `mix.exs`:
```elixir
def deps do
[{:issuer, "~> 0.2.2", only: :dev}]
end
```## Usage
Run `mix issuer` to automate subsequent running of:
mix test && \
confirm_suggested_version && \ # ⇐ will load versions, suggest the succ and ask about
patch_version_in_VERSION_and_README && \ # ⇐ will [safely] replace version to current in files
git commit -am ":paperclip: Bump version." && \
git push && \
git tag VERSION_CHOSEN_IN_STEP_2 && \
git push --tags && \
hex publish**NB**: on the first run it will move the version declaration out of `mix.exs`
to `config/VERSION`. I am not very proud of this solution, but I found it better
than modifying `mix.exs` on each subsequent run.## FAQ
**Q:** Is it of any good?
**A:** Yes, it is.**Q:** Is `issuer` itself being published with `issuer`?
**A:** Indeed.**Q:** Won’t it ruin my project?
**A:** Well, it could, but you have the project source versioned, haven’t you?**Q:** What happens if any step failed?
**A:** It’s `Elixir`, we just let the castle crash. `hex publish` is executed
if and only all previous steps succeeded.## How it looks like:

## Eastern Egg
Add:
```elixir
def deps do
[{:ex_ncurses, git: "https://github.com/jfreeze/ex_ncurses.git", only: :dev}]
end
```to your project’s `mix.exs` to be asked about version in fancy `ncurses`-based colorful manner :)
## Docs
[https://hexdocs.pm/issuer](https://hexdocs.pm/issuer)
## License
**MIT**