Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix: Raise NotAGitProjectError only in git related command #219

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

Merged
Lee-W merged 1 commit into master from raise-not-a-git-error-in-git-related-command-only
Jul 14, 2020

Conversation

Copy link
Member

@Lee-W Lee-W commented Jul 14, 2020

Only Running cz commit, cz bump and cz changelog in a non git project will raise NotAGitProjectError
Other commands like cz --help will work now

#206

(Thanks for sending a pull request! Please fill in the following content to let us know better about this change.)

Types of changes

Please put an x in the box that applies

  • Bugfix

Description

Describe what the change is

Checklist:

  • Add test cases to all the changes you introduce
  • Run ./script/format and ./script/test locally to ensure this change passes linter check and test
  • Test the changes on the local machine manually
  • Update the documentation for the changes

Steps to Test This Pull Request

  1. Run cz --help, cz ls, cz example, cz info, cz init, cz version, cz check
  2. Run cz commit, cz bump, cz changelog

Expected behavior

  1. After running the first group (i.e. cz --help ) of commands, no error should be raised.
  2. After running the second group (i.e. cz commit ) of commands, no error should be raised.

Related Issue

#206

Additional context

Add any other context or screenshots about the pull request here.

Only Running `cz commit`, `cz bump` and `cz changelog` in a non git project will raise NotAGitProjectError
Other commands like `cz --help` will work now
#206 
Copy link

codecov bot commented Jul 14, 2020
edited
Loading

Codecov Report

Merging #219 into master will increase coverage by 0.05%.
The diff coverage is 100.00%.

Impacted file tree graph

@@ Coverage Diff @@
## master #219 +/- ##
==========================================
+ Coverage 95.64% 95.69% +0.05% 
==========================================
 Files 34 34 
 Lines 942 953 +11 
==========================================
+ Hits 901 912 +11 
 Misses 41 41 
Flag Coverage Δ
#unittests 95.69% <100.00%> (+0.05%) ⬆️
Impacted Files Coverage Δ
commitizen/commands/bump.py 91.66% <100.00%> (+0.20%) ⬆️
commitizen/commands/changelog.py 97.29% <100.00%> (+0.07%) ⬆️
commitizen/commands/commit.py 96.61% <100.00%> (+0.11%) ⬆️
commitizen/config/__init__.py 97.67% <100.00%> (ø)
commitizen/git.py 95.45% <100.00%> (+0.27%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3f91066...a2f4af2. Read the comment docs.

@Lee-W Lee-W requested a review from woile July 14, 2020 08:52
Copy link
Member

woile commented Jul 14, 2020

Fantastic!

Lee-W reacted with thumbs up emoji

@Lee-W Lee-W merged commit 2fdce2f into master Jul 14, 2020
@Lee-W Lee-W deleted the raise-not-a-git-error-in-git-related-command-only branch July 14, 2020 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@woile woile woile approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants

AltStyle によって変換されたページ (->オリジナル) /