generated from TIBHannover/markdown-documents-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 1ca978f
Showing
11 changed files
with
216 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Initialize repo from template | ||
on: [push] | ||
jobs: | ||
init: | ||
name: Reinitialize repository | ||
runs-on: ubuntu-latest | ||
permissions: | ||
# Give the default GITHUB_TOKEN write permission to commit and push the changed files back to the repository. | ||
contents: write | ||
steps: | ||
- name: Exit for template repository | ||
shell: bash | ||
run: | | ||
curl --silent -X GET \ | ||
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \ | ||
-H "Accept: application/json" \ | ||
$GITHUB_API_URL/repos/$GITHUB_REPOSITORY \ | ||
| jq --exit-status '.is_template == false' | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Initialize | ||
shell: bash | ||
run: ./.init-repo.sh | ||
env: | ||
REPO_NAME: ${{ github.event.repository.name }} | ||
|
||
- name: Commit changes | ||
uses: stefanzweifel/git-auto-commit-action@v4 | ||
with: | ||
commit_message: "Initialized repo" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: Publish documents | ||
on: [push] | ||
|
||
env: | ||
OUTPUT_FILENAME: "document" | ||
USER_AGENT: "$GITHUB_REPOSITORY ($GITHUB_SERVER_URL/$GITHUB_REPOSITORY)" | ||
|
||
jobs: | ||
prepare-and-build-documents: | ||
runs-on: ubuntu-latest | ||
container: | ||
image: registry.gitlab.com/tibhannover/oer/markdown-pandoc-processor | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- run: | | ||
/build/process.sh | ||
ls -l | ||
mkdir .public | ||
cp -r * .public | ||
mv .public public | ||
- uses: actions/upload-pages-artifact@v1 | ||
with: | ||
path: ./public | ||
|
||
# Deployment job | ||
deploy: | ||
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages | ||
permissions: | ||
pages: write | ||
id-token: write | ||
environment: | ||
name: github-pages | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
runs-on: ubuntu-latest | ||
needs: prepare-and-build-documents | ||
steps: | ||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#!/bin/sh | ||
|
||
# adjust links in readme file | ||
sed -i "s,tibhannover.github.io/markdown-documents-template,${GITHUB_REPOSITORY_OWNER}.github.io/$REPO_NAME,g" README.md | ||
cat README.md | ||
|
||
# cleanup init-filees | ||
rm .init-repo.sh | ||
rm .github/workflows/initialize-repo.yml | ||
rm LICENSE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2023 Technische Informationsbibliothek (TIB) | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Template for OER | ||
|
||
This is a template for open and freely licensed texts that delivers appealing, and depending on the template, multimedia results. It additionally automates a lot of laborious work during creation. This template can be used for courses or modules as well as for all sorts of texts, including student research papers or theses. | ||
|
||
* generates metadata in HTML headers for OER repositories and Google search | ||
* automatically creates license notices for Wikimedia images with machine-readable notices according to CC REL | ||
* inserts license notice in generated documents | ||
|
||
With every save (commit) the documents are generated and available via: | ||
|
||
* [landing page](https://tibhannover.github.io/markdown-documents-template/) | ||
|
||
or directly | ||
* [Ebook](https://tibhannover.github.io/markdown-documents-template/document.epub) | ||
* [PDF](https://tibhannover.github.io/markdown-documents-template/document.pdf) | ||
* [HTML](https://tibhannover.github.io/markdown-documents-template/document.html) | ||
|
||
# Use this template | ||
|
||
1. Create a new repository based on this template | ||
* click the green button `Use this template` or click [here](https://github.com/TIBHannover/markdown-documents-template/generate) | ||
* enter a name for the new repository and click on `Create repository from template` | ||
1. In [settings -> pages](../../settings/pages): choose `GitHub Actions` as Source | ||
1. Adjust [metadata.yml](../../edit/main/metadata.yml) | ||
* edit manually or | ||
* create metadata with [generator](https://oersi.gitlab.io/metadata-form/metadata-generator.html) and copy/paste content into metadata.yml | ||
1. Output files will be generated automatically and available after aprox. 1 min | ||
1. Create your content in Markdown files (default chapterXX.md) | ||
1. You can overwrite this _README.md_ as you like | ||
|
||
# Configuration | ||
|
||
See https://gitlab.com/TIBHannover/oer/markdown-pandoc-processor#options | ||
|
||
# License notice | ||
This template for OER courses is released under MIT. The content of the document is subject to the respective license as indicated at the end of the generated files or in the metadata.yml. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Pythagorean theorem | ||
|
||
## Representation | ||
|
||
![Representation of the Pythagorean Theorem](https://upload.wikimedia.org/wikipedia/commons/d/d1/01-Rechtwinkliges_Dreieck-Pythagoras.svg) | ||
|
||
![Tree at the lake](https://upload.wikimedia.org/wikipedia/commons/c/c1/Regnitz-Baum-1012073.jpg) | ||
|
||
![Petri net](https://upload.wikimedia.org/wikipedia/commons/0/08/PetriNetzVentil.png) | ||
|
||
## The formula | ||
|
||
```math | ||
a^2 + b^2 = c^2 | ||
``` | ||
|
||
see [chapter 4](chapter04.md#assignment) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# Example video (test) | ||
|
||
a) Placeholder with link to Youtube | ||
|
||
[![Entwicklungsumgebung mit Groovy/Git testen](https://img.youtube.com/vi/fbZOii_l7M4/maxresdefault.jpg)](https://youtu.be/fbZOii_l7M4) | ||
|
||
b) AV-Portal player embedded | ||
|
||
<iframe width="560" height="315" scrolling="no" src="//av.tib.eu/player/40456" frameborder="0" allowfullscreen="allowfullscreen"></iframe> | ||
|
||
c) Youtube embedded | ||
|
||
<iframe width="420" height="315" | ||
src="https://www.youtube.com/embed/fbZOii_l7M4" allowfullscreen="allowfullscreen"> | ||
</iframe> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# H5P Test | ||
|
||
<iframe src="https://h5p.org/h5p/embed/617" width="545" height="337" frameborder="0" allowfullscreen="allowfullscreen"></iframe><script src="https://h5p.org/sites/all/modules/h5p/library/js/h5p-resizer.js" charset="UTF-8"></script> | ||
|
||
... | ||
|
||
<iframe src="https://h5p.org/h5p/embed/62954" width="1090" height="480" frameborder="0" allowfullscreen="allowfullscreen"></iframe><script src="https://h5p.org/sites/all/modules/h5p/library/js/h5p-resizer.js" charset="UTF-8"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Application | ||
|
||
* Example | ||
|
||
# Assignment | ||
|
||
* Example assignment with solution |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
output: | ||
- format: asciidoc | ||
- format: epub | ||
- format: html | ||
- format: pdf | ||
generate_landingpage: true | ||
# content_files: # uncomment this to set the order of the documents (default alphabetical) | ||
# - chapter01.md | ||
# - chapter02.md | ||
# - chapter03.md | ||
# - chapter04.md | ||
generate_reuse_note: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
name: "My OER Course" | ||
creator: | ||
- givenName: "Max" | ||
familyName: "Mustermann" | ||
- givenName: "Maxi" | ||
familyName: "Mustermann" | ||
publisher: | ||
givenName: "Max" | ||
familyName: "Mustermann" | ||
keywords: | ||
- "Geometry" | ||
- "Pythagoras" | ||
- "Mathematics" | ||
description: "Draft for a course" | ||
inLanguage: "en" | ||
version: 1.0 | ||
license: "https://creativecommons.org/publicdomain/zero/1.0/" | ||
thumbnailUrl: http://placehold.it/100x100 | ||
learningResourceType: "Course" | ||
creativeWorkStatus: "Draft" # Incomplete, Draft, Published |