Skip to content

Commit

Permalink
Merge pull request #3 from kabilar/main
Browse files Browse the repository at this point in the history
Create documentation framework
  • Loading branch information
kabilar authored Jun 6, 2024
2 parents 3a086c2 + 08db8a7 commit e535912
Show file tree
Hide file tree
Showing 16 changed files with 205 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .codespellrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[codespell]
skip = .git,*.pdf,*.svg,venvs,venv,site
ignore-words-list = Weill
22 changes: 22 additions & 0 deletions .github/workflows/build-docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Build MkDocs
on:
push:
pull_request:

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v1

- name: Install version of Python
uses: actions/setup-python@v5
with:
python-version: '3.11'

- name: Install requirements
run: pip install -r requirements.txt

- name: Build docs
run: mkdocs build
22 changes: 22 additions & 0 deletions .github/workflows/codespell.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
name: Codespell

on:
push:
branches: [main]
pull_request:
branches: [main]

permissions:
contents: read

jobs:
codespell:
name: Check for spelling errors
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v3
- name: Codespell
uses: codespell-project/actions-codespell@v2
18 changes: 18 additions & 0 deletions .github/workflows/publishdocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Publish docs via GitHub Pages
on:
push:
branches:
- main

jobs:
build:
name: Deploy docs
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v1

- name: Deploy docs
uses: mhausenblas/mkdocs-deploy-gh-pages@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.DS_Store
.idea/
activities/.DS_Store
protocols/.DS_Store
node_modules
local_data

site/
18 changes: 18 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- repo: https://github.com/psf/black
rev: 19.3b0
hooks:
- id: black
- repo: https://github.com/codespell-project/codespell
rev: v2.2.5
hooks:
- id: codespell
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
# linc-docs
[Uploading data to lincbrain.org](upload.md)
# LINC Documentation

Docs for the LINC project which can be found at lincbrain.org/docs
12 changes: 12 additions & 0 deletions docs/about.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# About this doc

## Acknowledgements

Thank you to the DANDI Archive project for setting up the documentation framework that is utilized here. See the [DANDI Handbook](https://www.dandiarchive.org/handbook/) for more information.

## License

<a rel="license" href="http://creativecommons.org/licenses/by/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by/4.0/88x31.png" /></a>

This work is licensed under a [Creative Commons Attribution 4.0 International License](http://creativecommons.org/licenses/by/4.0/).

11 changes: 11 additions & 0 deletions docs/contribute.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Contribute to this documentation

If you find an issue with this documentation please file an issue or submit a pull request on the [linc-docs repository](https://github.com/lincbrain/linc-docs).

If you would like to contribute to the LINC documentation and render the documentation locally as you make edits, please follow the steps below:

1. Fork the [linc-docs repository](https://github.com/lincbrain/linc-docs) and clone it to your computer.
2. Set up a Python environment with the dependencies in the [requirements.txt file](https://github.com/lincbrain/linc-docs/blob/main/requirements.txt).
3. Within the Python environment, run `mkdocs serve`. This will build the website and start a local webserver (e.g. at http://127.0.0.1:8000) with your documentation.
4. As you continue to edit the markdown files or configuration file, your documentation will be automatically re-built and rendered locally.
5. Commit your changes and submit a pull request.
Binary file added docs/img/linc.logo.color+black.alpha.notext.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/img/linc.logo.color+white.notext+square.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/img/linc.logo.color+white.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
32 changes: 32 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Welcome to the LINC Documentation

<img
src="./img/linc.logo.color+white.png"
alt="linc_banner"
style="width: 75%; height: auto; display: block; margin-left: auto; margin-right: auto;"/>

The center for [Large-scale Imaging of Neural Circuits (LINC)](https://connects.mgh.harvard.edu/)
(PIs: Haber, Hillman, Yendiki) is funded by the
[NIH BRAIN Initiative CONNECTS program](https://www.ninds.nih.gov/news-events/highlights-announcements/nih-brain-initiative-launches-projects-develop-innovative-technologies-map-brain-incredible-detail).
Its goal is to develop novel technologies for imaging brain connections down to
the microscopic scale, and deploy these technologies to image
cortico-subcortical projections that are relevant to deep brain stimulation for
motor and psychiatric disorders.

## About this doc

The LINC documentation is meant to share information across the LINC project investigators. If you are new to the LINC project, you can start on the [Upload data](upload.md) page for a description of how to interact with the LINC data sharing platform.

## Quick Links

- [LINC Homepage](https://connects.mgh.harvard.edu/)
- [LINC Data Sharing Platform](https://lincbrain.org/)
- [LINC Project Code on GitHub](https://github.com/lincbrain)

## Support

For questions, bug reports, and feature requests, please:

- File an issue on the relevant [GitHub repository](https://github.com/lincbrain)
- Reach out on the [LINC Slack](https://mit-lincbrain.slack.com/)
- Send an email to kabi@mit.edu
File renamed without changes.
53 changes: 53 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
site_name: LINC Documentation
repo_name: "lincbrain/linc-docs"
repo_url: "https://github.com/lincbrain/linc-docs"
copyright: "CC-BY 4.0"
use_directory_urls: true
site_url: https://www.lincbrain.org/docs/

# Material theme
theme:
name: "material"
language: "en"
favicon: img/linc.logo.color+white.notext+square.png
logo: img/linc.logo.color+black.alpha.notext.png
palette:
primary: "deep purple"
accent: "purple"
features:
- toc.integrate

# Pages
nav:
- Welcome: "index.md"
- Upload data: "upload.md"
- Contribute documentation: "contribute.md"
- About this doc: "about.md"

# List of extensions
markdown_extensions:
- admonition
- pymdownx.details
- pymdownx.critic
- pymdownx.magiclink
- toc:
permalink: True

# List of plugins
plugins:
- search
- open-in-new-tab

# Customize theme
extra:
generator: false
social:
- icon: material/home
link: https://connects.mgh.harvard.edu/
name: Homepage
- icon: fontawesome/brands/slack
link: https://mit-lincbrain.slack.com/
name: Slack
- icon: fontawesome/brands/github
link: https://github.com/lincbrain
name: GitHub
3 changes: 3 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
mkdocs-material>=9.5.10
pymdown-extensions
mkdocs-open-in-new-tab

0 comments on commit e535912

Please sign in to comment.