Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
152 changes: 138 additions & 14 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,26 +1,150 @@
# Binaries for programs and plugins
# --- OS ---
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
Thumbs.db
Desktop.ini
*~

# --- Editors / IDEs ---
.vscode/
.idea/
*.swp
*.swo
*.sublime-project
*.sublime-workspace
*.code-workspace

# --- Env / secrets (keep example env files tracked) ---
.env
.env.*
!.env.example
!.env.*.example
*.pem
*.priv
*.key
!*.pub

# --- Go ---
*.exe
*.exe~
*.dll
*.so
*.dylib


# Test binary, built with `go test -c`
*.test

# Output of the go coverage tool, specifically when used with LiteIDE
*.out
*.prof
*.coverprofile
coverage.out
coverage.html
assets_vfsdata.go
# vendor/ # uncomment if using vendoring
# Local toolchains (scripts/download-go-node.sh)
.tools/
# Ad-hoc binaries built at repo root
/rmdecode
/rmfakecloud
/rmdoc2png

# --- Node / JavaScript / TypeScript (Vite, pnpm) ---
node_modules/
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*
.pnpm-store/
.npm/
.yarn/
.yarn/cache
.yarn/unplugged
.yarn/build-state.yml
.yarn/install-state.gz
.pnp.*
.eslintcache
data/
*.tsbuildinfo
.turbo/
.cache/
ui/dist/
ui/build/
ui/.vite/

# --- Python (scripts, rmscene, rmc) ---
__pycache__/
*.py[cod]
*$py.class
*.pyo
.Python
.venv/
venv/
ENV/
env/
.env/
*.egg
*.egg-info/
.eggs/
dist/
node_modules/
assets_vfsdata.go
.vscode/
assets_vfsdata.go
# Dependency directories (remove the comment below to include it)
# vendor/
build/
.pytest_cache/
.mypy_cache/
.ruff_cache/
.tox/
.coverage
.coverage.*
htmlcov/
.ipynb_checkpoints/

# mkdoc build
# --- C / C++ / CMake / Emscripten (librm_lines WASM) ---
CMakeCache.txt
CMakeFiles/
cmake-build-*/
cmake_install.cmake
compile_commands.json
CTestTestfile.cmake
Makefile.cmake
*.o
*.obj
*.a
*.lib
*.la
*.lo
*.gch
*.pch
*.d
*.gcda
*.gcno
*.gcov
.ninja_deps
.ninja_log
build.ninja
ui/extra/simplerenderer/build/
ui/extra/simplerenderer/cmake-build-*/
# Intermediate WASM/JS from local emscripten builds (shipped copies live under ui/public/assets/)
ui/extra/simplerenderer/*.wasm
ui/extra/simplerenderer/*.js
ui/extra/simplerenderer/*.wasm.map
ui/extra/simplerenderer/*.js.map
!ui/public/assets/

# --- Docs (mkdocs) ---
site/

# --- App runtime / local data ---
data/
*.log
tmp/
temp/
*.tmp

# --- Build / release output ---
/dist/
*.zip
*.tar
*.tar.gz
*.tgz

# --- Device firmware reference binaries (local reverse-engineering copies) ---
refrences/
references/
6 changes: 6 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[submodule "ui/extra/simplerenderer/librm_lines"]
path = ui/extra/simplerenderer/librm_lines
url = https://github.com/RedTTGMoss/librm_lines
[submodule "third_party/rmscene"]
path = third_party/rmscene
url = https://github.com/ricklupton/rmscene.git
18 changes: 18 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,21 @@
# Unreleased

## Features

- `.rm` lines decoder: `cmd/rmdecode` and `internal/rmdecode` — export all writings to **SVG** or **PDF** (`-format` / `-o`); v3/v5 in Go, v6 via `rmc`; v6 text summary via Python + `rmscene` (see `internal/rmdecode/README.md`).
- **`cmd/rmdoc2png`**: extract every `*.rm` from a `.rmdoc` zip and write paginated PNGs (`001_….png`, …; v3/v5 in Go + gg; v6 via `scripts/rmscene_v6_to_png.py` + Pillow + vendored `third_party/rmscene`).
- Document type from `.content` file when present and size > 4 bytes (pdf, epub, notebook).
- Template thumbnails use `iconData` from `.template` file when available (base64 SVG).
- EPUB table of contents (TOC) uses black font color.
- PDF object fallback: "Alternative text: Download PDF" when plugin cannot render.

## Changed

- PDFs rendered solely as raw `application/pdf` via browser/Adobe plugin; removed react-pdf and PNG+overlay viewer.
- Error boundary ("Something went wrong") adds meta refresh to `/` and link to home.

---

# 0.0.25

## Features
Expand Down
16 changes: 16 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,22 @@ See the [documentation](https://ddvk.github.io/rmfakecloud/remarkable/setup/) fo

run `./dev.sh` which should start the UI and backend

### `.rm` page decoder (lines format)

To inspect raw handwriting pages (`*.rm`), see **[internal/rmdecode/README.md](internal/rmdecode/README.md)**. It documents **v3/v5** (Go) vs **v6** (Python + [rmscene](https://github.com/ricklupton/rmscene)), and points to **[rmc](https://github.com/ricklupton/rmc)** for production-grade v6 SVG/PDF export from the ecosystem.

The **rmscene** library is included as a git submodule at **`third_party/rmscene`**. After a fresh clone run: `git submodule update --init --recursive`.

```bash
go run ./cmd/rmdecode /path/to/page.rm
go run ./cmd/rmdecode -o strokes.svg -format svg /path/to/page.rm
go run ./cmd/rmdecode -o strokes.pdf /path/to/page.rm
```

v3/v5 SVG/PDF are rendered in Go; v6 SVG/PDF use the `rmc` CLI if installed.

**`.rmdoc` → PNG (all pages, paged filenames):** `go run ./cmd/rmdoc2png -o outdir doc.rmdoc` — writes `001_name.png`, `002_…` for each `*.rm` (v3/v5 in Go; v6 needs Python + Pillow + vendored [rmscene](https://github.com/ricklupton/rmscene)). See `internal/rmdecode/README.md`.

### Caveats/ WARNING

- (applies when you don't have security, version <= 0.0.3) connecting to the api will delete all your files, unless you mark them as not synced `synced:false` prior to syncing (advisable just to disconnect, reconnect the cloud)
Expand Down
Loading