Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added a mode which lists all tagged versions #7

Merged
merged 4 commits into from
Feb 10, 2017

Conversation

perlun
Copy link
Owner

@perlun perlun commented Dec 20, 2016

This mode is triggered by running the program in this mode:

cargo run ~/git/chaos # Only one parameter: the repo name

This will read the list of tags from git, and use them to produce a reasonably-nice looking changelog based on the list of git commits.


Two remaining issues:

  • Doesn't include the latest tag for some odd reason.
  • Needs to strip v prefix, i.e. v2.0.1-style tags should be supported.

This mode is triggered by running the program in this mode:

```
cargo run ~/git/chaos # Only one parameter: the repo name
```

This will read the list of tags from git, and use them to produce a reasonably-nice looking changelog based on the list of git commits.
@perlun
Copy link
Owner Author

perlun commented Dec 20, 2016

@mpalmujoki - there we go. Feel free to check out my latest neat addition to this tool. Still anxiously anticipating your first PR/suggestion for the project as well... 😊

Merry Christmas btw! 🎅 🎄 ☃️

@perlun
Copy link
Owner Author

perlun commented Dec 28, 2016

Ping @mpalmujoki

@mpalmujoki
Copy link
Collaborator

😛 Mind if I do this when I'm finished with Real Work? :)

@perlun
Copy link
Owner Author

perlun commented Dec 29, 2016

😛 Mind if I do this when I'm finished with Real Work? :)

Sure. ETA? 😉

@mpalmujoki
Copy link
Collaborator

Late January? 😝 Nah, I'll look at it now, stuck anyhow.

Copy link
Collaborator

@mpalmujoki mpalmujoki left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't really comment much.

src/main.rs Outdated
to_revision: to_tag
};
generator.generate_changelog();
print!("\n");
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here you print newline...

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needed because we want each version to be separate, like this:

## 0.0.4
[Full Changelog](https://github.com/chaos4ever/chaos/compare/0.0.3...0.0.4)

* 66b4faa chaos 0.0.4 coming up.
* 294159b Removed autochaos
* 02dc77c Various linter fixes.

## 0.0.3
[Full Changelog](https://github.com/chaos4ever/chaos/compare/0.0.2...0.0.3)

* a85b8af More refinements
* 6a1a9a7 Updated paragraph after screenshot
* 23ed01a Fixed screenshot link

But, you have a point - this part could be moved to the generate_changelog method. I'll try to fix it like that, thanks.

}
else {
println!("Usage: {} <path> <from_revision> <to_revision>\n", args[0]);
generator.generate_changelog();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But here you dont do it.

@perlun perlun self-assigned this Dec 29, 2016
This is overly simplistic and agressive, and probably won't cover all cases properly. But _for me_, it works rather well and makes the program more useful, so let's go with this for now.
The problem with the previous appraoch was that it included a bit of "junk" in terms of origin/master etc., which meant that the most recent tag was often excluded => no changelog entry would be produced for it. This has now all been fixed, and the program works like a charm.
@perlun
Copy link
Owner Author

perlun commented Feb 10, 2017

This now works as expected, I managed to fix the two remaining bugs. Merging away!

@perlun perlun merged commit a982352 into master Feb 10, 2017
@perlun perlun deleted the fix/list-all-tagged-versions branch February 10, 2017 22:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants