-
Notifications
You must be signed in to change notification settings - Fork 18
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
fix: Fix issues with docs, makim/make, release, and CI #182
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the great work, @xmnlab! Some minor comments below. Also, should a user be allowed to user be allowed to use both makim and Make together? If not, then we should add a condition here -
scicookie/src/scicookie/hooks/post_gen_project.py
Lines 248 to 253 in 0c5337e
def validation(): | |
if USE_BLUE and USE_BLACK: | |
raise Exception( | |
"The libs Blue and Black were selected, but you need to choose " | |
"just one of them." | |
) |
linter: | ||
help: Run linter tools | ||
run: | | ||
pre-commit install |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This isn't actually required, given that this file invoked pre-commit
explicitly using pre-commit run --all-files --verbose
. Having this is not a big issue too, does not take a lot of time to add pre-commit
hooks as git
hooks 🙂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yep, the idea is to force the user to install the pre-commit hook locally ... maybe it is not the best approach, I am currently investigating some better approach for doing that.
for poetry I found this: https://pypi.org/project/poetry-pre-commit-plugin/
but it seems it is not mature yet (all its tests are not executed: https://github.com/vstrimaitis/poetry-pre-commit-plugin/blob/master/tests/test_plugin.py
maybe we could do it as a post-gen step .. so it could work for all the projects .. but we would need to create the environment first ... so not sure if it is a good idea or not
nodejs projects are very nice in this topic .. because when you install it for development, it automatically installs pre-commit hook.
so if it is not a problem, I would keep it for now, and in the meantime I will try to figure out a good approach that would works for all the build-systems
|
||
.PHONY:lint | ||
lint: | ||
pre-commit install |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be remove, but again, having it does not hurt a lot
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
as I mentioned before, I would keep this for now, until I come with a better solution to "force" the installation of pre-commit hooks from the beginning
@@ -35,7 +35,7 @@ classifiers = [ | |||
"Typing :: Typed", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not related to this PR, but just noticed that these lines should be in a if cookiecutter.use_mypy == "yes"
condition (in all the build backend pyproject.toml files).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh I see, I will open an issue for that. thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great, A thousand thanks! 🚀
Leave some comments for the guide.
@@ -770,18 +770,18 @@ by selecting the option `None` (this is the default option). | |||
|
|||
## Automation Tools |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Include it in the structure, please
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry, I am not following you here, could you give more details please?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After that line:
Line 26 in 0c5337e
- [Integration with DevOps tools](#integration-with-devops-tools) |
should be:
- [Automation tools](#automation-tools)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh got it, thank you for the explanation, I am going to add it now. thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done!
Co-authored-by: Saransh Chopra <saransh0701@gmail.com>
Co-authored-by: Anavelyz Perez <42752529+Anavelyz@users.noreply.github.com>
for now it is used for the same thing, but the user maybe would like to use make for a different purpose, so at the end of the project creation the user would need to rewrite the Makefile scicookie uses both for the same purpose, so that is why does it make sense? |
It seems that currently there is no code for removing the makim file or makefile regarding to the user selection. |
@Saransh-cpp @Anavelyz I addressed the points you made and added a new change that removes Makefile or .makim.yaml if their tools are not selected. |
I also fixed an issue with hatch as well in the smoke tests. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome, looks good now! Thanks, @xmnlab!
@Saransh-cpp thanks for the review! |
🎉 This PR is included in version 0.6.2 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
Pull Request description
This is a big PR that aims to fix a bunch of issues:
How to test these changes
...
Pull Request checklists
This PR is a:
About this PR:
Author's checklist:
Additional information
Reviewer's checklist
Copy and paste this template for your review's note: