Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 21 additions & 7 deletions 10_manage_python_project.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
"metadata": {},
"source": [
"# Table of Contents\n",
" - [Manage Python project](#Manage-Python-project)\n",
" - [References](#References)\n",
" - [Introduction](#Introduction)\n",
" - [Preparatory exercise](#Preparatory-exercise)\n",
Expand All @@ -41,7 +40,7 @@
" - [Exercise on testing](#Exercise-on-testing)\n",
" - [Documentation](#Documentation)\n",
" - [Why document?](#Why-document?)\n",
" - [How document?](#How-document?)\n",
" - [How to document?](#How-to-document?)\n",
" - [Comments](#Comments)\n",
" - [Docstrings](#Docstrings)\n",
" - [Type hints](#Type-hints)\n",
Expand Down Expand Up @@ -137,10 +136,25 @@
"1. Decide which package you want to use for the following exercises, yours or the [mypackage](https://github.com/empa-scientific-it/mypackage).\n",
"1. If you use the `mypackage` fork it to your own GitHub account by clicking on the `Fork` button in the top right corner.\n",
"1. Clone the fork to your local machine: `git clone <url-to-your-repository>`.\n",
" The URL can be found by clicking on the `<Code>` dropdown and selecting __HTTPS__ tab.\n",
"1. [Create an access token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#creating-a-personal-access-token-classic) for your account that will be used instead of your password.\n",
" You should enable `workflow`, `write:packages`, `delete:packages`.\n",
" Make sure to store the token in some secure location.\n",
" The URL can be found by clicking on the `<Code>` dropdown and selecting the __SSH__ tab.\n",
Comment thread
yakutovicha marked this conversation as resolved.
"\n",
"<details>\n",
"<summary>How to set up SSH keys (click to expand)</summary>\n",
"\n",
"1. Open the Terminal and generate an SSH key pair:\n",
Comment thread
yakutovicha marked this conversation as resolved.
Outdated
" ```bash\n",
" ssh-keygen -t rsa\n",
" ```\n",
" Hit `Enter` three times to accept the default values.\n",
"\n",
"2. In the File Browser, enter the `.ssh` folder and open the file named `id_rsa.pub`. Copy its content.\n",
Comment thread
yakutovicha marked this conversation as resolved.
Outdated
"\n",
"3. Go to [github.com](https://github.com), click on your icon (top right corner) and select `Settings`.\n",
" In the newly opened window, select \"SSH and GPG keys\" and click on \"New SSH key\".\n",
" Provide a key title (e.g. `python-intro-tutorial`) and paste the key content in the \"Key\" field.\n",
" Click on \"Add SSH key\".\n",
"\n",
"</details>\n",
"\n",
"<div class=\"alert alert-block alert-info\">\n",
"In the following, we will always assume that <code>mypackage</code> is the package you are working on (either yours or the one you have forked).\n",
Expand Down Expand Up @@ -726,7 +740,7 @@
"id": "28",
"metadata": {},
"source": [
"## How document?\n",
"## How to document?\n",
"\n",
"Usually, the documentation of a package is written in [reStructuredText](https://www.sphinx-doc.org/en/master/usage/restructuredtext/index.html) or [Markdown](https://www.sphinx-doc.org/en/master/usage/markdown.html).\n",
"However, it is also possible to write the documentation in [Jupyter notebooks](https://jupyter.org/) (as we do in this tutorial).\n",
Expand Down