Camouflage HN: Brain, a commandline narrate-taking tool for growing a zettelkasten

Camouflage HN: Brain, a commandline narrate-taking tool for growing a zettelkasten

Meet this rather ingredient!!

Brain is a commandline tool for the organisation of a zettelkasten or as some folks call it: your 2d mind.

2022-02-03-131954

Brain doesn’t consume a standard Luhmann’s Zettelkasten but a a little bit altered model. The differences are:

  • Utilization of timestamp as narrate ID
  • Probability of using assorted forms of notes (would possibly very well be not noted when you happen to rep not desire to make consume of it). Extra info about this defined in Reward forms
    • Topic
    • Quote
    • Journal

Furthermore it uses markdown-formatted notes with YAML-headers for metadata.

Extra info about the zettelkasten map:

Contents

Aspects

Some of important aspects:

  • Vim-admire-keybindings in TUI
  • Automatic backlinking of notes
  • Great search performance
  • Notes are kept as simple Markdown info
  • Your Favorite editor would possibly very well be used for editing notes
  • Minimal (non-bloated) tool

Set up

The binary executable is named brn.

Pre-built binaries

Within the Releases page (on Github) you will accumulate pre-built binaries for every model.

Cargo

To design a binary using cargo lag within the mission root directory (the directory with Cargo.toml internal it) and discontinue:

That you would per chance accumulate the contemporary binary within the course ./target/release/brn.

Commands

Brain would possibly very well be utilized in 2 assorted recommendations:

  • That you would per chance consume it from the commandline using diversified subcommands admire:
    • brn add
    • brn consume away
    • brn checklist
  • That you would per chance consume the TUI mode for a extra interactive journey.
    • brn tui
    • With this that you would per chance per chance pause close to every thing that you would per chance per chance pause with all other subcommands. Exceptions:
      • brn init
      • brn random

For a beefy checklist of on hand commands kind brn support.

Creating a brand contemporary zettelkasten

Construct a brand contemporary directory, where you must design your zettelkasten and navigate into it:

mkdir my-zettelkasten
cd my-zettelkasten

Then discontinue:

The contemporary directory will be diagnosed as a zettelkasten to any extent further.

Adding notes

brn add "A Zettelkasten is astronomical"

Listing created notes

Opening notes

Brain opens notes within the editor specified by the EDITOR ambiance variable. This makes it that that you would per chance per chance take into consideration to make consume of your current editor for editing your notes.

That you would per chance delivery a narrate both within the TUI mode or on the commandline:

TUI mode

The TUI mode makes it more straightforward to traverse thourgh your zettelkasten.

Keybindings in TUI mode

Keys Description
q quit the program
j, UpArrow up
k, DownArrow down
l, LeftArrow delivery narrate
g lag to the pause of the narrate checklist
G lag to the backside of the narrate checklist
h narrate historical previous of ultimate visited notes
r narrate a checklist of random notes
/ enter search mode
ESC narrate checklist of ultimate created notes (default mediate about)
a add contemporary narrate
x consume away within the intervening time selected narrate
y reproduction narrate link to within the intervening time selected give away to clipboard

Reward forms

The muse of narrate forms stems from this reddit (r/zettelkasten) and weblog posts of the identical author:
The reverse collectors fallacy – Reddit
The reverse collectors fallacy – Weblog submit

This thought used to be built-in internal Brain by making it that that you would per chance per chance take into consideration to design 3 assorted forms of notes reckoning on the form of info internal them:

  • Topic (default)
    A customary zettelkasten narrate (=Zettel).
  • Quote
    Includes a quote that would possibly then be analysed by topic notes.
  • Journal
    A narrate similar to a diary entry. Can then be analysed be topic notes.

Currently the form of narrate can simplest be plight when growing contemporary notes and would possibly per chance not be modified afterwards.

The style of a narrate is reflected in basically the most important personality of the narrate ID. T stands for Topic, J for Journal and Q for Quote.

