mirror of
https://github.com/vrtmrz/obsidian-livesync.git
synced 2025-12-13 09:45:56 +00:00
Merge branch 'main' into chore/formatting
This commit is contained in:
@@ -140,28 +140,33 @@ const uri_passphrase = `${Deno.env.get("uri_passphrase") ?? friendlyString()}`;
|
|||||||
|
|
||||||
const URIBASE = "obsidian://setuplivesync?settings=";
|
const URIBASE = "obsidian://setuplivesync?settings=";
|
||||||
async function main() {
|
async function main() {
|
||||||
|
// We need re-format this
|
||||||
const conf = {
|
const conf = {
|
||||||
couchDB_URI: `${Deno.env.get("hostname")}`,
|
"couchDB_URI": `${Deno.env.get("hostname")}`,
|
||||||
couchDB_USER: `${Deno.env.get("username")}`,
|
"couchDB_USER": `${Deno.env.get("username")}`,
|
||||||
couchDB_PASSWORD: `${Deno.env.get("password")}`,
|
"couchDB_PASSWORD": `${Deno.env.get("password")}`,
|
||||||
couchDB_DBNAME: `${Deno.env.get("database")}`,
|
"couchDB_DBNAME": `${Deno.env.get("database")}`,
|
||||||
syncOnStart: true,
|
"syncOnStart": true,
|
||||||
gcDelay: 0,
|
"gcDelay": 0,
|
||||||
periodicReplication: true,
|
"periodicReplication": true,
|
||||||
syncOnFileOpen: true,
|
"syncOnFileOpen": true,
|
||||||
encrypt: true,
|
"encrypt": true,
|
||||||
passphrase: `${Deno.env.get("passphrase")}`,
|
"passphrase": `${Deno.env.get("passphrase")}`,
|
||||||
usePathObfuscation: true,
|
"usePathObfuscation": true,
|
||||||
batchSave: true,
|
"batchSave": true,
|
||||||
batch_size: 50,
|
"batch_size": 50,
|
||||||
batches_limit: 50,
|
"batches_limit": 50,
|
||||||
useHistory: true,
|
"useHistory": true,
|
||||||
disableRequestURI: true,
|
"disableRequestURI": true,
|
||||||
customChunkSize: 50,
|
"customChunkSize": 50,
|
||||||
syncAfterMerge: false,
|
"syncAfterMerge": false,
|
||||||
concurrencyOfReadChunksOnline: 100,
|
"concurrencyOfReadChunksOnline": 100,
|
||||||
minimumIntervalOfReadChunksOnline: 100,
|
"minimumIntervalOfReadChunksOnline": 100,
|
||||||
};
|
"handleFilenameCaseSensitive": false,
|
||||||
|
"doNotUseFixedRevisionForChunks": false,
|
||||||
|
"settingVersion": 10,
|
||||||
|
"notifyThresholdOfRemoteStorageSize": 800
|
||||||
|
}
|
||||||
const encryptedConf = encodeURIComponent(await encrypt(JSON.stringify(conf), uri_passphrase, false));
|
const encryptedConf = encodeURIComponent(await encrypt(JSON.stringify(conf), uri_passphrase, false));
|
||||||
const theURI = `${URIBASE}${encryptedConf}`;
|
const theURI = `${URIBASE}${encryptedConf}`;
|
||||||
console.log("\nYour passphrase of Setup-URI is: ", uri_passphrase);
|
console.log("\nYour passphrase of Setup-URI is: ", uri_passphrase);
|
||||||
|
|||||||
Reference in New Issue
Block a user