├── .gitattributes ├── .github └── workflows │ └── publish.yaml ├── .gitignore ├── .neuronignore ├── .vscode ├── extensions.json └── settings.json ├── README.md ├── faq.md ├── index.md ├── neuron.dhall └── static └── README.md /.gitattributes: -------------------------------------------------------------------------------- 1 | *.md linguist-detectable 2 | *.md linguist-language=Markdown 3 | *.md linguist-documentation=false 4 | *.md text 5 | -------------------------------------------------------------------------------- /.github/workflows/publish.yaml: -------------------------------------------------------------------------------- 1 | name: "Publish" 2 | on: 3 | # Run only when pushing to master branch 4 | push: 5 | branches: 6 | - master 7 | jobs: 8 | neuron: 9 | runs-on: ubuntu-latest 10 | steps: 11 | - uses: actions/checkout@v2 12 | - name: Build neuron site 🔧 13 | run: | 14 | mkdir -p .neuron/output && touch .neuron/output/.nojekyll 15 | docker run -v $PWD:/notes sridca/neuron neuron gen --pretty-urls 16 | - name: Deploy to gh-pages 🚀 17 | uses: peaceiris/actions-gh-pages@v3 18 | with: 19 | github_token: ${{ secrets.GITHUB_TOKEN }} 20 | publish_dir: .neuron/output/ 21 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .neuron 2 | -------------------------------------------------------------------------------- /.neuronignore: -------------------------------------------------------------------------------- 1 | .*/** 2 | static/README.md 3 | -------------------------------------------------------------------------------- /.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | // See https://go.microsoft.com/fwlink/?LinkId=827846 3 | // for the documentation about the extensions.json format 4 | "recommendations": [ 5 | // Main markdown support 6 | "yzhang.markdown-all-in-one", 7 | 8 | // Zettelkasten wiki-links, backlinks, etc. 9 | "svsool.markdown-memo", 10 | 11 | // Graph view 12 | // Disabled until https://github.com/tchayen/markdown-links/issues/28 is done 13 | // "tchayen.markdown-links", 14 | 15 | // For expanding title in daily note 16 | "gruntfuggly.auto-snippet", 17 | 18 | // Commands for bold, italic, etc. 19 | "mdickin.markdown-shortcuts", 20 | 21 | // Goodies: 22 | // - Checkboxes 23 | "bierner.markdown-checkbox", 24 | // - Footnote 25 | "houkanshan.vscode-markdown-footnote" 26 | ] 27 | } 28 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | // Avoid having to explicitly save notes 3 | "files.autoSave": "afterDelay", 4 | 5 | // Minimap is not useful for Markdown notes 6 | "editor.minimap.enabled": false, 7 | 8 | // Generally note files are not opened in duplicate tabs. 9 | // This also enables you to navigate to already open note in other split pane 10 | "workbench.editor.revealIfOpen": true, 11 | 12 | // For those that use daily notes, via vscode-memo extension 13 | "autoSnippet.snippets": [ 14 | { 15 | "pattern": "**/\\d{4}-\\d{2}-\\d{2}.md", 16 | "snippet": "daily" 17 | } 18 | ] 19 | 20 | // If use Git, these might be interesting: 21 | // "git.autofetch": true, 22 | // "git.postCommitCommand": "push" 23 | } 24 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # How to publish your own [neuron] site 2 | 3 | --- 4 | 5 | **NOTE**: Neuron is superceded by Emanote; See also: https://github.com/srid/emanote-template 6 | 7 | --- 8 | 9 | [neuron] is a note-taking app optimized for publishing. Use this template repository to get started with [publishing](https://neuron.zettel.page/778816d3.html) your own neuron site that looks like [one of these][examples]. 10 | 11 | - Login to GitHub and go to 12 | - Give your new repository a name, say `mynotes` 13 | - Select "*Include all branches*" ([might be necessary to get the site to publish](https://stackoverflow.com/a/47368231/55246)) 14 | - Click "Create repository from template" 15 | - Note: if you are on the free GitHub plan, your repository should be public for GitHub to publish it. 16 | 17 | GitHub will now build the site and serve it at: `https://.github.io/mynotes/`. 18 | 19 | For more information, see [neuron documentation][neuron] as well as the [GitHub Pages guide](https://help.github.com/en/github/working-with-github-pages). 20 | 21 | ## Set your site metadata 22 | 23 | - In your new repository, edit the `neuron.dhall` file to set your site configuration (such as title, author, color theme) to suitable values. 24 | 25 | ## How to edit and add notes 26 | 27 | Assuming you have changed the `editUrl` configuration in `neuron.dhall` (see the above section), you can simply click the "edit" icon on the published site to edit any note (see [Editing files in your repository](https://help.github.com/en/github/managing-files-in-a-repository/editing-files-in-your-repository) and [Creating new files](https://help.github.com/en/github/managing-files-in-a-repository/creating-new-files)). On every change, your site should eventually rebuild. 28 | 29 | To understand how linking works, read [the neuron guide on Linking][linking]. 30 | 31 | For other ways to edit your notes (editors, web interface), see the [neuron guide][create]. In particular, [Cerveau](https://www.cerveau.app/) is the easiest way to edit your notes on the go. 32 | 33 | Got questions? Checkout the [[faq]]. To find who else is using this template *publicly on GitHub*, [see here](https://github.com/search?o=desc&q=filename%3Aneuron.dhall&s=indexed&type=Code). 34 | 35 | [neuron]: https://neuron.zettel.page 36 | [examples]: https://neuron.zettel.page/examples 37 | [linking]: https://neuron.zettel.page/linking 38 | [create]: https://neuron.zettel.page/create 39 | 40 | -------------------------------------------------------------------------------- /faq.md: -------------------------------------------------------------------------------- 1 | --- 2 | tags: [other] 3 | --- 4 | 5 | # FAQ 6 | 7 | How long does it take for the site to update? 8 | : The [GitHub Actions](https://github.com/features/actions) build itself takes about ~15 seconds to run. It is generally expected for your site to update around that duration, and take no more than a minute. 9 | 10 | Which environment is used to build and deploy the site? 11 | : From the [Actions workflow file](https://github.com/srid/neuron-template/blob/master/.github/workflows/publish.yaml), it can be seen that we use the [official neuron docker image](https://neuron.zettel.page/docker.html), as well as use the [peaceiris/actions-gh-pages](https://github.com/peaceiris/actions-gh-pages) action to push the built site to the `gh-pages` branch, that in turn gets deployed to GitHub's servers. 12 | 13 | How can I use the stable version of neuron? 14 | : The Actions workflow file `publish.yml` is configured to pull the *latest* docker image; you can adjust it to pull from a (unchanging) tag instead. [See here][docker-tags] for a list of available tags which correspond to neuron versions; generally you would pick the latest tag and put it in `publish.yml`. Then, your site will continue use the same neuron version, regardless of upstream development changes. 15 | 16 | Can I use my own domain name? 17 | : Yes, you can [set the CNAME in publish.yaml][cname]. 18 | 19 | How can private repositories be published? 20 | : You will need a GitHub paid plan to publish private repositories. Public repositories on the other hand can be published in the GitHub free plan. 21 | 22 | [cname]: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-add-cname-file-cname 23 | [docker-tags]: https://hub.docker.com/r/sridca/neuron/tags?page=1&ordering=last_updated 24 | -------------------------------------------------------------------------------- /index.md: -------------------------------------------------------------------------------- 1 | # Neuron Template 2 | 3 | You are viewing a template site, generated from [neuron-template](https://github.com/srid/neuron-template) and published by [neuron](https://neuron.zettel.page/). [GitHub Pages](https://pages.github.com/) is used to automatically publish this site every time the underlying Git repository gets updated. 4 | 5 | Get started by reading [[README]]#. 6 | 7 | Other pages on this zettelkasten: 8 | 9 | - [[faq]]# 10 | -------------------------------------------------------------------------------- /neuron.dhall: -------------------------------------------------------------------------------- 1 | -- Documentation for neuron.dhall: https://neuron.zettel.page/configuration 2 | { siteTitle = "Neuron Template" 3 | , author = Some "John Doe" 4 | , siteBaseUrl = Some "https://srid.github.io/neuron-template/" 5 | -- List of color names: https://semantic-ui.com/usage/theming.html#sitewide-defaults 6 | , theme = "teal" 7 | -- This is used in the "edit" button 8 | , editUrl = Some "https://github.com/srid/neuron-template/edit/master/" 9 | } 10 | -------------------------------------------------------------------------------- /static/README.md: -------------------------------------------------------------------------------- 1 | Put your [static files](https://neuron.zettel.page/static-files) (images, pdf, etc.) here. They'll be copied as-is. 2 | --------------------------------------------------------------------------------