Examples:

  • T20220101120000
  • Q20220101120000
  • J20220101120000

On the commandline that you would per chance per chance specify the form of the narrate by utilizing the correspondig flag:

  • brn add creates a Topic-narrate
  • brn add -t creates a Topic-narrate
  • brn add -q creates a Quote-narrate
  • brn add -j creates a Journal-narrate

Reward format

Reward format necessities

All notes must satisfy the next format necessities. If they rep not, then errors would possibly happen.

  • The YAML header (=metadata) must persistently be on high of a narrate file
  • The YAML header wants at the least the next fields:
    • identity
    • name
    • date
    • tags
    • one-map hyperlinks
  • Don’t substitute the values of the next fields within the YAML-header (=metadata), as thery are filled routinely:
    • identity
    • date
    • one-map hyperlinks

All values of the metadata fields would possibly very well be split into extra than one traces:

---
identity: T20220101120000
name: Here is a truly lengthy narrate name
      that used to be split into 2 traces
tags: [ my-first-tag, my-second-tag, my-third-tag,
        my-fourth-tag, my-fifth-tag ]
...

The sigh of the fields within the YAML header doesn’t matter:

---
name: Here is a truly lengthy narrate name
      that used to be split into 2 traces
identity: T20220101120000
tags: [ my-first-tag, my-second-tag, my-third-tag,
        my-fourth-tag, my-fifth-tag ]
...

Tags

Tags would possibly very well be declared by changing the cost of the corresponding YAML header field. They are separated by colons:

tags: [ my-first-tag, my-second-tag, my-third-tag ]

So to make consume of areas and particular characters for tags you must quote them:

tags: [ "#my-first-tag", "my second tag", my-third-tag ]

Necessary: It doesn’t matter when you happen to inform your tags with a # or with out as it will be not noted by the program. When browsing for tags that you would per chance per chance persistently consume a # before every thing of the hunt text, to design obvious that that that simplest tags are searched and not narrate names. For extra info about browsing notes search Procuring for notes

Reward template

When executing brn init a hidden directory called .zettelkasten/ is created within the mission folder.

In there you will accumulate a file called narrate-template.md. By changing this file that you would per chance per chance decide how a newly created narrate will be structured.

Necessary: The YAML-Header (=metadata) must persistently be at the pause of the file, as it would per chance not be chanced on otherwise. For extra info relating to narrate formatting search Reward format necessities.

Marker

Markers would possibly very well be used to portray narrate-particular info within the narrate template. When growing a brand contemporary narrate those markers will be replaced by their corresponding info.

Marker Description
Inserts the narrate ID
Inserts the narrate name
Inserts the introduction timestamp

Example: Reward template

./.zettelkasten/narrate-template.md:

---

identity: 
name: 
date: 
tags: [ ]
one-map hyperlinks: [ ]

---

# 

## References

## Quotes

## Sources

If a brand contemporary narrate with the name my contemporary narrate can be created on the 1.January 2022 on 12 a.m. it would possibly look for admire this:

---

identity: T20220101120000
name: my contemporary narrate
date: 2022-01-01 12: 00: 00
tags: [ ]
one-map hyperlinks: [ ]

---

# my contemporary narrate

## References

## Quotes

## Sources

Procuring for notes

Search operators

Operator Description
&& Combines 2 search strings
! Excludes notes including the next search string
# Applies the next search string proper for tags

Detailed description

Notes would possibly very well be searched with the subcommand brn search or all around the TUI mode using the / shortcut:

It would consequence in as an illustration:

T20200629000001 random narrate name        #my-first-imprint
T20200629000002 one other narrate     #my-first-imprint
T20200629000003 one other random narrate     #my-first-imprint-2
T20210629000004 my-first-bright-narrate       #my-first-imprint
T20210718000005 my-first-narrate

That you would per chance search that basically the most important 3 results had been chanced on thanks to their imprint my-first-imprint. The fourth one used to be chanced on thanks to its name and its imprint. On this case the imprint can be displayed. The used to be chanced on simplest thanks to its name. Because the tags of this narrate don’t matter on this case they rep not appear to be displayed right here both.

