Skip to content

Commit 4c05d54

Browse files
authored
Fixed #414 Added fork syncing, checkbox fix to Contribute.ipynb
* Added fork syncing to Contribute.ipynb; #414 A new section was added to the contributing guide, Contribute.ipynb, summarizing the steps of syncing a fork to the upstream/main branch. * Fixed checkbox rendering issue in Contribute.ipynb; #414 * Added both methods for upstream fetching, #414 Both methods, fetching locally and fetching through Github, are now covered in Contribute.ipynb. The screenshot demonstrating the latter method was changed to a screenshot of a stumpy fork. The instructions for synching fork was also moved up to be between sections that describe pushing changes and starting a pull requests.
1 parent 589630e commit 4c05d54

2 files changed

Lines changed: 76 additions & 49 deletions

File tree

docs/Contribute.ipynb

Lines changed: 76 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@
2222
"> Warning: Don't confuse git and GitHub. Git is a tool used for version control. GitHub is an online platform used as a remote repository for git projects.\n",
2323
"\n",
2424
"Checklist: \n",
25-
"[ ] Create GitHub account \n",
26-
"[ ] Install Git"
25+
"- [ ] Create GitHub account \n",
26+
"- [ ] Install Git"
2727
]
2828
},
2929
{
@@ -53,9 +53,9 @@
5353
"> Warning: If you can tell someone else is actively working on an issue, don't take it.\n",
5454
"\n",
5555
"Checklist: \n",
56-
"[ ] Identify an issue \n",
57-
"[ ] Read CONTRIBUTING.md \n",
58-
"[ ] Post your proposal in the issue"
56+
"- [ ] Identify an issue \n",
57+
"- [ ] Read CONTRIBUTING.md \n",
58+
"- [ ] Post your proposal in the issue"
5959
]
6060
},
6161
{
@@ -77,9 +77,9 @@
7777
"> Warning: Create your branch before making any changes.\n",
7878
"\n",
7979
"Checklist: \n",
80-
"[ ] Fork STUMPY to your own account \n",
81-
"[ ] Clone a local copy for your fork\n",
82-
"[ ] Create a branch for your work"
80+
"- [ ] Fork STUMPY to your own account \n",
81+
"- [ ] Clone a local copy for your fork\n",
82+
"- [ ] Create a branch for your work"
8383
]
8484
},
8585
{
@@ -99,9 +99,9 @@
9999
"If all of the tests pass, then you know that you have a working copy of STUMPY to start your development on. Go ahead and implement your feature or change!\n",
100100
"\n",
101101
"Checklist: \n",
102-
"[ ] Create a virtual environment \n",
103-
"[ ] Install dependencies \n",
104-
"[ ] Run the unit tests"
102+
"- [ ] Create a virtual environment \n",
103+
"- [ ] Install dependencies \n",
104+
"- [ ] Run the unit tests"
105105
]
106106
},
107107
{
@@ -117,10 +117,10 @@
117117
"Next, run `flake8` and `black`. [flake8](https://flake8.pycqa.org/en/latest/) is a linter that checks the style and quality of the code. [black](https://pypi.org/project/black/) makes any necessary changes to ensure consistent code format.\n",
118118
"\n",
119119
"Checklist: \n",
120-
"[ ] Write/update any unit tests \n",
121-
"[ ] Run `black` to reformat any python files you changed \n",
122-
"[ ] Run `flake8` to identify any formatting errors before you submit your `pull request` \n",
123-
"[ ] Run the unit tests. In STUMPY, you'll run `./setup.sh && ./tests.sh`"
120+
"- [ ] Write/update any unit tests \n",
121+
"- [ ] Run `black` to reformat any python files you changed \n",
122+
"- [ ] Run `flake8` to identify any formatting errors before you submit your `pull request` \n",
123+
"- [ ] Run the unit tests. In STUMPY, you'll run `./setup.sh && ./tests.sh`"
124124
]
125125
},
126126
{
@@ -138,9 +138,36 @@
138138
"> Warning: If this is your first time using git, it may through a warning about global settings. Luckily, that warning tells you exactly how to fix it.\n",
139139
"\n",
140140
"Checklist: \n",
141-
"[ ] `git add your_file` \n",
142-
"[ ] `git commit -m 'Great Commit Message'` \n",
143-
"[ ] `git push`"
141+
"- [ ] `git add your_file` \n",
142+
"- [ ] `git commit -m 'Great Commit Message'` \n",
143+
"- [ ] `git push`"
144+
]
145+
},
146+
{
147+
"cell_type": "markdown",
148+
"metadata": {},
149+
"source": [
150+
"## Sync your Fork with the Parent Repository\n",
151+
"\n",
152+
"While you are working on your development branch, it is likely that the STUMPY repository will have undergone new changes that your fork does not have. It is recommended, therefore, to sync your fork with its parent repository before submitting a pull request. For more information refer to the [Github documentation](https://docs.github.com/en/github/collaborating-with-pull-requests/working-with-forks/syncing-a-fork).\n",
153+
"\n",
154+
"Checklist (fetching upstream through Github): \n",
155+
"- [ ] Sync your fork with the upstream/parent repository (see screenshot below) \n",
156+
"- [ ] `git checkout main` \n",
157+
"- [ ] `git pull` \n",
158+
"- [ ] `git checkout branch_name` \n",
159+
"- [ ] `git merge main` \n",
160+
"- [ ] Run the unit tests: `./setup.sh && ./tests.sh` \n",
161+
"\n",
162+
"Checklist (fetching upstream locally): \n",
163+
"- [ ] `git fetch upstream`\n",
164+
"- [ ] `git checkout main` \n",
165+
"- [ ] `git merge upstream/main` \n",
166+
"- [ ] `git checkout branch_name` \n",
167+
"- [ ] `git merge main` \n",
168+
"- [ ] Run the unit tests: `./setup.sh && ./tests.sh` \n",
169+
"\n",
170+
"![Fetch Upstream Fork](images/fetch_upstream_fork.png) "
144171
]
145172
},
146173
{
@@ -156,9 +183,9 @@
156183
"Continuous integration systems automatically determine the suitability of merging pull requests. They check the formatting, test coverage, and test success of your code. After you submit a pull request, you'll see these running (as comments in your pull request). If they fail, your code will not be merged until the failure is fixed. In STUMPY, locally passing `flake8`, `black`, and `./setup.sh && ./tests.sh` should ensure your continuous integration tests pass.\n",
157184
"\n",
158185
"Checklist: \n",
159-
"[ ] Create a Pull Request \n",
160-
"[ ] Write an informative Pull Request Message \n",
161-
"[ ] Monitor your Pull Request for continuous integration checks and messages from the maintainers"
186+
"- [ ] Create a Pull Request \n",
187+
"- [ ] Write an informative Pull Request Message \n",
188+
"- [ ] Monitor your Pull Request for continuous integration checks and messages from the maintainers"
162189
]
163190
},
164191
{
@@ -172,7 +199,7 @@
172199
"> Warning: After every change, make sure to run your formatting checks and unit tests.\n",
173200
"\n",
174201
"Checklist: \n",
175-
"[ ] Be open minded, responsive, and polite"
202+
"- [ ] Be open minded, responsive, and polite"
176203
]
177204
},
178205
{
@@ -184,8 +211,8 @@
184211
"When the contribution is nice and polished, the maintainers will `merge` it into STUMPY. **Success!**\n",
185212
"\n",
186213
"Checklist: \n",
187-
"[ ] Celebrate \n",
188-
"[ ] Go find another issue"
214+
"- [ ] Celebrate \n",
215+
"- [ ] Go find another issue"
189216
]
190217
},
191218
{
@@ -210,30 +237,30 @@
210237
},
211238
"source": [
212239
"## Final Checklist:\n",
213-
"[ ] Create GitHub account \n",
214-
"[ ] Install Git \n",
215-
"[ ] Identify an issue \n",
216-
"[ ] Read CONTRIBUTING.md \n",
217-
"[ ] Post your proposal in the issue \n",
218-
"[ ] Fork STUMPY to your own account \n",
219-
"[ ] Clone a local copy \n",
220-
"[ ] Create a branch for your work \n",
221-
"[ ] Create a virtual environment \n",
222-
"[ ] Install dependencies \n",
223-
"[ ] Run the unit tests \n",
224-
"[ ] Write/update any unit tests \n",
225-
"[ ] Run `black` to reformat any python files you changed \n",
226-
"[ ] Run `flake8` to identify any formatting errors before you submit your `pull request` \n",
227-
"[ ] Run the unit tests. In STUMPY, you'll run `./setup.sh && ./tests.sh` \n",
228-
"[ ] `git add your_file` \n",
229-
"[ ] `git commit -m 'Great Commit Message'` \n",
230-
"[ ] `git push` \n",
231-
"[ ] Create a Pull Request \n",
232-
"[ ] Write an informative Pull Request Message \n",
233-
"[ ] Monitor your Pull Request for continuous integration checks and messages from the maintainers \n",
234-
"[ ] Be open minded, responsive, and polite \n",
235-
"[ ] Celebrate \n",
236-
"[ ] Go find another issue "
240+
"- [ ] Create GitHub account \n",
241+
"- [ ] Install Git \n",
242+
"- [ ] Identify an issue \n",
243+
"- [ ] Read CONTRIBUTING.md \n",
244+
"- [ ] Post your proposal in the issue \n",
245+
"- [ ] Fork STUMPY to your own account \n",
246+
"- [ ] Clone a local copy \n",
247+
"- [ ] Create a branch for your work \n",
248+
"- [ ] Create a virtual environment \n",
249+
"- [ ] Install dependencies \n",
250+
"- [ ] Run the unit tests \n",
251+
"- [ ] Write/update any unit tests \n",
252+
"- [ ] Run `black` to reformat any python files you changed \n",
253+
"- [ ] Run `flake8` to identify any formatting errors before you submit your `pull request` \n",
254+
"- [ ] Run the unit tests. In STUMPY, you'll run `./setup.sh && ./tests.sh` \n",
255+
"- [ ] `git add your_file` \n",
256+
"- [ ] `git commit -m 'Great Commit Message'` \n",
257+
"- [ ] `git push` \n",
258+
"- [ ] Create a Pull Request \n",
259+
"- [ ] Write an informative Pull Request Message \n",
260+
"- [ ] Monitor your Pull Request for continuous integration checks and messages from the maintainers \n",
261+
"- [ ] Be open minded, responsive, and polite \n",
262+
"- [ ] Celebrate \n",
263+
"- [ ] Go find another issue "
237264
]
238265
}
239266
],
@@ -253,7 +280,7 @@
253280
"name": "python",
254281
"nbconvert_exporter": "python",
255282
"pygments_lexer": "ipython3",
256-
"version": "3.9.4"
283+
"version": "3.6.8"
257284
}
258285
},
259286
"nbformat": 4,
584 KB
Loading

0 commit comments

Comments
 (0)