Skip to content

Commit 6db0d58

Browse files
authored
Merge pull request #88 from jhudsl/repo-sync/OTTR_Template/default
🔄 Synced file(s) with jhudsl/OTTR_Template
2 parents 7e85c3c + 505457f commit 6db0d58

File tree

4 files changed

+31
-24
lines changed

4 files changed

+31
-24
lines changed

.github/workflows/check-url.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ jobs:
4545
- name: Make the branch fresh
4646
run: |
4747
git config --global --add safe.directory $GITHUB_WORKSPACE
48-
git config --global user.email "[email protected]"
49-
git config --global user.name "jhudsl-robot"
48+
git config --global user.name 'github-actions[bot]'
49+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
5050
5151
echo branch doesnt exist
5252
git checkout -b preview-spell-error || echo branch exists

.github/workflows/pull_request.yml

Lines changed: 15 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ jobs:
3333
- name: Make the branch fresh
3434
run: |
3535
git config --global --add safe.directory $GITHUB_WORKSPACE
36-
git config --global user.email "[email protected]"
37-
git config --global user.name "jhudsl-robot"
36+
git config --global user.name 'github-actions[bot]'
37+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
3838
3939
branch_name='preview-${{ github.event.pull_request.number }}'
4040
echo branch doesnt exist
@@ -130,8 +130,8 @@ jobs:
130130
- name: Set up git checkout
131131
run: |
132132
git config --global --add safe.directory $GITHUB_WORKSPACE
133-
git config --global user.email "[email protected]"
134-
git config --global user.name "jhudsl-robot"
133+
git config --global user.name 'github-actions[bot]'
134+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
135135
136136
branch_name='preview-${{ github.event.pull_request.number }}'
137137
git fetch --all
@@ -160,6 +160,9 @@ jobs:
160160
echo Toc-less status ${{steps.tocless.outcome}}
161161
exit 1
162162
163+
- name: Website preview for download
164+
run: zip website-preview.zip docs/* -r
165+
163166
# Commit the rendered bookdown files
164167
- name: Commit rendered bookdown files to preview branch
165168
id: commit
@@ -188,6 +191,8 @@ jobs:
188191
bookdown_link=$(echo "https://htmlpreview.github.io/?https://raw.githubusercontent.com/$GITHUB_REPOSITORY/preview-${{ github.event.pull_request.number }}/docs/index.html")
189192
tocless_link=$(echo "https://htmlpreview.github.io/?https://raw.githubusercontent.com/$GITHUB_REPOSITORY/preview-${{ github.event.pull_request.number }}/docs/no_toc/index.html")
190193
docx_link=$(echo "https://github.com/$GITHUB_REPOSITORY/raw/preview-${{ github.event.pull_request.number }}/docs/$course_name.docx")
194+
zip_link=$(echo "https://github.com/$GITHUB_REPOSITORY/raw/preview-${{ github.event.pull_request.number }}/website-preview.zip")
195+
echo "zip_link=$zip_link" >> $GITHUB_OUTPUT
191196
echo "bookdown_link=$bookdown_link" >> $GITHUB_OUTPUT
192197
echo "tocless_link=$tocless_link" >> $GITHUB_OUTPUT
193198
echo "docx_link=$docx_link" >> $GITHUB_OUTPUT
@@ -203,11 +208,13 @@ jobs:
203208
issue-number: ${{ github.event.pull_request.number }}
204209
body: |
205210
Re-rendered previews from the latest commit:
206-
- See [preview of Bookdown here](${{ steps.build-components.outputs.bookdown_link }})
207-
- See [preview of Coursera/Leanpub version here](${{ steps.build-components.outputs.tocless_link }})
208-
- Download the [preview of .docx file](${{ steps.build-components.outputs.docx_link }})
211+
- :eyes: Quick [preview of course website here](${{ steps.build-components.outputs.bookdown_link }}) \*
212+
- :microscope: Comprehensive [download of the course website here](${{ steps.build-components.outputs.zip_link }})
213+
- Download the [.docx file](${{ steps.build-components.outputs.docx_link }})
209214
210-
_Updated at ${{ steps.build-components.outputs.time }} with changes from ${{ steps.build-components.outputs.commit_id }}_
215+
\* note not all html features will be properly displayed in the "quick preview" but it will give you a rough idea.
216+
217+
_Updated at ${{ steps.build-components.outputs.time }} with changes from the latest commit ${{ steps.build-components.outputs.commit_id }}_
211218
edit-mode: replace
212219

213220
- name: Comment if no changes

.github/workflows/render-all.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,11 @@ jobs:
4949
fetch-depth: 0
5050
token: ${{ secrets.GH_PAT }}
5151

52-
- name: Login as jhudsl-robot
52+
- name: Login as github actions bot
5353
run: |
5454
git config --global --add safe.directory $GITHUB_WORKSPACE
55-
git config --global user.email "[email protected]"
56-
git config --global user.name "jhudsl-robot"
55+
git config --global user.name 'github-actions[bot]'
56+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
5757
5858
# We want a fresh run of the renders each time
5959
- name: Delete old docs/*
@@ -101,11 +101,11 @@ jobs:
101101
fetch-depth: 0
102102
token: ${{ secrets.GH_PAT }}
103103

104-
- name: Login as jhudsl-robot
104+
- name: Login as github-actions bot
105105
run: |
106106
git config --global --add safe.directory $GITHUB_WORKSPACE
107-
git config --global user.email "[email protected]"
108-
git config --global user.name "jhudsl-robot"
107+
git config --global user.name 'github-actions[bot]'
108+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
109109
110110
# Rendered content for Leanpub and Coursera is very similar.
111111
# This job creates a shared scaffold for both.
@@ -140,11 +140,11 @@ jobs:
140140
fetch-depth: 0
141141
token: ${{ secrets.GH_PAT }}
142142

143-
- name: Login as jhudsl-robot
143+
- name: Login as github actions bot
144144
run: |
145145
git config --global --add safe.directory $GITHUB_WORKSPACE
146-
git config --global user.email "[email protected]"
147-
git config --global user.name "jhudsl-robot"
146+
git config --global user.name 'github-actions[bot]'
147+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
148148
149149
# Create screenshots
150150
- name: Run the screenshot creation
@@ -217,11 +217,11 @@ jobs:
217217
fetch-depth: 0
218218
token: ${{ secrets.GH_PAT }}
219219

220-
- name: Login as jhudsl-robot
220+
- name: Login as github action
221221
run: |
222222
git config --global --add safe.directory $GITHUB_WORKSPACE
223-
git config --global user.email "[email protected]"
224-
git config --global user.name "jhudsl-robot"
223+
git config --global user.name 'github-actions[bot]'
224+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
225225
226226
# Run Coursera version
227227
- name: Convert Leanpub quizzes to Coursera

resources/exclude_files.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ About.Rmd
22
docs/*
33
style-sets/*
44
manuscript/*
5+
CONTRIBUTING.md
6+
LICENSE.md
57
code_of_conduct.md
68
README.md
7-
README-template.md
8-
reproducibility-checklist.md

0 commit comments

Comments
 (0)