Must you simplest desire to request for tags, then you positively would possibly set aside a # in front of the hunt text. Reward that the hunt text needs to be quoted this time because the shell would recognise the hunt text as a comment otherwise:

It would consequence in:

T20200629000001 random narrate name        #my-first-imprint
T20200629000002 one other narrate     #my-first-imprint
T20200629000003 one other random narrate     #my-first-imprint-2
T20210629000004 my-first-bright-narrate       #my-first-imprint

As that you would per chance per chance search the narrate my-first-narrate will not be displayed anymore, as it doesn’t like any imprint that contains the text my-first.

That you would per chance moreover mix assorted search necessities with &&. Reward that you must quote the hunt text not simplest thanks to the # but additionally attributable to it now contains areas:

$ brn search "#my-first && random"

It would consequence in:

T20200629000001 random narrate name        #my-first-imprint
T20200629000003 some random narrate     #my-first-imprint-2

As that you would per chance per chance search now there are simplest results which like a imprint containing my-first and both a imprint, a narrate name or narrate ID containing random.

That you would per chance moreover filter the outcomes basically based entirely on issues you rep not desire internal your results with !:

$ brn search "#my-first && !random"

It would consequence in:

T20200629000002 one other narrate     #my-first-imprint
T20210629000004 my-first-bright-narrate       #my-first-imprint

Now all results that encompass random of their narrate name, narrate ID or in any of their tags are not displayed.

The specified search text also persistently searches the narrate IDs. Because the narrate ID contains the timestamp of its introduction this would possibly be very appropriate. As an illustration when you happen to would admire to search all notes that had been created in July 2021:

It would consequence in:

T20210718000005 my-first-narrate
J20210703000032 some journal written in july

That you would per chance moreover filter basically based entirely on narrate kind:

It would consequence in:

T20210718000005 my-first-narrate

Reward that the journal now doesn’t seem because the narrate is n

Read More
Half this on knowasiak.com to chat to folks on this topicPrice in on Knowasiak.com now when you happen to is liable to be not registered yet.

Related Articles

Valve has just validated 3000 Games For The Steam Deck

Willy Jetman: Astromonkey’s RevengeSteam Deck Verified2022-05-21Store Page The Princess, the Stray Cat, and Matters of the HeartSteam Deck Verified2022-05-21Store Page YngletSteam Deck Verified2022-05-21Store Page Citizens of SpaceSteam Deck Playable2022-05-21Store Page VirtuaVerseSteam Deck Playable2022-05-21Store Page Shank 2Steam Deck Verified2022-05-21Store Page Chromosome EvilSteam Deck Playable2022-05-21Store Page New Super Lucky’s TaleSteam Deck Playable2022-05-21Store Page DeleveledSteam Deck Verified2022-05-21Store Page…

What’s recent in Emacs 28.1?

By Mickey Petersen It’s that time again: there’s a new major version of Emacs and, with it, a treasure trove of new features and changes.Notable features include the formal inclusion of native compilation, a technique that will greatly speed up your Emacs experience.A critical issue surrounding the use of ligatures also fixed; without it, you…

Vim Galore: the entirety you accept as true with to know about Vim

Intro What is Vim? The Vim Philosophy First steps Minimal vimrc What kind of Vim am I running? Cheatsheets Basics Buffers, windows, tabs Active, loaded, listed, named buffers Argument list Mappings Mapleader Registers Ranges Marks Completion Motions, operators, text objects Autocmds Changelist, jumplist Undo tree Quickfix and location lists Macros Colorschemes Folding Sessions Locality Usage…

A curated list of warez and piracy links

A curated list of arrrrrrrrr! Preamble Over the past couple of years, I’ve accumulated bookmarks, saved Reddit posts, and GitHub stars all related to piracy in some form or another. This list is my attempt to add structure to those resources and share them. Everything you need to get started on your pirate voyage can…