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

create changelog file if it does not exist #13

Open
usernam3 opened this issue Oct 26, 2017 · 1 comment
Open

create changelog file if it does not exist #13

usernam3 opened this issue Oct 26, 2017 · 1 comment

Comments

@usernam3
Copy link
Owner

usernam3 commented Oct 26, 2017

When meta_commit changelog is called and CHANGELOG.md does not exist in the directory, it shows error :

meta_commit/lib/meta_commit/changelog/adapters/changelog.rb:70:in `read': No such file or directory @ rb_sysopen - CHANGELOG.md (Errno::ENOENT)

It would be better if meta_commit will create the CHANGELOG.md (if it is missing) and notify the user about it.

Scenario that should pass when this issue is closed (add it to features/changelog_command.feature)

Scenario: Run command on repository without changelog file
    Given three_commits_with_two_tags git repository
    When I run meta_commit command `changelog v1.0 v2.0`
    Then the output should contain #{notification_that_file_created}
    Then the output should contain exactly "added version [v2.0] to CHANGELOG.md"
    Then the changelog should be equal to fixture file "three_commits_with_tags"
@usernam3 usernam3 added the bug label Oct 26, 2017
@usernam3 usernam3 changed the title create changelog if it does not exist create changelog file if it does not exist Dec 3, 2017
@usernam3
Copy link
Owner Author

  • Add new scenario to feature (features/changelog_command.feature)
  • Run (rake features) and see it fails
  • Handle the error (Maybe on cli.rb:29 level, create file if it doesn't exist)
  • See usage scenario is passing 💪

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

No branches or pull requests

1 participant