diff --git a/.obsidian/plugins/obsidian-git/main.js b/.obsidian/plugins/obsidian-git/main.js index 726960a9..1b1f73ba 100644 --- a/.obsidian/plugins/obsidian-git/main.js +++ b/.obsidian/plugins/obsidian-git/main.js @@ -31252,9 +31252,7 @@ var ObsidianGit = class extends import_obsidian23.Plugin { let status2; let unstagedFiles; if (this.gitManager instanceof SimpleGit) { - const file = this.app.vault.getAbstractFileByPath(this.conflictOutputFile); - if (file != null) - await this.app.vault.delete(file); + this.mayDeleteConflictFile(); status2 = await this.updateCachedStatus(); if (fromAutoBackup && status2.conflicted.length > 0) { this.displayError(`Did not commit, because you have conflicts in ${status2.conflicted.length} ${status2.conflicted.length == 1 ? "file" : "files"}. Please resolve them and commit per command.`); @@ -31267,9 +31265,7 @@ var ObsidianGit = class extends import_obsidian23.Plugin { this.displayError(`Did not commit, because you have conflicts. Please resolve them and commit per command.`); return false; } else if (hadConflict) { - const file = this.app.vault.getAbstractFileByPath(this.conflictOutputFile); - if (file != null) - await this.app.vault.delete(file); + await this.mayDeleteConflictFile(); status2 = await this.updateCachedStatus(); changedFiles = [...status2.changed, ...status2.staged]; } else { @@ -31346,10 +31342,9 @@ var ObsidianGit = class extends import_obsidian23.Plugin { if (!await this.remotesAreSet()) { return false; } - const file = this.app.vault.getAbstractFileByPath(this.conflictOutputFile); const hadConflict = this.localStorage.getConflict() === "true"; - if (this.gitManager instanceof SimpleGit && file) - await this.app.vault.delete(file); + if (this.gitManager instanceof SimpleGit) + await this.mayDeleteConflictFile(); let status2; if (this.gitManager instanceof SimpleGit && (status2 = await this.updateCachedStatus()).conflicted.length > 0) { this.displayError(`Cannot push. You have conflicts in ${status2.conflicted.length} ${status2.conflicted.length == 1 ? "file" : "files"}`); @@ -31387,6 +31382,17 @@ var ObsidianGit = class extends import_obsidian23.Plugin { } return pulledFiles.length != 0; } + async mayDeleteConflictFile() { + const file = this.app.vault.getAbstractFileByPath(this.conflictOutputFile); + if (file) { + this.app.workspace.iterateAllLeaves((leaf) => { + if (leaf.view instanceof import_obsidian23.MarkdownView && leaf.view.file.path == file.path) { + leaf.detach(); + } + }); + await this.app.vault.delete(file); + } + } async stageFile(file) { if (!await this.isAllInitialized()) return false; @@ -31584,7 +31590,10 @@ var ObsidianGit = class extends import_obsidian23.Plugin { if (conflicted !== void 0) { lines = [ "# Conflicts", - "Please resolve them and commit per command (This file will be deleted before the commit).", + "Please resolve them and commit them using the commands `Obsidian Git: Commit all changes` followed by `Obsidian Git: Push`", + "(This file will automatically be deleted before commit)", + "[[#Additional Instructions]] available below file list", + "", ...conflicted.map((e) => { const file = this.app.vault.getAbstractFileByPath(e); if (file instanceof import_obsidian23.TFile) { @@ -31593,7 +31602,18 @@ var ObsidianGit = class extends import_obsidian23.Plugin { } else { return `- Not a file: ${e}`; } - }) + }), + ` +# Additional Instructions +I strongly recommend to use "Source mode" for viewing the conflicted files. For simple conflicts, in each file listed above replace every occurrence of the following text blocks with the desired text. + +\`\`\`diff +<<<<<<< HEAD + File changes in local repository +======= + File changes in remote repository +>>>>>>> origin/main +\`\`\`` ]; } this.writeAndOpenFile(lines == null ? void 0 : lines.join("\n")); diff --git a/.obsidian/plugins/obsidian-git/manifest.json b/.obsidian/plugins/obsidian-git/manifest.json index 6cfe6c00..db1024b2 100644 --- a/.obsidian/plugins/obsidian-git/manifest.json +++ b/.obsidian/plugins/obsidian-git/manifest.json @@ -5,5 +5,5 @@ "isDesktopOnly": false, "fundingUrl": "https://ko-fi.com/vinzent", "js": "main.js", - "version": "2.13.0" + "version": "2.14.0" } diff --git a/.obsidian/plugins/obsidian-hider/manifest.json b/.obsidian/plugins/obsidian-hider/manifest.json index 35be2f99..818161b0 100644 --- a/.obsidian/plugins/obsidian-hider/manifest.json +++ b/.obsidian/plugins/obsidian-hider/manifest.json @@ -1,10 +1,11 @@ { "id": "obsidian-hider", "name": "Hider", - "version": "1.2.3", + "version": "1.2.4", "minAppVersion": "0.16.0", "description": "Hide UI elements such as tooltips, status, titlebar and more", "author": "@kepano", "authorUrl": "https://www.twitter.com/kepano", + "fundingUrl": "https://www.buymeacoffee.com/kepano", "isDesktopOnly": false } \ No newline at end of file diff --git a/.obsidian/workspace.json b/.obsidian/workspace.json index cccfdabd..6a6ce94f 100644 --- a/.obsidian/workspace.json +++ b/.obsidian/workspace.json @@ -11,11 +11,15 @@ "id": "a870b4adb412e005", "type": "leaf", "state": { - "type": "markdown", + "type": "canvas", "state": { - "file": "Idioms.md", - "mode": "source", - "source": true + "file": "canvas.canvas", + "viewState": { + "x": 0, + "y": 0, + "zoom": 0, + "snapToGrid": false + } } } } @@ -86,7 +90,7 @@ "state": { "type": "outline", "state": { - "file": "Idioms.md" + "file": "canvas.canvas" } } }, @@ -107,7 +111,7 @@ "state": { "type": "backlink", "state": { - "file": "Idioms.md", + "file": "canvas.canvas", "collapseAll": false, "extraContext": false, "sortOrder": "alphabetical", @@ -124,7 +128,7 @@ "state": { "type": "outgoing-link", "state": { - "file": "Idioms.md", + "file": "canvas.canvas", "linksCollapsed": false, "unlinkedCollapsed": true } @@ -147,8 +151,9 @@ "workspaces:Manage workspace layouts": false } }, - "active": "a870b4adb412e005", + "active": "47f03e690283089d", "lastOpenFiles": [ + "Idioms.md", "canvas.canvas", "Digital-Tools.md", "48-Galatians/Gal.5.16-21.md", @@ -157,7 +162,6 @@ "48-Galatians/Gal.4.12-20.md", "48-Galatians/Galatians-Interlinear.md", "48-Galatians/Gal.4.8-11.md", - "48-Galatians/Gal.4.1-7.md", - "BBG4E/HW12-Key.md" + "48-Galatians/Gal.4.1-7.md" ] } \ No newline at end of file