From 50989d94911bcbe4a5b0859be5416cb353b54226 Mon Sep 17 00:00:00 2001 From: Mara Date: Sun, 25 Feb 2024 11:28:20 +0100 Subject: [PATCH 1/2] fix: error in value count in notification --- src/GitHub/upload.ts | 2 +- src/commands/index.ts | 5 +---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/GitHub/upload.ts b/src/GitHub/upload.ts index 78bffbd2..696b89a6 100644 --- a/src/GitHub/upload.ts +++ b/src/GitHub/upload.ts @@ -11,8 +11,8 @@ import { Vault, } from "obsidian"; -import { convertToHTMLSVG } from "../conversion/compiler/excalidraw"; import { mainConverting } from "../conversion"; +import { convertToHTMLSVG } from "../conversion/compiler/excalidraw"; import { getImagePath, getReceiptFolder, diff --git a/src/commands/index.ts b/src/commands/index.ts index bb122a4e..60261a53 100644 --- a/src/commands/index.ts +++ b/src/commands/index.ts @@ -37,11 +37,9 @@ export async function shareAllMarkedNotes( const statusBar = new ShareStatusBar(statusBarItems, sharedFiles.length); const repoFrontmatter = monoRepo.frontmatter; try { - let errorCount = 0; const fileError : string[] = []; const listStateUploaded: UploadedFiles[] = []; if (sharedFiles.length > 0) { - const publishedFiles = sharedFiles.map((file) => file.name); if (createGithubBranch) { const isValid = await checkRepositoryValidityWithRepoFrontmatter(PublisherManager, repoFrontmatter, sharedFiles.length); if (!isValid) return false; @@ -59,7 +57,6 @@ export async function shareAllMarkedNotes( listStateUploaded.push(...uploaded.uploaded); } } catch(e) { - errorCount++; fileError.push(sharedFile.name); new Notice( (i18next.t("error.unablePublishNote", {file: sharedFile.name}))); @@ -67,7 +64,7 @@ export async function shareAllMarkedNotes( } } statusBar.finish(8000); - const noticeValue = `${publishedFiles.length - errorCount} notes`; + const noticeValue = `${listStateUploaded.length} notes`; const deleted = await deleteFromGithub( true, branchName, From ecf0b79af77d52abc4ab3866f69f55c2671a63b0 Mon Sep 17 00:00:00 2001 From: Mara Date: Sun, 25 Feb 2024 11:28:27 +0100 Subject: [PATCH 2/2] chore(release): 6.16.0-3 --- CHANGELOG-beta.md | 7 +++++++ manifest-beta.json | 2 +- package-lock.json | 4 ++-- package.json | 2 +- 4 files changed, 11 insertions(+), 4 deletions(-) diff --git a/CHANGELOG-beta.md b/CHANGELOG-beta.md index 245d6c43..364922fd 100644 --- a/CHANGELOG-beta.md +++ b/CHANGELOG-beta.md @@ -2,6 +2,13 @@ All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines. +## [6.16.0-3](https://github.com/obsidianMkdocs/obsidian-github-publisher/compare/6.16.0-2...6.16.0-3) (2024-02-25) + + +### Bug Fixes + +* error in value count in notification ([50989d9](https://github.com/obsidianMkdocs/obsidian-github-publisher/commit/50989d94911bcbe4a5b0859be5416cb353b54226)) + ## [6.16.0-2](https://github.com/obsidianMkdocs/obsidian-github-publisher/compare/6.16.0-1...6.16.0-2) (2024-02-24) diff --git a/manifest-beta.json b/manifest-beta.json index 8e8ed7bf..c6040209 100644 --- a/manifest-beta.json +++ b/manifest-beta.json @@ -1,7 +1,7 @@ { "id": "obsidian-mkdocs-publisher", "name": "Github Publisher", - "version": "6.16.0-2", + "version": "6.16.0-3", "minAppVersion": "0.15.4", "description": "Github Publisher helps you to publish your notes on a preconfigured GitHub repository, for free, and more!", "author": "Mara-Li", diff --git a/package-lock.json b/package-lock.json index 705df8ba..8cef25ca 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "obsidian-github-publisher", - "version": "6.16.0-2", + "version": "6.16.0-3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "obsidian-github-publisher", - "version": "6.16.0-2", + "version": "6.16.0-3", "license": "AGPL-3.0", "dependencies": { "@excalidraw/utils": "^0.1.2", diff --git a/package.json b/package.json index 901034c4..c17ac54e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "obsidian-github-publisher", - "version": "6.16.0-2", + "version": "6.16.0-3", "description": "Github Publisher is a plugin that help you to send file in a configured Github Repository, based on a frontmatter entry state.", "main": "main.js", "scripts": {