-
Notifications
You must be signed in to change notification settings - Fork 1
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
add CONTRIBUTING doc #152
add CONTRIBUTING doc #152
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅ 📢 Thoughts on this report? Let us know! |
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 taking the time to add this.
CONTRIBUTING.md
Outdated
git add . | ||
git commit -m "Description of changes" |
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.
git add .
is not a good idea either. git commit -a
will auto add changes to already tracked files.
git add . | |
git commit -m "Description of changes" | |
git add <path-to-newly-added-file-if-applicable> | |
git commit -am "Description of changes" |
CONTRIBUTING.md
Outdated
To adapt this `CONTRIBUTING.md` template for a specific project: | ||
1. Replace `[PROJECT_NAME]` with the name of your project. | ||
2. Replace `[REPOSITORY_URL]` with the URL of the main repository on GitHub. | ||
3. If needed, replace `[FORMAT_TOOL]` with the specific formatting tool or linter used in your project (e.g., `ruff`, `black`). |
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.
I think we can remove this line since we hide the tool behind tox
.
CONTRIBUTING.md
Outdated
|
||
Thank you for your interest in contributing to [PROJECT_NAME]! As a contributor, you’ll work from your fork of the main repository. This document outlines the steps to set up your development environment, guidelines for coding, and instructions for submitting contributions. | ||
|
||
## Customization Instructions |
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.
I think we can remove this entire section and hard-bake package_name
and ssec-jhu/base-template
such that project_setup.py can auto-correct these.
@ryanhausen that should work, right?
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.
Yes, I’ve hard-baked those two values. Note that this also requires updating project_setup.py to include processing for CONTRIBUTING.md.
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 seems to be already accounted for here:
def valid_file_predicate(file_path: Path) -> bool:
"""Checks if a file is valid for modification."""
is_valid_extension = file_path.suffix not in [
# images
".png",
".jpg",
".jpeg",
]
not_ds_store = file_path.name != ".DS_Store"
not_this = file_path.name != Path(__file__).name
return is_valid_extension and not_ds_store and not_this
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.
@ryanhausen can you confirm this, 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.
Yep! Just follow the convention used for the placeholders in other files and it should get replaced automatically.
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.
Thank you for the great feedback! I’ve made updates based on your suggestions. Please review it again.
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! Just 2 tiny changes regarding the project name vs repo name.
CONTRIBUTING.md
Outdated
@@ -28,35 +19,33 @@ After making these replacements, this file will be ready for use in your project | |||
3. **Clone Your Fork Locally**: | |||
- Once your fork is created, you can clone it to your local machine to start working: | |||
```bash | |||
git clone https://github.com/your-username/[PROJECT_NAME].git | |||
cd [PROJECT_NAME] | |||
git clone https://github.com/your-username/package_name.git |
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 needs to be the repo url, not the package name.
CONTRIBUTING.md
Outdated
git clone https://github.com/your-username/package_name.git | ||
cd package_name |
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.
Same here this is the repo name, not the package name, however, it might be easier to just leave this one as something like: cd <repo dir>
. @ryanhausen is there something in project_setup.py
that will pick up just the repo dir name?
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.
Yes, use repo dir enhance flexibility!
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.
Cool, thanks! But for clarity, it's not a point of flexibility, but that you used the repo URL and repo names don't have to match project/package names. So if/when they differ, this would break.
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.
Thank you for the thoughtful review! I've revised the changes accordingly. Please take another look.
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!
This PR addresses the documentation issue described in #151.