-
Notifications
You must be signed in to change notification settings - Fork 7
Revamp README #53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
+80
−46
Merged
Revamp README #53
Changes from 4 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
08639e6
Revamp README
danielballan 0a1958b
whitespace
danielballan 2a19c4c
Refine text
danielballan c4c6f99
How do I use it?
danielballan ff7a8a4
Better wording
danielballan 999d19e
Avoid 'click here' vibes
danielballan a27ec77
Be specific
danielballan d3734c7
Minor edits
danielballan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
---|---|---|
@@ -1,43 +1,62 @@ | ||
# Executable Tutorials | ||
|
||
A repository demonstrating one way to manage and distribute interactive tutorials. | ||
See the [Guide to Contributing](https://scentific-python.org/executable-tutorials/contributing.html) | ||
for a good overview of what this is like to use. | ||
## Use Cases | ||
|
||
## Demo Links | ||
Many organizations maintain collections of tutorials addressing realistic | ||
problems in a science domain, with runnable code examples written and | ||
kept current by experts in the tools. They are useful as: | ||
|
||
- **[Tutorials](https://github.com/scientific-python/executable-tutorials/tree/main/tutorials)** are written in MyST Markdown. | ||
- Tutorials can be easily edited as notebooks in JupyterLab. | ||
- Executed tutorials are **[published](https://scientific-python.github.io/exeuctable-tutorials/)** on a GitHub Pages site. | ||
- **[Jupyter Lite (beta)](https://scientific-python.github.io/executable-tutorials/jupyterlite/lab/index.html)** (works only on the basic executable example so far, missing dependencies for others) | ||
- **[Binder](https://mybinder.org/v2/gh/scientific-python/executable-tutorials/notebooks)** | ||
- A trove of working snippets to copy and paste | ||
- A maintained resource for self-guided learning | ||
- A ready-to-use curriculum for interactive workshops | ||
- A suite of science domain-specific "integration tests" | ||
danielballan marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
### Notes on the notebook file format | ||
## Key Features | ||
|
||
We do use MyST Markdown format for the notebooks, please visit [the upstream documentation](https://mystmd.org/guide/md-vs-ipynb) to learn more about the reasoning behind the choice. | ||
However, we add it here that you can easily have the same user experience in JupyterLab if these two dependencies are installed: | ||
- [jupytext library](https://pypi.org/project/jupytext/) | ||
- [jupyterlab-myst JupyterLab extension](https://pypi.org/project/jupyterlab-myst/) | ||
This repository demonstrates one way to configure a collection of tutorials, | ||
covering some core features: | ||
|
||
- Source is in [MyST Markdown][] which is easy for humans to edit and review. | ||
danielballan marked this conversation as resolved.
Show resolved
Hide resolved
|
||
- The executed examples---code and results---are published as a static site. | ||
([example][static site example]) | ||
danielballan marked this conversation as resolved.
Show resolved
Hide resolved
|
||
- The examples can be opened as Jupyter notebooks to run and edit: | ||
- In a user's local environment | ||
- On a Binder ([example][binder example]) | ||
- (Experimental) In the user's browser via Jupyter Lite ([example][jupyterlite example]) | ||
- The examples can be tested using `pytest`, both locally and on CI. | ||
|
||
## Goals | ||
## Try It Out | ||
|
||
- Make content easy to explore and try in a variety of modes: | ||
- interactive and non-interactive | ||
- local and cloud-based | ||
- Jupyter and not-Jupyter | ||
- Document an accessible development workflow, so that non-experts can contribute. | ||
- Keep the infrastructure as simple as possible. | ||
- Read the [published examples][static site example]. | ||
|
||
## To Do | ||
- Open it on [Binder][binder example] to run the examples in the cloud. | ||
|
||
- Test execution _of changed tutorials only_ in CI on PR. | ||
- Set up devcontainer. | ||
- Add example with additional dependencies. | ||
- Download and run the examples locally. | ||
|
||
## Prior Art | ||
```sh | ||
git clone https://github.com/scientific-python/executable-tutorials | ||
``` | ||
|
||
Examples that this is drawing from: | ||
For users of [pixi][]: | ||
|
||
- https://github.com/Caltech-IPAC/irsa-tutorials | ||
- https://github.com/MotherDuck-Open-Source/sql-tutorial | ||
```sh | ||
pixi run start | ||
``` | ||
|
||
Alternatively, install the requirements with pip and start JupyterLab. | ||
|
||
```sh | ||
pip install -r requirements.txt | ||
jupyter lab | ||
``` | ||
|
||
## Make Your Own | ||
|
||
See the [Guide for Maintainers][] to create your own collection of tutorials. | ||
|
||
[Myst Markdown]: https://mystmd.org/guide/typography | ||
[static site example]: https://scientific-python.github.io/exeuctable-tutorials/ | ||
[binder example]: https://mybinder.org/v2/gh/scientific-python/executable-tutorials/main | ||
[jupyterlite example]: https://scientific-python.github.io/executable-tutorials/jupyterlite/lab/index.html | ||
[pixi]: https://pixi.sh/ | ||
[Guide for Maintainers]: https://scientific-python.github.io/executable-tutorials/maintainer-guide.html |
This file contains hidden or 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 |
---|---|---|
|
@@ -24,5 +24,5 @@ caption: Contributing | |
--- | ||
|
||
contributing | ||
maintainers | ||
maintainer-guide | ||
``` |
This file contains hidden or 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 @@ | ||
# Guide for Maintainers | ||
|
||
This guide for configuring and maintaining collection of executable | ||
tutorials. | ||
|
||
## Notes on the notebook file format | ||
|
||
We do use MyST Markdown format for the notebooks, please visit | ||
[the upstream documentation](https://mystmd.org/guide/md-vs-ipynb) | ||
to learn more about the reasoning behind the choice. To provide a seamless | ||
user experience for users in JupyterLab, we employ some libraries [^1] and a | ||
little special configuration [^2]. | ||
|
||
## Specialized Patterns | ||
|
||
Sometimes it is convenient to disable a job in a GitHub Action on certain Pull | ||
Requests. This may be added to the job to configure it to skip Pull Requests | ||
that have a given label called `LABEL`. | ||
|
||
```yaml | ||
jobs: | ||
tests: | ||
if: ${{ !(github.event_name == 'pull_request') || !contains(github.event.pull_request.labels.*.name, 'LABEL') }} | ||
``` | ||
|
||
[^1]: [jupytext][] and the [jupyterlab-myst JupyterLab extension][] | ||
|
||
[^2]: See `.binder/postBuild` and `.binder/overrides.json`. | ||
|
||
[jupytext]: https://pypi.org/project/jupytext/ | ||
[jupyterlab-myst JupyterLab extension]: https://pypi.org/project/jupyterlab-myst/ |
This file was deleted.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.