Skip to content

Commit df1b2a2

Browse files
committed
update_pr_template: introduce
1 parent 6242850 commit df1b2a2

2 files changed

Lines changed: 7 additions & 6 deletions

File tree

.github/pull_request_template.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ for an explanation on how to use task lists-->
2828
- [ ] The filename of my tutorial or article is `index.md`. In case of an Rmarkdown tutorial I have knitted my `index.Rmd` to `index.md` (both files are pushed to the repo).
2929
- [ ] I have included `tags` in the YAML header (see the tags listed in the [tutorials website side bar](https://inbo.github.io/tutorials/) for tags that have been used before)
3030
- [ ] I have added `categories` to the YAML header and my category tags are from the [list of category tags](https://github.com/inbo/tutorials/blob/master/static/list_of_categories)
31+
- [ ] I have previewed this PR locally (see steps below) and confirmed that the new content renders as expected.
3132

3233

3334
## Previewing the pull request
@@ -38,9 +39,9 @@ This provides a way to preview how these updates will look on the website, usefu
3839
### Instructions to preview the updated website
3940

4041
1) On the PR page, you can find a "details" link under "checks - On PR, build the site and ...". Go there, click on the top link in the left sidebar ("Summary"), and download the generated artifact at the bottom of the page.
41-
2) Decompress it into a target directory.
42-
3) From the target directory, run `python -m http.server 8887`, _or_ launch the Google Chrome [Web Server app](https://chrome.google.com/webstore/detail/web-server-for-chrome/ofhbbkphhbklhfoeikjpcbhemlocgigb) and point it at the target directory.
43-
4) Point your browser to http://0.0.0.0:8887.
42+
2) Decompress it into a target directory, e.g. `Downloads/tutorials_preview`.
43+
3) To preview the website, use a program which can serve `http` sites on your local machine. One such option is [the `servr` package](https://github.com/yihui/servr) in R: `& '\C:\Program Files\R\R-4.4.2\bin\Rscript.exe' -e "servr::httd('./tutorials_preview')" -p8887`
44+
4) Point your browser to http://localhost:8887.
4445
5) Review the updated website. As a contributor, you can push extra commits to update the PR. As a reviewer, you can accept/refuse/comment the PR.
4546

46-
**Note: for step 3, you can use any other simple HTTP server to serve the current directory if you don't have a Python 3 environment or Google Chrome available.**
47+
**Note: for step 3, you can use any other simple HTTP server to serve the current directory, e.g. [Python `http.server`](https://docs.python.org/3/library/http.server.html): `python -m http.server 8887 --bind localhost --directory path/to/tutorials_preview`**

content/create_tutorial/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,15 +172,15 @@ Replace all the CAPITAL words with appropriate information:
172172
- multiple tags you can pick yourself, all lowercase words. Have a look at the current [wordcloud](https://inbo.github.io/tutorials/tags/) to check which would be useful for your submission.
173173
- leave the `output` section as it is
174174

175-
Underneath the last triple dahs (`---`), you can write the tutorial as you like using [markdown syntax](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet) and add code chunks to run R code.
175+
Underneath the last triple dash (`---`), you can write the tutorial as you like using [markdown syntax](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet) and add code chunks to run R code.
176176

177177
As the Rmarkown file will not be part of the website, make sure to click the `knit` button to create the equivalent markdown file (`index.md`) in the same directory:
178178

179179
![](images/knit_md.png)
180180

181181
**Notice**: always knit the Rmarkdown file before you start committing the changes!
182182

183-
- `add`/`commit` **both files** to git, cfr. [STEP 2 of the workflow](https://inbo.github.io/git-course/workflow_rstudio.html#while_editing). You can commit the tutorial all in once or split the commits in different steps, that is up to you. To make sure your work is updated online as well, `push` the tutorial as in [STEP 3 of the workflow](https://inbo.github.io/git-course/workflow_rstudio.html#step_3:_push_your_changes_to_github).
183+
- `add`/`commit` **both files** to git, *cfr.* [STEP 2 of the workflow](https://inbo.github.io/git-course/workflow_rstudio.html#while_editing). You can commit the tutorial all in once or split the commits in different steps, that is up to you. To make sure your work is updated online as well, `push` the tutorial as in [STEP 3 of the workflow](https://inbo.github.io/git-course/workflow_rstudio.html#step_3:_push_your_changes_to_github).
184184
- When ready, `push` your tutorial a last time and create a `Pull request` to the website maintainers as explained in [STEP 4 of the workflow](https://inbo.github.io/git-course/workflow_rstudio.html#step_4:_pull_request_to_add_your_changes_to_the_current_master).
185185

186186
After you pull request, your submission will be checked and reviewed. When accepted and merged, you tutorial will be online.

0 commit comments

Comments
 (0)