Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/felko/neuron-mode

An emacs mode for editing Zettelkasten notes with neuron
https://github.com/felko/neuron-mode

emacs emacs-lisp emacs-mode markdown zettelkasten

Last synced: about 2 months ago
JSON representation

An emacs mode for editing Zettelkasten notes with neuron

Awesome Lists containing this project

README

        

[![MELPA](https://melpa.org/packages/neuron-mode-badge.svg)](https://melpa.org/#/neuron-mode)

# neuron-mode

neuron-mode is an Emacs major mode derived from
[markdown-mode](https://jblevins.org/projects/markdown-mode/) to edit notes
using the [neuron](https://neuron.zettel.page/) Zettelkasten manager.

drawingneuron-mode demo in doom emacs

## Installation

1. Install [neuron](https://neuron.zettel.page/2011501.html) and make sure that
the `neuron` command is in your path.

2. Install neuron-mode, either via MELPA (recommended) or manually by cloning
this repository.

If you are using an emacs distribution like doom emacs or spacemacs, refer to
[this paragraph](#appendix-integration-to-emacs-distributions) to see how
neuron-mode can be integrated into your configuration.

## Features

All commands are executed in the active zettelkasten which is either detected by
traversing the directory hierarchy upwards until a `neuron.dhall` file is met
(see [neuron configuration](https://neuron.zettel.page/2011701.html)), or
otherwise it uses the zettelkasten that is specified by
`neuron-default-zettelkasten-directory` (a path). Although `neuron.dhall` files
are not mandatory to use neuron itself, this is what enables neuron-mode
automatically when opening a markdown file. neuron-mode will then cache the
zettels and regenerate it when needed (typically when creating a new zettel).
Sometimes, when the zettelkasten is modified externally to neuron-mode, you
might need to invalidate the cache and rebuild it manually, which is done with
the `neuron-refresh` command. This will also reload the titles displayed next to
zettel links (see next paragraph).

#### Reading

neuron-mode allows you to browse your zettelkasten directly from Emacs. Most
importantly, neuron links are shown together with their titles so that you don't
need to read the zettel from the associated HTML file anymore.

#### Navigating

neuron links can also be followed using `neuron-follow-thing-at-point`. For
queries, it will prompt you to select a zettel that match the query under the
point.

Navigating "upwards" is also possible, using the `neuron-edit-uplink` function.

#### Searching

The `neuron-edit-zettel` will prompt you with the list of zettels, where you can
search by title, by tag or by ID using ivy.

projectile can also be useful as a complement to neuron-mode since it allows you
to search the zettelkasten by content.

#### Editing

You can create new zettels from Emacs, neuron-mode will take care of creating
the file with a generated hash in the current active zettelkasten.

Links can be inserted using `neuron-insert-zettel-link` which will prompt you to
select an existing zettel in the active zettelkasten. Zettels can also be linked
and created on the fly by using `neuron-insert-new-zettel`. A third way to
insert links, assuming that you use company, is by typing `

(include those files in `.doom.d/modules/tools/neuron`)

This creates a private module that can then be enabled by inserting `neuron`
under the `:tools` section of your `doom!` block (inside your `init.el`).

### Spacemacs integration

A spacemacs layer for neuron-mode along with installation instructions can be
found in the
[LightAndLight/spacemacs-neuron](https://github.com/LightAndLight/spacemacs-neuron)
repository.