Skip to content

Commit eb28f87

Browse files
committed
Add a usage section to the readme
1 parent 9543481 commit eb28f87

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,18 @@ This is a plugin for [Obsidian](https://obsidian.md) that lets you define custom
44

55
If you're used to writing in an environment that auto-links certain strings and don't want to build new habits, this will help with that. E.g. `T12345` in phabricator, or `#4324` in github.
66

7+
## Usage
8+
9+
Install and enable the plugin. Once you do, you'll find there's a new section in your settings called "Smart Links". In it you can add/remove replacement rules. You'll need to write a regular expression and a replacement string for it. This can range from very simple to very complicated.
10+
11+
| Regular expression | Replacement |
12+
|--------------------|-----------------------------------------|
13+
| `T(\d+)` | `https://phabricator.wikimedia.org/T$1` |
14+
| `(?:AAPL\|GOOG)` | `https://finance.yahoo.com/quote/$&` |
15+
| `go\/[_\d\w-/]+` | `http://$&` |
16+
17+
The replacements work using normal Javascript regular expression replacement syntax. I'm so very sorry.
18+
719
## Credits
820

921
The reading-mode code was heavily influenced by [Obsidian GoLinks](https://github.com/xavdid/obsidian-golinks) -- this plugin is (arguably) a customizable superset of that one's functionality.

0 commit comments

Comments
 (0)