Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ehumph authored Jan 19, 2024
0 parents commit 9923806
Show file tree
Hide file tree
Showing 770 changed files with 32,558 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/ISSUE_TEMPLATE/course-content-add.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
name: New content idea
about: Suggest an idea for the course
title: ''
labels: ''
assignees:

---

## Describe the your scope of your content idea
<!-- What will this cover and how does it relate to the current course material? -->

## Describe the learning objectives for your content idea
<!-- What will users learn from this new content? -->

## Additional context or resources
<!-- Add any other context or related resources we should know about? -->
28 changes: 28 additions & 0 deletions .github/ISSUE_TEMPLATE/course-problem-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
name: Course Problem Report
about: Create a report to help improve the course
title: [Problem]
labels: bug
assignees:

---

## Describe what is not working with the course
<!-- A clear and concise description of what the bug is. -->

## Steps to Reproduce
<!-- Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
-->

## Expected behavior
<!-- A clear and concise description of what you expected to happen. -->

## Screenshots
<!-- If applicable, add screenshots to help explain your problem. -->

## Additional context
<!-- Add any other context about the problem here. -->
40 changes: 40 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
<!--This PR Template was modified from https://github.com/AlexsLemonade/OpenPBTA-analysis/blob/master/.github/PULL_REQUEST_TEMPLATE.md-->

### Purpose/implementation Section

#### What changes are being implemented in this Pull Request?



#### What was your approach?



#### What GitHub issue does your pull request address?



### Tell potential reviewers what kind of feedback you are soliciting.



### New Content Checklist

