Skip to content

Prevent accidental creation of nested projects#545

Merged
FlorianWilhelm merged 4 commits intomasterfrom
issue-544
Dec 1, 2021
Merged

Prevent accidental creation of nested projects#545
FlorianWilhelm merged 4 commits intomasterfrom
issue-544

Conversation

@abravalheri
Copy link
Collaborator

@abravalheri abravalheri commented Nov 30, 2021

Purpose

This PR attempts to prevent users from accidentally creating nested projects, which may result in problems with setuptools-scm, as described in #544.

Approach

The pyscaffold.actions.verify_project_dir was modified to also look for nested repositories and raise an error when relevant.

If the --force option is given, PyScaffold will understand that the users know what they are doing and create the project without complaining.

@abravalheri abravalheri marked this pull request as ready for review November 30, 2021 22:02
@abravalheri
Copy link
Collaborator Author

@FlorianWilhelm, is this more or less what you had in mind?

@coveralls
Copy link

coveralls commented Nov 30, 2021

Pull Request Test Coverage Report for Build 6720378509721600

  • 11 of 11 (100.0%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.01%) to 97.439%

Totals Coverage Status
Change from base Build 5014187148574720: 0.01%
Covered Lines: 1678
Relevant Lines: 1711

💛 - Coveralls

@FlorianWilhelm
Copy link
Member

Wow! You are so fast 🚀 Looks really good :-)

BTW, I noticed yesterday again how fast the unit tests are. Thanks again for having sped them up so much ⚡

@FlorianWilhelm FlorianWilhelm merged commit 7cac3a3 into master Dec 1, 2021
@FlorianWilhelm FlorianWilhelm deleted the issue-544 branch December 1, 2021 07:38
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.

3 participants