notebooks for collaborative tools session
parent
281309b7ef
commit
a6bc48017e
@ -0,0 +1,123 @@
|
||||
{
|
||||
"cells": [
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"# Oh my Git!\n",
|
||||
"\n",
|
||||
"![](https://post.lurk.org/system/cache/media_attachments/files/107/763/566/139/941/382/original/a9f23a7691b7845e.png)\n",
|
||||
"\n",
|
||||
"XPUB's Git: https://git.xpub.nl/\n",
|
||||
"\n",
|
||||
"Git introduction tutorial: https://rogerdudler.github.io/git-guide/\n",
|
||||
"\n",
|
||||
"Visual cheat sheet: https://ndpsoftware.com/git-cheatsheet.html"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Most commonly used git commands\n",
|
||||
"\n",
|
||||
"`git pull`\n",
|
||||
"\n",
|
||||
"`git status`\n",
|
||||
"\n",
|
||||
"`git log`\n",
|
||||
"\n",
|
||||
"`git add filename.txt`\n",
|
||||
"\n",
|
||||
"`git commit -m \"my short summary of what has changed\"`\n",
|
||||
"\n",
|
||||
"`git push`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Clone, branch, merge & forking\n",
|
||||
"\n",
|
||||
"`git clone https://git.xpub.nl/username/repository_name`\n",
|
||||
"\n",
|
||||
"`git checkout`\n",
|
||||
"\n",
|
||||
"`git merge`\n"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Oh my Git, let's do it \n",
|
||||
"\n",
|
||||
"We will make a Git repository together, that includes:\n",
|
||||
"\n",
|
||||
"* `playcard.html`: the most epic playcard ever\n",
|
||||
"* `playcard.css`: CSS rules to style the playcard\n",
|
||||
"* `playcard.ipynb`: notebook in which we generate a PDF based on the HTML + CSS files\n",
|
||||
"* `.gitignore`: a gitignore file that includes the notebook: we do not want to push changes in the notebook back to git\n",
|
||||
"* `README.md`: a README file written in markdown"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Possible way how Git's features can be used?\n",
|
||||
"\n",
|
||||
"* How to write a narrative story in git... ? Like imagine mapping the idea of parallel branches to a world with parallel realities \n",
|
||||
"\n",
|
||||
"\n",
|
||||
"![](https://i.redd.it/3nypv8br5f301.jpg)\n",
|
||||
"\n",
|
||||
"https://i.redd.it/3nypv8br5f301.jpg"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"# Diving further into Git: *Oh shit Git!*\n",
|
||||
"\n",
|
||||
"<img src=\"https://wizardzines.com/zines/oh-shit-git/cover_hu820f401f4c3f84d12801fd52a338b934_1141571_800x0_resize_q75_box.jpg\" width=\"300px\">\n",
|
||||
"\n",
|
||||
"https://ohshitgit.com/\n",
|
||||
"\n",
|
||||
"https://wizardzines.com/zines/oh-shit-git/\n",
|
||||
"\n",
|
||||
"https://hub.xpub.nl/bootleglibrary/read/741/pdf"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": []
|
||||
}
|
||||
],
|
||||
"metadata": {
|
||||
"kernelspec": {
|
||||
"display_name": "Python 3",
|
||||
"language": "python",
|
||||
"name": "python3"
|
||||
},
|
||||
"language_info": {
|
||||
"codemirror_mode": {
|
||||
"name": "ipython",
|
||||
"version": 3
|
||||
},
|
||||
"file_extension": ".py",
|
||||
"mimetype": "text/x-python",
|
||||
"name": "python",
|
||||
"nbconvert_exporter": "python",
|
||||
"pygments_lexer": "ipython3",
|
||||
"version": "3.7.3"
|
||||
}
|
||||
},
|
||||
"nbformat": 4,
|
||||
"nbformat_minor": 4
|
||||
}
|
@ -0,0 +1,96 @@
|
||||
{
|
||||
"cells": [
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"# Collective playcard generating time!"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Git cheatsheet\n",
|
||||
"\n",
|
||||
"`git pull`\n",
|
||||
"\n",
|
||||
"`git status`\n",
|
||||
"\n",
|
||||
"`git log`\n",
|
||||
"\n",
|
||||
"`git add filename.txt`\n",
|
||||
"\n",
|
||||
"`git commit -m \"my short summary of what has changed\"`\n",
|
||||
"\n",
|
||||
"`git push`"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Generate playcard.pdf"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 8,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"from weasyprint import HTML, CSS\n",
|
||||
"\n",
|
||||
"HTML(filename='playcard.html').write_pdf('playcard.pdf', stylesheets=[CSS(filename='playcard.css')])"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## Weasyprint links\n",
|
||||
"\n",
|
||||
"https://doc.courtbouillon.org/weasyprint/stable/\n",
|
||||
"\n",
|
||||
"https://weasyprint.org/"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"## CSS links\n",
|
||||
"\n",
|
||||
"https://pzwiki.wdka.nl/mediadesign/Paged_Media_CSS_examples"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": []
|
||||
}
|
||||
],
|
||||
"metadata": {
|
||||
"kernelspec": {
|
||||
"display_name": "Python 3",
|
||||
"language": "python",
|
||||
"name": "python3"
|
||||
},
|
||||
"language_info": {
|
||||
"codemirror_mode": {
|
||||
"name": "ipython",
|
||||
"version": 3
|
||||
},
|
||||
"file_extension": ".py",
|
||||
"mimetype": "text/x-python",
|
||||
"name": "python",
|
||||
"nbconvert_exporter": "python",
|
||||
"pygments_lexer": "ipython3",
|
||||
"version": "3.7.3"
|
||||
}
|
||||
},
|
||||
"nbformat": 4,
|
||||
"nbformat_minor": 4
|
||||
}
|
Loading…
Reference in New Issue