Compare commits

...

8 Commits
0.1.5 ... 0.1.8

Author SHA1 Message Date
vorotamoroz
9965d123bd bumped 2021-10-27 23:25:19 +09:00
vorotamoroz
b1c045937b fixed #5 2021-10-27 23:23:49 +09:00
vrtmrz
a4fdcf9540 change information order. 2021-10-27 18:30:11 +09:00
vrtmrz
a9f06a3ae7 Add readme. 2021-10-27 18:28:30 +09:00
vorotamoroz
0946b1e012 Update database fixing procedure. 2021-10-26 18:31:50 +09:00
vorotamoroz
ccbf1b2ffe fix some,
- Add Utility functions.
- Database reset opeartion and corrupt preventions.
- Fixing file deleting.
- Tidy up setting dialog.
- Add notice about the file that having platform dependant name.
- Add webclip on readme
2021-10-26 18:08:01 +09:00
vorotamoroz
a01079d4b1 add the information of Test Server and WebClipper 2021-10-25 11:37:51 +09:00
vorotamoroz
1d71870fa3 Add 1 Feature and Refactored some
- Add Remote Database version check.
- Removed Depencency from Database Class.
2021-10-21 18:48:42 +09:00
7 changed files with 569 additions and 153 deletions

View File

@@ -16,6 +16,7 @@ Limitations: Folder deletion handling is not completed.
- Live Sync
- Self-Hosted data synchronization with conflict detection and resolving in Obsidian.
- Off-line sync is also available.
- Receive WebClip from [obsidian-livesync-webclip](https://chrome.google.com/webstore/detail/obsidian-livesync-webclip/jfpaflmpckblieefkegjncjoceapakdf)
## IMPORTANT NOTICE
@@ -32,20 +33,48 @@ If you want to synchronize to both backend, sync one by one, please.
Setup details are in Couldant Setup Section.
5. Setup LiveSync or SyncOnSave or SyncOnStart as you like.
## When your database looks corrupted
## Test Server
Setting up an instance of Cloudant or local CouchDB is a little complicated, so I made the [Tasting server of obsidian-livesync](https://olstaste.vrtmrz.net/) up. Try free!
Note: Please read "Limitations" carefully. Do not send your private vault.
## WebClipper is also available.
Available from on Chrome Web Store:[obsidian-livesync-webclip](https://chrome.google.com/webstore/detail/obsidian-livesync-webclip/jfpaflmpckblieefkegjncjoceapakdf)
Repo is here: [obsidian-livesync-webclip](https://github.com/vrtmrz/obsidian-livesync-webclip). (Docs are work in progress.)
## When your database looks corrupted or too heavy to replicate to a new device.
obsidian-livesync changes data treatment of markdown files since 0.1.0
When you are troubled with synchronization, **Please reset local and remote databases**.
_Note: Without synchronization, your files won't be deleted._
1. Update plugin on all devices.
1. Disable any synchronizations on all devices.
2. From the most reliable device<sup>(_The device_)</sup>, back your vault up.
3. Click "Reset local database" on all devices.
4. From _The device_ click "Reset remote database".
5. From _The device_ click "Init Database again".
6. Enable any sync or Hit the Replication button.
1. From the most reliable device<sup>(_The device_)</sup>, back your vault up.
1. Press "Drop History"-> "Execute" button from _The device_.
1. Wait for a while, so obsidian-livesync will say "completed."
1. In other devices, replication will be canceled automatically. Click "Reset local database" and click "I'm ready, mark this device 'resolved'" on all devices.
If it doesn't be shown. replicate once.
1. It's all done. But if you are sure to resolve all devices and the warning is noisy, click "I'm ready, unlock the database". it unlocks the database completely.
# Designed architecture
## How does this plugin synchronize.
![Synchronization](images/1.png)
1. When notes are created or modified, Obsidian raises some events. obsidian-live-sync catch these events and reflect changes into Local PouchDB.
2. PouchDB automatically or manually replicates changes to remote CouchDB.
3. Another device is watching remote CouchDB's changes, so retrieve new changes.
4. obsidian-live-sync reflects replicated changeset into Obsidian's vault.
Note: The figure is drawn as single-directional, between two devices. But everything occurs bi-directionally between many devices at once in real.
## Techniques to keep bandwidth low.
![dedupe](images/2.png)
And wait for a minute. your data will be uploaded and synchronized with all devices again.
## Cloudant Setup

BIN
images/1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 96 KiB

BIN
images/2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 223 KiB

671
main.ts

File diff suppressed because it is too large Load Diff

View File

@@ -1,7 +1,7 @@
{
"id": "obsidian-livesync",
"name": "Obsidian Live sync",
"version": "0.1.5",
"version": "0.1.8",
"minAppVersion": "0.9.12",
"description": "Reflect your vault changes to some other devices immediately. Please make sure to disable other synchronize solutions to avoid content corruption or duplication.",
"author": "vorotamoroz",

4
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{
"name": "obsidian-livesync",
"version": "0.0.8",
"version": "0.1.8",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "obsidian-livesync",
"version": "0.0.8",
"version": "0.1.8",
"license": "MIT",
"dependencies": {
"diff-match-patch": "^1.0.5",

View File

@@ -1,6 +1,6 @@
{
"name": "obsidian-livesync",
"version": "0.1.5",
"version": "0.1.8",
"description": "Reflect your vault changes to some other devices immediately. Please make sure to disable other synchronize solutions to avoid content corruption or duplication.",
"main": "main.js",
"scripts": {