readshell 0.3.2 β†’ 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE CHANGED
@@ -1,17 +1,21 @@
1
- GNU AFFERO GENERAL PUBLIC LICENSE
2
- Version 3, 19 November 2007
1
+ MIT License
3
2
 
4
- Copyright (C) 2026 ReadShell
3
+ Copyright (c) 2026 ReadShell / davidy
5
4
 
6
- This program is free software: you can redistribute it and/or modify
7
- it under the terms of the GNU Affero General Public License as published by
8
- the Free Software Foundation, either version 3 of the License, or
9
- (at your option) any later version.
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
10
11
 
11
- This program is distributed in the hope that it will be useful,
12
- but WITHOUT ANY WARRANTY; without even the implied warranty of
13
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
- GNU Affero General Public License for more details.
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
15
14
 
16
- You should have received a copy of the GNU Affero General Public License
17
- along with this program. If not, see <https://www.gnu.org/licenses/>.
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -8,10 +8,10 @@
8
8
 
9
9
  [![npm version](https://img.shields.io/npm/v/readshell.svg)](https://www.npmjs.com/package/readshell)
10
10
  [![npm downloads](https://img.shields.io/npm/dm/readshell.svg)](https://www.npmjs.com/package/readshell)
11
- [![License: AGPL-3.0](https://img.shields.io/badge/License-AGPL%20v3-blue.svg)](https://www.gnu.org/licenses/agpl-3.0)
12
- [![Node.js](https://img.shields.io/badge/Node.js-%3E%3D18-green.svg)](https://nodejs.org)
11
+ [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
12
+ [![Node.js](https://img.shields.io/badge/Node.js-%3E%3D20-green.svg)](https://nodejs.org)
13
13
 
14
- *A low-friction reading tool for developers who never leave the terminal.*
14
+ *A low-friction reading tool for developers who never leave the terminal. Free and open source β€” no accounts, no servers, no paid tier.*
15
15
 
16
16
  ![ReadShell Demo](./docs/demo.gif)
17
17
 
@@ -40,19 +40,24 @@ One command. Back to where you were. Back to work when you're ready.
40
40
  The most important command. Picks up exactly where you left off, down to the byte.
41
41
 
42
42
  **πŸ₯· Boss Key (`b` / `Esc`) β€” Instant disguise**
43
- One keypress transforms the reader into a convincing terminal error log. Your secret is safe.
43
+ One keypress transforms the reader into a convincing terminal error log (nodejs / python / java / c / go). Your secret is safe.
44
+ ![Boss Key Demo](./docs/error.png)
45
+ *Boss Key wipes the scrollback buffer and shows a fake error. `novel resume` jumps back to the exact spot.*
44
46
 
45
- **⏱ Reading time estimate**
46
- Calibrated to your actual reading speed. Tells you if you have time for one more chapter.
47
+ **πŸ”„ Folder sync β€” multi-device, no server**
48
+ Point ReadShell at any folder synced by iCloud Drive, Dropbox, OneDrive, εšζžœδΊ‘, or Syncthing. Progress, bookmarks (including deletions), and reading stats merge across devices automatically on open/exit. Nothing is ever uploaded to a ReadShell server β€” there isn't one.
47
49
 
48
- **πŸ”– Bookmarks (`m`)**
49
- Capture a passage mid-read. Revisit it later from the chapter navigator (`c`).
50
+ **πŸ“Š `novel stats` β€” GitHub-style heatmap**
51
+ A year of reading at a glance, plus reading days, total time, books read, and streaks β€” aggregated across all synced devices.
52
+
53
+ **πŸ”– Bookmarks (`m`) + free export**
54
+ Capture a passage mid-read, revisit via the chapter navigator (`c`), export everything with `novel bookmarks export --format md|json`.
50
55
 
51
56
  **πŸ“š Batch import**
52
- `novel import ~/books/` β€” recursively imports an entire folder of `.txt` and `.epub` files.
57
+ `novel import ~/books/` β€” recursively imports `.txt`, `.epub`, and `.md` files.
53
58
 
54
59
  **🌐 i18n**
55
- Native English and Chinese support.
60
+ Native Chinese and English support (`novel lang zh|en`).
56
61
 
57
62
  ---
58
63
 
@@ -78,8 +83,9 @@ novel list
78
83
 
79
84
  | Key | Action |
80
85
  |---|---|
81
- | `Space` / `j` / `↓` | Next page / scroll down |
86
+ | `Space` / `j` / `↓` / `f` | Next page / scroll down |
82
87
  | `k` / `↑` | Previous page / scroll up |
88
+ | `g` / `G` | First / last page |
83
89
  | `c` | Chapter list & bookmarks |
84
90
  | `Tab` | Toggle chapters / bookmarks |
85
91
  | `m` | Add bookmark |
@@ -87,14 +93,56 @@ novel list
87
93
  | `q` | Quit & save |
88
94
  | `?` | Help |
89
95
 
90
- ### Configuration
96
+ ### Commands
97
+ ```bash
98
+ novel import <path> # file or directory (txt / epub / md)
99
+ novel list # library
100
+ novel open <id|title> # open a book
101
+ novel resume # resume last position
102
+ novel remove <id|title> # remove from library
103
+ novel stats # reading heatmap & streaks
104
+ novel bookmarks export [--format json|md] [--out file]
105
+ novel sync --dir <path> [--with-books] # set sync folder & sync
106
+ novel sync # sync with saved folder
107
+ novel sync --off # disable sync
108
+ novel lang zh|en # interface language
109
+ novel config <key> <value> # language | line-spacing | reading-mode | boss-key-lang
110
+ novel update # update to latest
111
+ ```
112
+
113
+ ---
114
+
115
+ ## Folder Sync
116
+
117
+ ReadShell syncs through a plain folder β€” no account, no server. Each device writes a snapshot to `<syncDir>/readshell-sync/devices/<deviceId>.json` and merges every other device's file (last-write-wins progress, bookmark tombstones, session union).
118
+
119
+ Pick a folder that your sync tool already watches:
120
+
121
+ ```bash
122
+ # iCloud Drive (macOS)
123
+ novel sync --dir "$HOME/Library/Mobile Documents/com~apple~CloudDocs/ReadShell"
124
+
125
+ # Dropbox
126
+ novel sync --dir ~/Dropbox/ReadShell
127
+
128
+ # εšζžœδΊ‘ / OneDrive / Syncthing β€” same idea, any synced folder
129
+ novel sync --dir ~/Nutstore/ReadShell
130
+ ```
131
+
132
+ Add `--with-books` to also copy book files into the sync folder β€” other devices will auto-import books they don't have yet. Without it, only progress/bookmarks/stats sync (books are matched by file hash).
133
+
134
+ Sync runs automatically when the reader opens (pull) and exits (push + pull), silently and bounded to ~2s. `novel sync --off` disables it.
135
+
136
+ ---
137
+
138
+ ## Migrating from readshell-pro
139
+
91
140
  ```bash
92
- novel lang en # Set language (en / zh)
93
- novel config line-spacing 1 # Line spacing
94
- novel config reading-mode scroll # scroll or page
95
- novel update # Update to latest
141
+ npm uninstall -g readshell-pro && npm install -g readshell
96
142
  ```
97
143
 
144
+ Your library, progress, and bookmarks are preserved β€” the data directory is unchanged. Cloud auth keys are cleaned up automatically on first run.
145
+
98
146
  ---
99
147
 
100
148
  ## Why the terminal?
@@ -103,13 +151,13 @@ The terminal is already where you live. It's focused, text-only, and distraction
103
151
 
104
152
  ReadShell doesn't ask you to context-switch. It sits quietly in your workflow β€” invisible to colleagues, zero install friction, no accounts, no cloud, no noise.
105
153
 
106
- Your reading history lives entirely on your local machine in a SQLite file. Nothing leaves your disk.
154
+ Your reading history lives entirely on your local machine in a SQLite file (plus the sync folder you choose). Nothing leaves your disk otherwise.
107
155
 
108
156
  ---
109
157
 
110
158
  ## Tech Stack
111
159
 
112
- - **TypeScript** + **Node.js** β‰₯ 18
160
+ - **TypeScript** + **Node.js** β‰₯ 20
113
161
  - **Ink** β€” React-based TUI framework
114
162
  - **SQLite** (`better-sqlite3`) β€” local-first, zero-dependency storage
115
163
  - **Vitest** β€” testing
@@ -119,8 +167,8 @@ Your reading history lives entirely on your local machine in a SQLite file. Noth
119
167
  src/
120
168
  β”œβ”€β”€ cli/ # Command layer
121
169
  β”œβ”€β”€ ui/ # TUI components (Ink)
122
- β”œβ”€β”€ services/ # Business logic
123
- β”œβ”€β”€ parsers/ # txt / epub parsers
170
+ β”œβ”€β”€ services/ # Business logic (incl. folder sync, stats)
171
+ β”œβ”€β”€ parsers/ # txt / epub / md parsers
124
172
  β”œβ”€β”€ db/ # SQLite layer
125
173
  β”œβ”€β”€ config/ # Config management
126
174
  └── utils/
@@ -130,11 +178,15 @@ src/
130
178
 
131
179
  ## Contributing
132
180
 
133
- Issues, ideas, and PRs are welcome.
181
+ Issues, ideas, and PRs are welcome β€” see [CONTRIBUTING](docs/CONTRIBUTING.md).
134
182
  If ReadShell fits into your workflow, a ⭐ helps more people find it.
135
183
 
184
+ ## Sponsor
185
+
186
+ If ReadShell saves you time, consider supporting development: https://readshell.com/sponsor
187
+
136
188
  ---
137
189
 
138
190
  ## License
139
191
 
140
- [AGPL-3.0](LICENSE)
192
+ [MIT](LICENSE)