- [ ] New content/chapter is in an Rmd file with [this kind of format and headers](https://github.com/jhudsl/OTTR_Template/blob/main/02-chapter_of_course.Rmd).

- [ ] New content/chapter contains [Learning Objectives and are in the correct format](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-images-and-graphics#learning-objectives-formatting).

- [ ] [Bookdown successfully re-renders and any new content files have been added to the _bookdown.yml](https://github.com/jhudsl/OTTR_Template/wiki/Publishing-with-Bookdown).

- [ ] Spell check runs successfully in [Github actions style-n-check](https://github.com/jhudsl/OTTR_Template/wiki/How-to-set-up-and-customize-GitHub-actions-robots#spell-check)).

- [ ] Any newly necessary packages that are needed have been added to the [Dockerfile and image](https://github.com/jhudsl/OTTR_Template/wiki/Using-Docker#adding-packages-to-the-dockerfile).

- [ ] Images are in the [correct format for rendering](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-images-and-graphics#adding-images-and-graphics-in-text).

- [ ] Every new image has [alt text and is in a Google Slide](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-images-and-graphics#accessibility).

- [ ] Each slide is described in the notes of the slide so learners relying on a screen reader can access the content. See https://lastcallmedia.com/blog/accessible-comics for more guidance on this.

- [ ] The color palette choices of the slide are contrasted in a way that is friendly to those with color vision deficiencies.
You can check this using [Color Oracle](https://colororacle.org/).
10 changes: 10 additions & 0 deletions .github/automatic-issues/add-feedback-method.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@

To help users report issues or areas of improvement for your course, you should provide a clear method of feedback for your users to route their concerns through.

A feedback method (Google Form) has already been provided for AnVIL and GDSCN courses. Github actions automatically populates the Google Form with the `title` field from [`index.Rmd`](https://github.com/jhudsl/AnVIL_Template/blob/main/index.Rmd) using the [AnVIL Feedback Script](https://github.com/jhudsl/AnVIL_Template/blob/main/scripts/AnVIL_Feedback_Script.sh).

- [ ] The `title` field has been filled out in the header yaml of `index.Rmd`.

*No further action is needed on your part*. However, if you would like to change the feedback method, you can do so by editing [this line of code](https://github.com/jhudsl/AnVIL_Template/blob/7c501e9804cf88a151832bb0a9bbc1eae9d23fdf/_output.yml#L19) in `_output.yml`.

[See these instructions](https://docs.google.com/document/d/1uhGafEkbtJL3ar3TVHqRFypwTbXjudHa7h2mXu53CkA/edit?usp=sharing) for how to manually create a feedback link for AnVIL / GDSCN content or events.
14 changes: 14 additions & 0 deletions .github/automatic-issues/add-repo-to-anvil-collection.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@

If you want this repository to be added to the AnVIL Collection, make sure you do the following:

- Click the gear icon on the top right of the "Code" page next to "About"
- [ ] Create a repository description
- [ ] Add the homepage where your course will be rendered
- [ ] Add a description of your course/content
- [ ] Add the topic tag `anvil` or `gdscn`. You should also supply any other relevant tags.

Following these steps will also automatically add this repository to the [AnVIL Collection](https://hutchdatascience.org/AnVIL_Collection/) if this repository is owned by one of the DaSL organizations.

For more information on these settings see instructions in the [wiki pages](https://github.com/jhudsl/AnVIL_Template/wiki/The-AnVIL-Collection#adding-your-course-to-the-anvil-collection).

For more information about adding repositories to the DaSL Collection, see the [AnVIL Collection README](https://github.com/fhdsl/AnVIL_Collection#readme).
14 changes: 14 additions & 0 deletions .github/automatic-issues/git-secrets.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@

**Note these steps are only pertinent if you are setting up this course outside of the jhudsl organization**

For more information on these settings see instructions in the [getting started GitHub wiki pages](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-GitHub-secrets).

It's important that these are set up and named exactly what they are below in order for Github actions to work correctly.

To set up these repository secrets, on your repository's main Github page, go to `Settings` and scroll down to see `Secrets` on the left side menu bar.

- [ ] Set `GH_PAT`
`Name`: `GH_PAT`
`value`: A personal access token [following these instructions](https://github.com/jhudsl/OTTR_Template/wiki/Start-a-new-course#6-set-up-your-github-personal-access-token).
Underneath `Select scopes`, check both `repo` and `workflow`.
Then copy the PAT and save as the value.
25 changes: 25 additions & 0 deletions .github/automatic-issues/images-checklist.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

Use this checklist to make sure your slides and images are set up correctly!

See [Setting Up Images and Graphics](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-images-and-graphics) for more info!

- [ ] Create your [course's main Google Slides](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-images-and-graphics)

- [ ] The slides use the [appropriate template](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-images-and-graphics).

- [ ] Each slide is described in the notes of the slide so learners relying on a screen reader can access the content. See https://lastcallmedia.com/blog/accessible-comics for more guidance on this.

- [ ] The color palette choices of the slide are contrasted in a way that is friendly to those with color vision deficiencies.
You can check this using [Color Oracle](https://colororacle.org/).

- [ ] Every image is [inserted into the text](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-images-and-graphics#adding-images-and-graphics-in-text) using one of these options: `ottrpal::include_slide()`, `knitr::include_image()`, or this format: `<img src="blah.png" alt="SOMETHING">`.

- [ ] Every image has [alternative text added to it](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-images-and-graphics#adding-images-and-graphics-in-text).

- [ ] The beginning of each Rmd contains this chunk so the images are saved in the correct spot:

`````
```{r, include = FALSE}
ottrpal::set_knitr_image_path()
```
`````
25 changes: 25 additions & 0 deletions .github/automatic-issues/set-repo-settings.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

For more information on these settings see instructions in the [getting started GitHub wiki pages](https://github.com/jhudsl/OTTR_Template/wiki/Start-a-new-course).

- [ ] This course repository is set to `public`.
- [ ] [Add the `jhudsl-robot` as a collaborator to your repository.](https://github.com/jhudsl/OTTR_Template/wiki/Setting-up-your-repository-settings#add-jhudsl-robot-as-a-collaborator).
- [ ] [GH_PAT has been set up as a GitHub secret](https://github.com/jhudsl/OTTR_Template/wiki/Start-a-new-course#6-set-up-your-github-personal-access-token)

- [ ] GitHub pages is turned on
- [ ] Go to `Settings` > `Pages`. Underneath `Source`, choose `main` for the branch and select the `docs` folder. Then click `Save`.
- [ ] Check `Enforce HTTPS`.

- [ ] [Github secret `GH_PAT` has been set](https://github.com/jhudsl/OTTR_Template/wiki/Start-a-new-course#6-set-up-your-github-personal-access-token)
`Name`: `GH_PAT`
`value`: A personal access token [following these instructions](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#creating-a-token).
Underneath `Select scopes`, check both `repo` and `workflow`.
Then copy the PAT and save as the value.

- [ ] [Set branch protections settings](https://github.com/jhudsl/OTTR_Template/wiki/Start-a-new-course#9-set-up-branch-rules)
- [ ] `main` branch has been set up:
- [ ] `Require pull request reviews before merging` box is checked.
- [ ] `Require status checks to pass before merging` box is checked.
- [ ] Underneath that `Require branches to be up to date before merging` box is checked.
- [ ] Click `Save` at the bottom of the page!

- [ ] [Customize GitHub actions](https://github.com/jhudsl/OTTR_Template/wiki/How-to-set-up-and-customize-GitHub-actions-robots) for what you will need in this course.
34 changes: 34 additions & 0 deletions .github/automatic-issues/templates-to-edit.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@

[Follow the Wiki instructions here](https://github.com/jhudsl/OTTR_Template/wiki/Start-editing-your-course) for details on how to complete the items in this issue.

The following files need to be edited to get this new course started!

### Files that need edited upon creating a new course.

- [ ] `README.md` - Fill in all the `{ }`.
- [ ] `index.Rmd` - `title:` should be updated.
- [ ] `01-intro.Rmd` - replace the information there with information pertinent to this new course.
- [ ] `02-chapter_of_course.Rmd` - This Rmd has examples of how to set things up, if you don't need it as a reference, it can be deleted.

### Files that need to be edited upon adding each new chapter (including upon creating a new course):

- [ ] `_bookdown.yml` - The list of Rmd files that need to be rendered needs to be updated. See [instructions](https://github.com/jhudsl/OTTR_Template/wiki/Publishing-with-Bookdown).
- [ ] `book.bib` - any citations need to be added. See [instructions](https://github.com/jhudsl/OTTR_Template/wiki/Citations).

### Picking a style

See more [about customizing style on this page in the guide](https://github.com/jhudsl/OTTR_Template/wiki/Change-Title-&-Customize-style).
By default this course template will use the jhudsl data science lab style. However, you can customize and switch this to another style set.

#### Using a style set

[Read more about the style sets here](https://github.com/jhudsl/OTTR_Template/wiki/Change-Title-&-Customize-style#using-a-style-set).

- [ ] On a new branch, copy the `style-sets/<set-name>/index.Rmd` and `style-sets/<set-name>/_output.yml` to the top of the repository to overwrite the default `index.Rmd` and `_output.yml`.
- [ ] Copy over all the files in the `style-sets/<set-name>/copy-to-assets` to the `assets` folder in the top of the repository.
- [ ] [Create a pull request](https://github.com/jhudsl/OTTR_Template/wiki/Start-editing-your-course#getting-started-with-the-github-workflow) with these changes, and double check the rendered preview to make sure that the style is what you are looking for.

### Files that need to be edited upon adding new packages that the book's code uses:

- `docker/Dockerfile` needs to have the new package added so it will be installed. See [instructions](https://github.com/jhudsl/OTTR_Template/wiki/Using-Docker#starting-a-new-docker-image).
- The code chunk in `index.Rmd` should be edited to add the new package.
9 changes: 9 additions & 0 deletions .github/automatic-issues/update-enrollment.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@

The original template: https://github.com/jhudsl/OTTR_Template is always a work in progress.
We are working on adding more features and smoothing out bugs as we go. The AnVIL Template collects these and can pass them along to this repository.

If you want to receive updates from the AnVIL template to your course template, you will need to enroll this repository to the template updates by adding it to the `sync.yml` file.

- [ ] [Follow these instructions](https://github.com/jhudsl/AnVIL_Template/wiki/Start-a-New-Book-or-Course#enroll-your-repository-for-anvil-updates) to enroll your course repository to receive these updates.

- [ ] [Ensure that you have followed these instructions](https://github.com/jhudsl/OTTR_Template/wiki/Start-a-new-course#5-add-jhudsl-robot-as-a-collaborator) to add the `jhudsl-robot` as a collaborator to your repository.
39 changes: 39 additions & 0 deletions .github/switch_sync_repo.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
#!/usr/bin/env Rscript

# This script switches the repo entry for the yaml file to whatever is specified
# Written by Candace Savonen Jan 2022

if (!("optparse" %in% installed.packages())){
install.packages("optparse")
}

library(optparse)

option_list <- list(
optparse::make_option(
c("--repo"),
type = "character",
default = "jhudsl/OTTR_Template_Test",
help = "GitHub repository name, e.g. jhudsl/OTTR_Template_Test",
)
)

# Read the arguments passed
opt_parser <- optparse::OptionParser(option_list = option_list)
opt <- optparse::parse_args(opt_parser)

# Find .git root directory
root_dir <- rprojroot::find_root(rprojroot::has_dir(".git"))

# Get test sync yaml path
sync_file_path <- file.path(root_dir, ".github", "test-sync.yml")

yaml_contents <- yaml::yaml.load_file(sync_file_path)

# Only keep first grouping
yaml_contents$group <- yaml_contents$group[[1]]

# Switch out repo
yaml_contents$group$repos <- opt$repo

yaml::write_yaml(yaml_contents, sync_file_path)
114 changes: 114 additions & 0 deletions .github/sync.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,114 @@
# For info on how to update this file see: https://github.com/marketplace/actions/repo-file-sync-action#%EF%B8%8F-sync-configuration

group:
- files:
- source: .github/workflows/
dest: .github/workflows/
exclude: |
send-updates.yml
test-send-updates.yml
starting-course.yml
release-notes.yml
- source: .github/ISSUE_TEMPLATE/course-problem-report.md
dest: .github/ISSUE_TEMPLATE/course-problem-report.md
- source: .github/ISSUE_TEMPLATE/course-content-add.md
dest: .github/ISSUE_TEMPLATE/course-content-add.md
- source: scripts/ottr-fy.R
dest: scripts/ottr-fy.R
- source: scripts/git_repo_check.R
dest: scripts/git_repo_check.R
- source: scripts/make_screenshots.R
dest: scripts/make_screenshots.R
- source: scripts/AnVIL_Feedback_Script.sh
dest: scripts/AnVIL_Feedback_Script.sh
- source: code_of_conduct.md
dest: code_of_conduct.md
- source: style-sets
dest: style-sets
- source: assets/box_images/
dest: assets/box_images/
- source: assets/AnVIL_style/
dest: assets/AnVIL_style/
deleteOrphaned: true
- source: assets/GDSCN_style/
dest: assets/GDSCN_style/
deleteOrphaned: true
- source: assets/itcr_arrow.png
dest: assets/itcr_arrow.png
- source: assets/style.css
dest: assets/style.css
- source: assets/toc_close.css
dest: assets/toc_close.css
# Repositories to receive changes
repos: |
fhdsl/AnVIL_Book_Epigenetics_Intro
fhdsl/AnVIL_SRA_Data
fhdsl/AnVIL_Urban_Genomics_PCA
fhdsl/GDSCN_SARS_RStudio_on_AnVIL
jhudsl/AnVIL_Book_Getting_Started
jhudsl/AnVIL_Book_Instructor_Guide
jhudsl/AnVIL_Book_WDL
jhudsl/AnVIL_Phylogenetic-Techniques
jhudsl/GDSCN_Book_SARS_Galaxy_on_AnVIL
jhudsl/GDSCN_Book_Statistics_for_Genomics_Differential_Expression
jhudsl/GDSCN_Book_Statistics_for_Genomics_PCA
jhudsl/GDSCN_Book_Statistics_for_Genomics_RNA-seq
jhudsl/GDSCN_Book_Statistics_for_Genomics_scRNA-seq
jhudsl/GDSCN_Book_swirl
###ADD NEW REPO HERE following the format above#

# AnVIL repos should sync AnVIL version of _output.yml
- files:
- source: _output.yml
dest: _output.yml
repos: |
fhdsl/AnVIL_Book_Epigenetics_Intro
fhdsl/AnVIL_Collection
fhdsl/AnVIL_Data_Subsetting
fhdsl/AnVIL_Demos
fhdsl/AnVIL_SRA_Data
fhdsl/AnVIL_Urban_Genomics_PCA
jhudsl/AnVIL_Book_WDL
# GDSCN repos should sync the GDSCN version of _output.yml
# They should also sync the top level assets into an AnVIL style-set
- files:
- source: style-sets/GDSCN/_output.yml
dest: _output.yml
- source: _output.yml
dest: style-sets/AnVIL/_output.yml
- source: index.Rmd
dest: style-sets/AnVIL/index.Rmd
repos: |
fhdsl/GDSCN_SARS_RStudio_on_AnVIL
jhudsl/GDSCN_Template_Test
# Repos where Hopkins took the lead have JHU branding instead of Hutch
- files:
- source: style-sets/AnVIL_JHU/_output.yml
dest: _output.yml
- source: _output.yml
dest: style-sets/AnVIL/_output.yml
- source: index.Rmd
dest: style-sets/AnVIL/index.Rmd
repos: |
jhudsl/AnVIL_Book_Getting_Started
jhudsl/AnVIL_Book_Instructor_Guide
jhudsl/AnVIL_Phylogenetic-Techniques
- files:
- source: style-sets/GDSCN_JHU/_output.yml
dest: _output.yml
- source: _output.yml
dest: style-sets/AnVIL/_output.yml
- source: index.Rmd
dest: style-sets/AnVIL/index.Rmd
repos: |
jhudsl/GDSCN_Book_SARS_Galaxy_on_AnVIL
jhudsl/GDSCN_Book_Statistics_for_Genomics_Differential_Expression
jhudsl/GDSCN_Book_Statistics_for_Genomics_PCA
jhudsl/GDSCN_Book_Statistics_for_Genomics_RNA-seq
jhudsl/GDSCN_Book_Statistics_for_Genomics_scRNA-seq
jhudsl/GDSCN_Book_swirl
Loading

0 comments on commit 9923806

Please sign in to comment.