add auto-updater and git workflow enhancements
publish / publish-tauri (, windows-latest) (release) Failing after 2m52s
publish / publish-tauri (, windows-latest) (release) Failing after 2m52s
This change introduces a comprehensive auto-update mechanism for the application and significant improvements to the integrated Git client experience. Key features include: - **Automated Release Workflow:** A new Gitea Actions workflow (`app_builder.yaml`) and a Python `cicd_tool` are added to automatically build, sign, and upload release artifacts to S3-compatible storage (MinIO) upon a new release. This also generates the `latest.json` file required by the updater. - **Tauri Updater Integration:** The `tauri-plugin-updater` is integrated into the application, enabling it to check for and apply updates seamlessly. - **Robust Git Push Handling:** The application now intelligently handles non-fast-forward push failures by prompting the user to perform a pull/merge operation before re-attempting the push. - **Enhanced File Comparison:** A new `compare_file_to_parent` command is introduced, allowing detailed file diffs against a commit's direct parent, including the "empty tree" for initial commits. - **Explorer Panel Improvements:** "Expand All" and "Collapse All" functionality is added to the file explorer for better navigation.
This commit is contained in:
@@ -31,6 +31,8 @@
|
||||
hasRepository: boolean;
|
||||
isBusy: boolean;
|
||||
onToggleFolder: (node: ExplorerNode) => void;
|
||||
onExpandAllFolders: () => void;
|
||||
onCollapseAllFolders: () => void;
|
||||
onSelectNode: (node: ExplorerNode) => void;
|
||||
}
|
||||
|
||||
@@ -42,6 +44,8 @@
|
||||
hasRepository = false,
|
||||
isBusy = false,
|
||||
onToggleFolder = () => {},
|
||||
onExpandAllFolders = () => {},
|
||||
onCollapseAllFolders = () => {},
|
||||
onSelectNode = () => {},
|
||||
}: Props = $props();
|
||||
|
||||
@@ -152,6 +156,7 @@
|
||||
|
||||
let explorerTree = $derived(buildExplorerTree(repoFiles));
|
||||
let visibleNodes = $derived(flattenExplorerTree(explorerTree, expandedExplorerPaths));
|
||||
let hasFolders = $derived(explorerTree.some((node) => node.kind === "folder"));
|
||||
</script>
|
||||
|
||||
<section class="panel grid grid-rows-[auto_1fr] overflow-hidden" aria-label="File explorer">
|
||||
@@ -160,7 +165,29 @@
|
||||
<span class="eyebrow">Explorer</span>
|
||||
<h2 class="mt-0.5 text-ink text-base font-bold leading-tight">Files</h2>
|
||||
</div>
|
||||
<span class="pill pill-count">{repoFiles.length}</span>
|
||||
<div class="explorer-head-actions">
|
||||
<button
|
||||
class="explorer-bulk-button"
|
||||
type="button"
|
||||
onclick={onExpandAllFolders}
|
||||
disabled={isBusy || !hasRepository || !hasFolders}
|
||||
title="Alle Ordner aufklappen"
|
||||
aria-label="Alle Ordner aufklappen"
|
||||
>
|
||||
<FolderOpen size={14} aria-hidden="true" />
|
||||
</button>
|
||||
<button
|
||||
class="explorer-bulk-button"
|
||||
type="button"
|
||||
onclick={onCollapseAllFolders}
|
||||
disabled={isBusy || !hasRepository || !hasFolders || expandedExplorerPaths.size === 0}
|
||||
title="Alle Ordner zuklappen"
|
||||
aria-label="Alle Ordner zuklappen"
|
||||
>
|
||||
<Folder size={14} aria-hidden="true" />
|
||||
</button>
|
||||
<span class="pill pill-count">{repoFiles.length}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{#if !hasRepository}
|
||||
|
||||
@@ -128,6 +128,15 @@ export function compareFileToHead(
|
||||
return invoke<GitCommitComparison>("compare_file_to_head", { path, commit, file });
|
||||
}
|
||||
|
||||
export function compareFileToParent(
|
||||
path: string,
|
||||
commit: string,
|
||||
file: string,
|
||||
oldFile: string | null = null,
|
||||
): Promise<GitCommitComparison> {
|
||||
return invoke<GitCommitComparison>("compare_file_to_parent", { path, commit, file, oldFile });
|
||||
}
|
||||
|
||||
export function searchCodeIntroductions(
|
||||
path: string,
|
||||
query: string,
|
||||
|
||||
Reference in New Issue
Block a user