Tablature

approvedunreviewed

by hc-nolan

Write and edit guitar tabs from the keyboard, in fenced code blocks.

★ 1 stars↓ 49 downloadsUpdated 17d agoGPL-3.0

Tablature

Write and edit guitar and bass tabs from the keyboard in Obsidian. A port of tablature.nvim.

Your tabs stay plain text in fenced code blocks, so a note reads the same with or without the plugin. Requires Obsidian 1.15.0 or later, on desktop. Works with or without Vim mode.

Getting started

  1. Under Settings → Hotkeys, search for "Tablature" and assign keys to Insert staff and Enter tab mode. The plugin sets no hotkeys of its own.
  2. Put the cursor on an existing staff and run Enter tab mode. Anywhere else, Enter tab mode inserts a blank staff first, as does Insert staff.
  3. Type frets. Press Esc when you're done.

Note format

Tablature works in code blocks marked tab and in code blocks with no language. Blocks in other languages are left alone.

```tab
e|------------|------------|
B|--1--3------|------------|
G|------------|--12--------|
D|------------|------------|
A|------------|------------|
E|------------|------------|
```
  • A staff is at least 2 consecutive lines. Each line has a label of 1 to 4 characters, then |, and ends with |.
  • Each beat is 3 characters wide, so every measure's width must be a multiple of 3.
  • The bars must line up on every row. If they don't, tab mode tells you what's wrong rather than editing the staff.
  • Any other line, such as an annotation or a blank line, separates staves and is never changed.

Keys

Tab mode

KeyAction
h or ←, l or →Previous or next beat
H or {, L or }First beat of the previous or next measure
j or ↓, k or ↑Next or previous string, continuing into the next or previous staff
0–9Write a fret. Two digits in a row make a double-digit fret
SpaceClear the cell
BackspaceClear the previous cell and move onto it
TChange the staff's tuning
BSet the number of beats in every measure of the staff
v, or Shift+←/→Select measures. After v, moving extends the selection; v or Esc cancels it
y or Ctrl+C (⌘+C on macOS)Copy the selected measures, or the current one
p or Ctrl+V (⌘+V on macOS)Paste the copied measures after the current one
d or DeleteDelete the selected measures, or the current one
CPick a chord shape and enter chord mode
NInsert a staff below
ISwitch the staff between guitar and bass
Esc or qExit tab mode
?Show all keys in the legend below the staff, or only the essentials

Other keys type nothing, so stray typing can't break a staff. Combinations with Ctrl or Cmd, such as undo and save, work as usual. Clicking a cell moves to it, and clicking outside a staff exits.

I keeps the low strings and adds or removes the high ones, using the first guitar or bass tuning. It won't remove a string that has notes on it.

Chord mode

A preview of the chord follows the cursor until you write it.

KeyAction
Tab, Shift+TabNext or previous shape
+ or =, -Move the root fret up or down
EnterWrite the chord
CPick a different shape
Movement keysAs in tab mode
Esc or qReturn to tab mode
?Show all keys or only the essentials

Settings

  • Default beats per measure and Default measures per staff set the size of new staves.

  • New staves use sets whether a staff inserted from scratch is for guitar or bass. Inserting next to an existing staff copies its tuning instead.

  • Guitar tunings and Bass tunings have one tuning per line, low string to high. The first in each list is the default for new staves of that instrument. Built-in defaults are always included, so ones added by an update appear without changing your own entries:

    Drop D | D A D G B e
    
  • Chord shapes has one shape per line, low string to high. Use default for any tuning, or a tuning's name to limit the shape to that tuning. x mutes a string:

    default | Power 5th (E root) | 0 2 2 x x x
    Standard | Major (E shape) | 0 2 2 1 0 0
    default | Bass octave (E root) | 0 x 2 x
    

Install manually

From a release, download main.js, manifest.json and styles.css into <your vault>/.obsidian/plugins/tablature/. Then reload Obsidian and enable Tablature under Settings → Community plugins.

To build from source:

pnpm install
pnpm build

Privacy

Tablature makes no network requests and collects no data. It only changes the note you're editing.

How this was made

This plugin was written with Claude Code, an AI coding agent. The author directed the design and tested the plugin by hand, but hasn't reviewed the code line by line.

License

GPL-3.0-only

For plugin developers

Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.