-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* reorganise programming section * restructure data analysis section * added sphinx-design to requirements * Rewrote homepage * udpated repo readme * updated contributing guide * added warning about guide names starting with How To * hide TOC on homepage * removed coming soon section * reduced TOC depth in the main sections * hide the show source button
- Loading branch information
Showing
17 changed files
with
99 additions
and
78 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 |
---|---|---|
@@ -1,36 +1,41 @@ | ||
# How to contribute to this website | ||
|
||
## Website structure | ||
|
||
The website is structured in three high-level sections, represented by folders in the `docs/source` directory: | ||
- Data Analysis | ||
- Programming | ||
- Guides | ||
- Open Science | ||
|
||
Each section is further divided into sub-sections, each corresponding to a different markdown file in `docs/source/{section}` directory. There are also `docs/source/{section}/index.md` files, which are used to create the tables of contents for each section. | ||
Each section directory (`docs/source/<section>`) may contain several markdown files, with each file corresponding to a specific long-form guide. There are also `docs/source/<section>/index.md` files, which are used to create the tables of contents for each section. | ||
|
||
## Adding new content | ||
## Adding a long-form guide | ||
To add a new guide, create a new markdown file in the appropriate section directory, and make sure to start it with a level-1 heading. Remember to also add the new file to the table of contents in the corresponding`docs/source/<section>/index.md` file. | ||
|
||
To add a new sub-section, create a new markdown file in the appropriate section directory, and make sure to start it with a level-1 heading. Remember to also add the new file to the table of contents in the corresponding`docs/source/{section}/index.md` file. | ||
## Adding a small tip | ||
If the content you want to add is not long enough to warrant a full guide, for example a small tip or a quick solution to a common problem, you can add it to a `Troubleshooting.md` file in the appropriate section directory. For an example see `docs/source/programming/Troubleshooting.md`. Each small tip should start with a level-2 heading. | ||
|
||
To add entries to an existing sub-section, simply add new level-2/3 headings to the right markdown file, as appropriate. | ||
> **warning** | ||
> | ||
> Since the website is already named "HowTo", please avoid starting your guides/tips with "How to ...". | ||
> For example, instead of "How to detach a forked repo on GitHub", use "Detach a forked repo on GitHub". | ||
## GitHub workflow | ||
* Clone the GitHub repository, and create your `new_branch`. | ||
* Edit the website and commit your changes to the `new_branch`. | ||
* Push the `new_branch` to GitHub and create a pull request. This will automatically trigger a [GitHub Action](https://github.com/ammaraskar/sphinx-action) that checks if the website still builds correctly. | ||
* If the checks pass, assign someone to review your changes. | ||
* When the reviewer merges your changes into the `main` branch, a different [GitHub Action](https://github.com/peaceiris/actions-gh-pages) will be triggered, which will build the website and publish it to the `gh-pages` branch. | ||
* Push the `new_branch` to GitHub and create a draft pull request. This will automatically trigger a [GitHub action](https://github.com/neuroinformatics-unit/actions/tree/main/build_sphinx_docs) that checks if the website still builds correctly. | ||
* If the checks pass, mark the pull request as ready to review assign someone to review your changes. | ||
* When the reviewer merges your changes into the `main` branch, a different [GitHub action](https://github.com/neuroinformatics-unit/actions/tree/main/deploy_sphinx_docs) will be triggered, which will build the website and publish it to the `gh-pages` branch. | ||
* The updated website should be available at [howto.neuroinformatics.dev](https://howto.neuroinformatics.dev) | ||
|
||
> **note** | ||
> | ||
> If you wish to view the website locally, before you push it, you can do so by running the following commands from the root of the repository. | ||
> ```bash | ||
> # First time only | ||
> pip install -r docs/requirements.txt | ||
> sphinx-build docs/source docs/build | ||
> | ||
> # Every time you want to build the website | ||
> # Every time you want to update the local build | ||
> rm -rf docs/build && sphinx-build docs/source docs/build | ||
>``` | ||
>You can view the local build at `docs/build/index.html` |
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 |
---|---|---|
@@ -1,7 +1,12 @@ | ||
# Neuroinformatics Unit HowTo | ||
|
||
[![Website shields.io](https://img.shields.io/website-up-down-green-red/https/howto.neuroinformatics.dev.svg)](https://howto.neuroinformatics.dev) | ||
[![made-with-sphinx-doc](https://img.shields.io/badge/Made%20with-Sphinx-1f425f.svg)](https://www.sphinx-doc.org/) | ||
|
||
Source code for the [Neuroinformatics Unit HowTo](https://howto.neuroinformatics.dev/) website. | ||
|
||
On this website, we keep track of solutions to common issues arising when using software tools for neuroscience research (whether made by the Neuroinformatics Unit or not). The information is primarily aimed at researchers at the [Sainsbury Wellcome Centre (SWC)](https://www.sainsburywellcome.org/web/) and [Gatsby Computational Neuroscience Unit (GCNU)](https://www.ucl.ac.uk/gatsby/gatsby-computational-neuroscience-unit), though most of it should be useful to neuroscientists in general. | ||
On this website, we keep track of long-form how-to guides as well as collections of small tips and tricks related to data analysis and software development in neuroscience. | ||
|
||
The information is primarily aimed at researchers at the [Sainsbury Wellcome Centre (SWC)](https://www.sainsburywellcome.org/web/) and [Gatsby Computational Neuroscience Unit (GCNU)](https://www.ucl.ac.uk/gatsby/gatsby-computational-neuroscience-unit), though most of it should be useful to neuroscientists in general. | ||
|
||
If you wish to edit the website, please read the [contributing guide](CONTRIBUTING.md) first. |
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 |
---|---|---|
|
@@ -3,4 +3,5 @@ pydata-sphinx-theme | |
myst-parser | ||
numpydoc | ||
nbsphinx | ||
linkify-it-py | ||
linkify-it-py | ||
sphinx-design |
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
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,15 +1,10 @@ | ||
# Data Analysis | ||
|
||
Issues relating to data analysis in neuroscience are grouped into sections corresponding to data *modalities*. | ||
Each *modality* is further subdivided into subsections corresponding to specific *tools*. | ||
Guides related to the analysis of neuroscientific data, spanning a wide range of data types such as electrophysiology, behaviour, calcium imaging, histology, etc. The focus may be on the use of specific software tools, or on more general analysis tasks and concepts. | ||
|
||
```{toctree} | ||
:maxdepth: 2 | ||
:maxdepth: 1 | ||
Behaviour | ||
Electrophysiology | ||
Imaging | ||
Histology | ||
``` | ||
|
||
|
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
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
4 changes: 1 addition & 3 deletions
4
docs/source/programming/Python.md → .../source/programming/Cookiecutter-cruft.md
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
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
7 changes: 1 addition & 6 deletions
7
docs/source/programming/IDEs.md → docs/source/programming/SSH-vscode.md
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
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 @@ | ||
# Troubleshooting | ||
Small problems and their solutions. | ||
|
||
## Ubuntu distribution update error | ||
This is an error that appeared when updating to a new Ubuntu distribution. | ||
Error msg: Software Updater - Not all updates can be installed. | ||
Solution: `sudo apt-get dist-upgrade` | ||
|
||
## Terminal is not opening after installing a new Python version | ||
If you installed a new Python version without the use of `conda`, there might be a mismatch in the python naming in a bin file. | ||
If it's possible open terminal through vscode or open a virtual terminal (VT) with CTRL + ALT + F3 and run `gnome-ternimal`. | ||
Does it throw a Python error? If yes run `sudo nano /usr/bin/gnome-terminal` and change `#!/usr/bin/python3` to `#!/usr/bin/python3.10` if the version you're currently using is 3.10. | ||
Exit the VT via CTRL + ALT + F2. | ||
|
||
## Detach a forked repo on GitHub | ||
If you forked a repo and want to detach it from the original repo, use the [Github chatbot-virtual-assistant](https://support.github.com/contact?tags=rr-forks&subject=Detach%20Fork&flow=detach_fork). | ||
Follow the instructions and wait for the response. |
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,12 +1,14 @@ | ||
# Programming | ||
|
||
General programming and software development issues, tips and tricks. | ||
Guides related to general coding and software development issue, such as version control, programming environments, IDEs, Linux, the command line, etc. | ||
|
||
Small tips and tricks that do not warrant a long-form guide can be found in the [Troubleshooting](Troubleshooting.md) section. | ||
|
||
```{toctree} | ||
:maxdepth: 2 | ||
:maxdepth: 1 | ||
Linux | ||
IDEs | ||
VersionControl | ||
Python | ||
SSH-vscode | ||
Mount-ceph-ubuntu | ||
Cookiecutter-cruft | ||
Troubleshooting | ||
``` |