0.0.1 • Published 1 year ago

scrapbox-to-markdown v0.0.1

Weekly downloads
-
License
-
Repository
-
Last release
1 year ago

scrapbox-to-markdown

A CLI application to convert Scrapbox text to Markdown using progfay/scrapbox-parser.

Install & Usage

Clone this repo and then execute the following commands.

pnpm global-install
scrapbox-to-markdown examples/example.txt

or

pnpm tsc
node build/index.js examples/example.txt

s2m is an alias for scrapbox-to-markdown.

For Obsidian markdown:

scrapbox-to-markdown examples/example.txt --obsidian

If you want to output to a file:

scrapbox-to-markdow examples/example.txt -o examples/example.md

Example

example.txt based on https://scrapbox.io/help/syntax is converted to example.md as follows:

Syntax
[https://gyazo.com/0f82099330f378fe4917a1b4a5fe8815]

[[Internal Links]] (linking to another page on scrapbox)
	`[link]` ⇒ [Link]

[[External  Links]] (linking to another web page)
 `http://google.com` ⇒ http://google.com
	`[http://google.com Google]` ⇒ [http://google.com Google]
or
 `[Google http://google.com]` ⇒ [Google http://google.com]

...

is converted to

# Syntax

![](https://gyazo.com/0f82099330f378fe4917a1b4a5fe8815/thumb/1000)



**Internal Links** (linking to another page on scrapbox)

- `[link]` ⇒ [Link](Link)


**External  Links** (linking to another web page)

- `http://google.com` ⇒ [](http://google.com)
- `[http://google.com Google]` ⇒ [Google](http://google.com)
or

- `[Google http://google.com]` ⇒ [Google](http://google.com)

...