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

Complete redesign of this gem #28

Merged
merged 3 commits into from
Jan 29, 2023
Merged

Complete redesign of this gem #28

merged 3 commits into from
Jan 29, 2023

Conversation

jcouball
Copy link
Member

  • Split the Options class into two different classes: CommandLineOptions which just holds the command line options and Project which has all the properties of the project that the release is being created for. The Options class was getting too complicated and this simplifies the class and testing.
  • Use git log instead of docker to get the change log

@jcouball jcouball requested a review from a team as a code owner January 29, 2023 22:16
#
# @api public
#
class Project
Copy link

Choose a reason for hiding this comment

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

Class Project has 26 methods (exceeds 20 allowed). Consider refactoring.

# Returns `true` if `#changelog_path` is nil or is a valid regular file path
# @return [Boolean]
# @api private
def validate_changelog_path
Copy link

Choose a reason for hiding this comment

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

Method validate_changelog_path has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.

#
def initialize(tag, date, description)
def initialize(previous_tag, tag, created_on, changes, release_log_url)
Copy link

Choose a reason for hiding this comment

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

Method initialize has 5 arguments (exceeds 4 allowed). Consider refactoring.

@codeclimate
Copy link

codeclimate bot commented Jan 29, 2023

Code Climate has analyzed commit 1c9a683 and detected 1 issue on this pull request.

Here's the issue category breakdown:

Category Count
Complexity 1

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 100.0% (0.0% change).

View more on Code Climate.

@jcouball jcouball merged commit c7bd12d into main Jan 29, 2023
@jcouball jcouball deleted the redesign branch January 29, 2023 23:07
@jcouball jcouball mentioned this pull request Jan 30, 2023
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

1 participant