| 
									
										
										
										
											2022-02-10 23:37:25 +01:00
										 |  |  | # Trilium Notes DB dump tool
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | This is a simple tool to dump the content of Trilium's document.db onto filesystem. | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | It is meant as a last resort solution when the standard mean to access your data (through main Trilium application) fail. | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | ## Installation
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2022-10-26 23:50:54 +02:00
										 |  |  | This tool requires node.js, testing has been done on 16.18.0, but it will probably work on other versions as well. | 
					
						
							| 
									
										
										
										
											2022-02-10 23:37:25 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  | ``` | 
					
						
							|  |  |  | npm install | 
					
						
							|  |  |  | ``` | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | ## Running
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-08-10 18:23:49 +02:00
										 |  |  | See output of `npx esrun dump.ts --help`: | 
					
						
							| 
									
										
										
										
											2022-02-10 23:37:25 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  | ``` | 
					
						
							| 
									
										
										
										
											2024-08-10 18:23:49 +02:00
										 |  |  | dump-db.ts <path_to_document> <target_directory> | 
					
						
							| 
									
										
										
										
											2022-02-12 22:20:15 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  | dump the contents of document.db into the target directory | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | Positionals: | 
					
						
							|  |  |  | path_to_document  path to the document.db | 
					
						
							|  |  |  | target_directory  path of the directory into which the notes should be dumped | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | Options: | 
					
						
							|  |  |  | --help             Show help                                         [boolean] | 
					
						
							|  |  |  | --version          Show version number                               [boolean] | 
					
						
							|  |  |  | --password         Set password to be able to decrypt protected notes.[string] | 
					
						
							|  |  |  | --include-deleted  If set to true, dump also deleted notes. | 
					
						
							|  |  |  | [boolean] [default: false] | 
					
						
							| 
									
										
										
										
											2022-02-10 23:37:25 +01:00
										 |  |  | ``` |