diff --git a/.gitignore b/.gitignore index c7b0519d35..2bf60fec8c 100644 --- a/.gitignore +++ b/.gitignore @@ -6,6 +6,7 @@ *.user *.suo *.code-workspace +*.tss .DS_Store .DocumentRevisions-V100 diff --git a/CHANGELOG.md b/CHANGELOG.md index 0e01feae04..442080943f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,12 @@ Fork releases of SourceGit-SK. Upstream changes arrive through upstream release merges and are documented in the [upstream release notes](https://github.com/sourcegit-scm/sourcegit/releases). +## [2026.17-sk] - 2026-07-24 + +### Changed + +- Merged upstream [v2026.15](https://github.com/sourcegit-scm/sourcegit/releases/tag/v2026.15) into the fork, bringing upstream's fixes and improvements while keeping all fork customizations ([#9](https://github.com/skoonin/sourcegit-sk/pull/9)) + ## [2026.16-sk] - 2026-07-12 ### Added @@ -32,5 +38,6 @@ First fork release, based on upstream [v2026.14](https://github.com/sourcegit-sc - Version numbers carry an `-sk` suffix (shown in the About dialog) to distinguish fork releases from upstream builds. - The update check and release links point at this fork's releases instead of upstream's, so new `-sk` releases are detected and offered ([#2](https://github.com/skoonin/sourcegit-sk/pull/2)) +[2026.17-sk]: https://github.com/skoonin/sourcegit-sk/releases/tag/v2026.17-sk [2026.16-sk]: https://github.com/skoonin/sourcegit-sk/releases/tag/v2026.16-sk [2026.15-sk]: https://github.com/skoonin/sourcegit-sk/releases/tag/v2026.15-sk diff --git a/Makefile b/Makefile index 3abcaaf7f4..cc1b846d9a 100644 --- a/Makefile +++ b/Makefile @@ -2,6 +2,10 @@ # GitHub Actions are disabled in this repository; `make check` is the local CI gate. DOTNET ?= $(shell command -v dotnet 2>/dev/null || echo $(HOME)/.local/share/dotnet/dotnet) +# Avalonia's build-time stats task writes to ~/Library/Application Support/AvaloniaUI; +# that write fails in restricted/sandboxed environments and breaks the build. Opt out to +# keep builds hermetic. Only affects build telemetry, not the app. +export AVALONIA_TELEMETRY_OPTOUT := true # Lazy so only the app target shells out for the version. VERSION = $(shell cat VERSION) RUNTIME ?= osx-arm64 diff --git a/README.md b/README.md index 2bf6c6968b..bf68518fa3 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,16 @@ [![latest](https://img.shields.io/github/v/release/sourcegit-scm/sourcegit.svg)](https://github.com/sourcegit-scm/sourcegit/releases/latest) [![downloads](https://img.shields.io/github/downloads/sourcegit-scm/sourcegit/total)](https://github.com/sourcegit-scm/sourcegit/releases) +## Fork customizations (SourceGit-SK) + +This is a personal fork of [sourcegit-scm/sourcegit](https://github.com/sourcegit-scm/sourcegit) that tracks upstream and adds the changes below. These are specific to this fork and are not part of upstream SourceGit. See [CHANGELOG.md](CHANGELOG.md) for the full history. + +* **Stacked multi-file diff** across every change view (working copy, commit details, compare, revision compare, submodule compare, stashes): with no file selected the whole change set shows as one scrollable diff; selecting several files stacks those; selecting one shows a single file. Includes a shared toolbar, file navigation, and per-file context controls. +* **Recent-commits block in the repository sidebar**, showing the full commit graph. +* **Bracket tab switching**: Cmd+Shift+[ / Cmd+Shift+] on macOS (Ctrl+Shift on Windows/Linux) moves between tabs; the existing bindings still work. +* **"Open Another Repository..."** entry in the repository switcher (Ctrl/Cmd+P) opens a folder picker for a repo not yet in the list. +* **Fork versioning**: releases carry an `-sk` suffix (shown in the About dialog), and the update check points at this fork's releases instead of upstream's. + ## Screenshots * Dark Theme diff --git a/TRANSLATION.md b/TRANSLATION.md index 495092dc97..2184710c8c 100644 --- a/TRANSLATION.md +++ b/TRANSLATION.md @@ -125,60 +125,28 @@ This document shows the translation status of each locale file in the repository -### ![el__GR](https://img.shields.io/badge/el__GR-96.20%25-yellow) +### ![el__GR](https://img.shields.io/badge/el__GR-99.12%25-yellow)
Missing keys in el_GR.axaml -- Text.Apply.Source -- Text.Apply.Source.File -- Text.Apply.Source.Clipboard -- Text.Bisect.WaitingForCheckoutAnother -- Text.Bisect.WaitingForFirstBad -- Text.CheckoutDetached -- Text.CheckoutDetached.Target -- Text.CheckoutDetached.Warning -- Text.Configure.Git.EnableRecursiveWhenAutoUpdatingSubmodules -- Text.CopyAsPatch -- Text.DeleteBranch.AskForRemote -- Text.DeleteBranch.Force - Text.Diff.AndMoreFiles -- Text.Diff.EmptyFile - Text.Diff.FilesCount - Text.Diff.FirstFile - Text.Diff.LargeDiffHint - Text.Diff.LastFile - Text.Diff.NextFile - Text.Diff.PrevFile -- Text.FileModeChange -- Text.FileModeChange.Deleted -- Text.FileModeChange.Directory -- Text.FileModeChange.Executable -- Text.FileModeChange.New -- Text.FileModeChange.Normal -- Text.FileModeChange.Submodule -- Text.FileModeChange.Symlink -- Text.FileModeChange.Unknown -- Text.GitFlow.Finish -- Text.GitFlow.FinishWithRebase -- Text.GitFlow.StartAt -- Text.GitFlow.StartName - Text.Launcher.OpenOtherRepository - Text.Repository.Commits -- Text.TagCM.Checkout -- Text.TagCM.Merge -- Text.UpdateSubmodules.Recursive -- Text.WorkingCopy.AddToGitIgnore.UntrackedInSameFolder
-### ![es__ES](https://img.shields.io/badge/es__ES-97.96%25-yellow) +### ![es__ES](https://img.shields.io/badge/es__ES-99.12%25-yellow)
Missing keys in es_ES.axaml -- Text.DeleteBranch.AskForRemote -- Text.DeleteBranch.Force - Text.Diff.AndMoreFiles - Text.Diff.FilesCount - Text.Diff.FirstFile @@ -186,18 +154,8 @@ This document shows the translation status of each locale file in the repository - Text.Diff.LastFile - Text.Diff.NextFile - Text.Diff.PrevFile -- Text.FileModeChange -- Text.FileModeChange.Deleted -- Text.FileModeChange.Directory -- Text.FileModeChange.Executable -- Text.FileModeChange.New -- Text.FileModeChange.Normal -- Text.FileModeChange.Submodule -- Text.FileModeChange.Symlink -- Text.FileModeChange.Unknown - Text.Launcher.OpenOtherRepository - Text.Repository.Commits -- Text.WorkingCopy.AddToGitIgnore.UntrackedInSameFolder
@@ -1086,13 +1044,11 @@ This document shows the translation status of each locale file in the repository -### ![ru__RU](https://img.shields.io/badge/ru__RU-97.96%25-yellow) +### ![ru__RU](https://img.shields.io/badge/ru__RU-99.12%25-yellow)
Missing keys in ru_RU.axaml -- Text.DeleteBranch.AskForRemote -- Text.DeleteBranch.Force - Text.Diff.AndMoreFiles - Text.Diff.FilesCount - Text.Diff.FirstFile @@ -1100,18 +1056,8 @@ This document shows the translation status of each locale file in the repository - Text.Diff.LastFile - Text.Diff.NextFile - Text.Diff.PrevFile -- Text.FileModeChange -- Text.FileModeChange.Deleted -- Text.FileModeChange.Directory -- Text.FileModeChange.Executable -- Text.FileModeChange.New -- Text.FileModeChange.Normal -- Text.FileModeChange.Submodule -- Text.FileModeChange.Symlink -- Text.FileModeChange.Unknown - Text.Launcher.OpenOtherRepository - Text.Repository.Commits -- Text.WorkingCopy.AddToGitIgnore.UntrackedInSameFolder
@@ -1857,12 +1803,11 @@ This document shows the translation status of each locale file in the repository -### ![zh__CN](https://img.shields.io/badge/zh__CN-99.03%25-yellow) +### ![zh__CN](https://img.shields.io/badge/zh__CN-99.12%25-yellow)
Missing keys in zh_CN.axaml -- Text.DeleteBranch.AskForRemote - Text.Diff.AndMoreFiles - Text.Diff.FilesCount - Text.Diff.FirstFile @@ -1875,12 +1820,11 @@ This document shows the translation status of each locale file in the repository
-### ![zh__TW](https://img.shields.io/badge/zh__TW-99.03%25-yellow) +### ![zh__TW](https://img.shields.io/badge/zh__TW-99.12%25-yellow)
Missing keys in zh_TW.axaml -- Text.DeleteBranch.AskForRemote - Text.Diff.AndMoreFiles - Text.Diff.FilesCount - Text.Diff.FirstFile diff --git a/VERSION b/VERSION index 0344429986..06ff1862b9 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2026.16-sk \ No newline at end of file +2026.17-sk diff --git a/depends/AvaloniaEdit b/depends/AvaloniaEdit index 3451f4e0bd..11bf2b6a82 160000 --- a/depends/AvaloniaEdit +++ b/depends/AvaloniaEdit @@ -1 +1 @@ -Subproject commit 3451f4e0bdfaf05d927446f63cde8359a5e79eca +Subproject commit 11bf2b6a8265329974606604ecc96ece8bfbc0b9 diff --git a/src/App.Extensions.cs b/src/App.Extensions.cs index 7c2d0195a0..e6d8add253 100644 --- a/src/App.Extensions.cs +++ b/src/App.Extensions.cs @@ -18,6 +18,18 @@ public static string Escaped(this string value) return value.Replace("\"", "\\\"", StringComparison.Ordinal); } + public static string EscapeForBRE(this string value) + { + return value + .Replace("\\", "\\\\", StringComparison.Ordinal) + .Replace(".", "\\.", StringComparison.Ordinal) + .Replace("[", "\\[", StringComparison.Ordinal) + .Replace("*", "\\*", StringComparison.Ordinal) + .Replace("^", "\\^", StringComparison.Ordinal) + .Replace("$", "\\$", StringComparison.Ordinal) + .Replace("{", "\\{", StringComparison.Ordinal); + } + public static string FormatFontNames(string input) { if (string.IsNullOrEmpty(input)) diff --git a/src/Commands/Diff.cs b/src/Commands/Diff.cs index ecfb24c42d..6edeff5407 100644 --- a/src/Commands/Diff.cs +++ b/src/Commands/Diff.cs @@ -33,6 +33,7 @@ public partial class Diff : Command private const string SPECIAL_DIFF_START = "diff "; private const string SPECIAL_BINARY = "Binary files "; private const string SPECIAL_NO_NEWLINE = " No newline at end of file"; + private const string SPECIAL_SUBMODULE = "Subproject commit "; public Diff(string repo, Models.DiffOption opt, int numContextLines, bool ignoreWhitespace, bool ignoreCRAtEOL) { @@ -92,7 +93,7 @@ public Diff(string repo, Models.DiffOption opt, int numContextLines, bool ignore // Ignore exceptions. } - if (_result.IsBinary || _result.IsLFS || _result.TextDiff.Lines.Count == 0) + if (_isLFS || _result.IsBinary || _result.TextDiff.Lines.Count == 0) { _result.TextDiff = null; } @@ -104,6 +105,28 @@ public Diff(string repo, Models.DiffOption opt, int numContextLines, bool ignore _isInChunk = false; } + if (_result.TextDiff.Lines.Count < 4) + { + var isSubmoduleChange = true; + + for (int i = 1; i < _result.TextDiff.Lines.Count; i++) + { + var line = _result.TextDiff.Lines[i]; + if (!line.Content.StartsWith(SPECIAL_SUBMODULE, StringComparison.Ordinal)) + { + isSubmoduleChange = false; + break; + } + } + + if (isSubmoduleChange) + { + _result.IsSubmoduleChange = true; + _result.TextDiff = null; + return _result; + } + } + _result.TextDiff.MaxLineNumber = Math.Max(_newLine, _oldLine); _result.TextDiff.OldMode = _result.OldMode; _result.TextDiff.NewMode = _result.NewMode; @@ -254,7 +277,7 @@ private bool ParseFileModeChange(string line) private bool ParseLFSChange(char prefix, string content) { - if (_result.IsLFS) + if (_isLFS) { if (prefix == PREFIX_DELETED) { @@ -284,7 +307,7 @@ private bool ParseLFSChange(char prefix, string content) { if (content.StartsWith(LFS_SPECIFIER, StringComparison.Ordinal)) { - _result.IsLFS = true; + _isLFS = true; _result.LFSDiff = new Models.LFSDiff(); return true; } @@ -340,5 +363,6 @@ private void ProcessInlineHighlights() private int _oldLine = 0; private int _newLine = 0; private bool _isInChunk = false; + private bool _isLFS = false; } } diff --git a/src/Commands/InteractiveRebase.cs b/src/Commands/InteractiveRebase.cs index f3c84c3d6c..6b61b9d2ab 100644 --- a/src/Commands/InteractiveRebase.cs +++ b/src/Commands/InteractiveRebase.cs @@ -11,7 +11,7 @@ public InteractiveRebase(string repo, string basedOn, bool autoStash, bool noVer Editor = EditorType.RebaseEditor; var builder = new StringBuilder(512); - builder.Append("-c core.commentChar=± rebase -i --autosquash "); + builder.Append("-c core.commentChar=\"^\" -c core.commentString=\"±\" rebase -i --autosquash "); if (autoStash) builder.Append("--autostash "); if (noVerify) diff --git a/src/Commands/QuerySubmoduleRevision.cs b/src/Commands/QuerySubmoduleRevision.cs new file mode 100644 index 0000000000..a70f1efb68 --- /dev/null +++ b/src/Commands/QuerySubmoduleRevision.cs @@ -0,0 +1,67 @@ +using System; +using System.Threading.Tasks; + +namespace SourceGit.Commands +{ + public class QuerySubmoduleRevision : Command + { + public QuerySubmoduleRevision(string repo, string revision) + { + WorkingDirectory = repo; + Context = repo; + + if (revision.EndsWith("-dirty", StringComparison.Ordinal)) + { + _hasUncommittedChange = true; + _revision = revision.Substring(0, revision.Length - 6); + } + else + { + _hasUncommittedChange = false; + _revision = revision; + } + } + + public async Task GetResultAsync() + { + Args = $"show --no-show-signature --decorate=full --format=%H%x00%P%x00%D%x00%aN±%aE%x00%at%x00%cN±%cE%x00%ct%x00%s%x00%B -s {_revision}"; + + var rs = await ReadToEndAsync().ConfigureAwait(false); + if (!rs.IsSuccess || string.IsNullOrEmpty(rs.StdOut)) + return null; + + var commit = new Models.Commit(); + var lines = rs.StdOut.Split('\0'); + if (lines.Length < 9) + return null; + + commit.SHA = lines[0]; + if (!string.IsNullOrEmpty(lines[1])) + commit.Parents.AddRange(lines[1].Split(' ', StringSplitOptions.RemoveEmptyEntries)); + if (!string.IsNullOrEmpty(lines[2])) + commit.ParseDecorators(lines[2]); + commit.Author = Models.User.FindOrAdd(lines[3]); + commit.AuthorTime = ulong.Parse(lines[4]); + commit.Committer = Models.User.FindOrAdd(lines[5]); + commit.CommitterTime = ulong.Parse(lines[6]); + commit.Subject = lines[7]; + + var message = new Models.CommitFullMessage() { Message = lines[8].TrimEnd() }; + var uncommittedChangesCount = 0; + if (_hasUncommittedChange) + uncommittedChangesCount = await new CountLocalChanges(WorkingDirectory, true) + .GetResultAsync() + .ConfigureAwait(false); + + return new Models.RevisionSubmodule() + { + Commit = commit, + FullMessage = message, + UncommittedChanges = uncommittedChangesCount + }; + } + + private bool _hasUncommittedChange = false; + private string _revision = string.Empty; + } +} diff --git a/src/Commands/Rebase.cs b/src/Commands/Rebase.cs index 33b45413b2..fdc585c019 100644 --- a/src/Commands/Rebase.cs +++ b/src/Commands/Rebase.cs @@ -10,7 +10,7 @@ public Rebase(string repo, string basedOn, bool autoStash, bool noVerify) Context = repo; var builder = new StringBuilder(512); - builder.Append("-c core.commentChar=± rebase "); + builder.Append("-c core.commentChar=\"^\" -c core.commentString=\"±\" rebase "); if (autoStash) builder.Append("--autostash "); if (noVerify) diff --git a/src/Models/DiffResult.cs b/src/Models/DiffResult.cs index d1564cce36..ddb3d7e07a 100644 --- a/src/Models/DiffResult.cs +++ b/src/Models/DiffResult.cs @@ -101,7 +101,7 @@ public class SubmoduleDiff public class DiffResult { public bool IsBinary { get; set; } = false; - public bool IsLFS { get; set; } = false; + public bool IsSubmoduleChange { get; set; } = false; public string OldHash { get; set; } = string.Empty; public string NewHash { get; set; } = string.Empty; public int OldMode { get; set; } = 0; diff --git a/src/Models/RepositorySettings.cs b/src/Models/RepositorySettings.cs index fdad5a9903..506e6ded78 100644 --- a/src/Models/RepositorySettings.cs +++ b/src/Models/RepositorySettings.cs @@ -54,12 +54,6 @@ public AvaloniaList CommitTemplates set; } = []; - public AvaloniaList CommitMessages - { - get; - set; - } = []; - public AvaloniaList CustomActions { get; @@ -122,25 +116,6 @@ public void Save() } } - public void PushCommitMessage(string message) - { - message = message.Trim().ReplaceLineEndings("\n"); - var existIdx = CommitMessages.IndexOf(message); - if (existIdx == 0) - return; - - if (existIdx > 0) - { - CommitMessages.Move(existIdx, 0); - return; - } - - if (CommitMessages.Count > 9) - CommitMessages.RemoveRange(9, CommitMessages.Count - 9); - - CommitMessages.Insert(0, message); - } - public CustomAction AddNewCustomAction() { var act = new CustomAction() { Name = "Unnamed Action" }; diff --git a/src/Models/RepositoryUIStates.cs b/src/Models/RepositoryUIStates.cs index a05bedd147..1603219629 100644 --- a/src/Models/RepositoryUIStates.cs +++ b/src/Models/RepositoryUIStates.cs @@ -237,6 +237,12 @@ public AvaloniaList HistoryFilters set; } = []; + public List RecentCommitMessages + { + get; + set; + } = []; + public static RepositoryUIStates Load(string gitDir) { var fileInfo = new FileInfo(Path.Combine(gitDir, "sourcegit.uistates")); @@ -483,6 +489,26 @@ private void BuildHistoryParamsForExcluded(StringBuilder builder, string gitDir) builder.Append("--tags "); } + public void AddRecentCommitMessage(string message) + { + message = message.Trim().ReplaceLineEndings("\n"); + var existIdx = RecentCommitMessages.IndexOf(message); + if (existIdx == 0) + return; + + if (existIdx > 0) + { + RecentCommitMessages.RemoveAt(existIdx); + RecentCommitMessages.Insert(0, message); + return; + } + + if (RecentCommitMessages.Count > 9) + RecentCommitMessages.RemoveRange(9, RecentCommitMessages.Count - 9); + + RecentCommitMessages.Insert(0, message); + } + private string _file = string.Empty; } } diff --git a/src/Models/Statistics.cs b/src/Models/Statistics.cs index 3ecee89e0e..4ef9927fc5 100644 --- a/src/Models/Statistics.cs +++ b/src/Models/Statistics.cs @@ -42,11 +42,14 @@ public StatisticsSamples(StatisticsMode mode, DateTime start, DateTime end, Dict else MaxValue = (int)(Math.Floor(maxValue / 6.0) * 8.0); - Count = mode switch - { - StatisticsMode.All => (end.Year - start.Year) * 12 + (end.Month - start.Month) + 1, - _ => all.Count, - }; + if (maxValue == 0) + Count = 0; + else + Count = mode switch + { + StatisticsMode.All => (end.Year - start.Year) * 12 + (end.Month - start.Month) + 1, + _ => all.Count, + }; } public void WithUser(Dictionary user) diff --git a/src/Resources/Locales/el_GR.axaml b/src/Resources/Locales/el_GR.axaml index 7f1da3c39d..0b537616e3 100644 --- a/src/Resources/Locales/el_GR.axaml +++ b/src/Resources/Locales/el_GR.axaml @@ -32,6 +32,9 @@ Τριμερής συγχώνευση (3-Way) Επιλέξτε αρχείο .patch για εφαρμογή Αγνόηση αλλαγών κενών χαρακτήρων + Πηγή: + Αρχείο + Πρόχειρο Εφαρμογή Patch Κενά: Εφαρμογή Stash @@ -55,6 +58,8 @@ Κακό Καλό Παράλειψη + Εκτέλεση bisect. Κάντε checkout σε άλλο και μετά σημειώστε το ως καλό ή κακό. + Εκτέλεση bisect. Σημειώστε το τρέχον commit ως κακό ή κάντε checkout σε άλλο και μετά σημειώστε το ως κακό. Εκτέλεση bisect. Σημειώστε το τρέχον commit ως καλό ή κακό και κάντε checkout σε άλλο. Εκτέλεση bisect. Το τρέχον HEAD είναι καλό ή κακό; Blame @@ -120,6 +125,9 @@ Checkout κλάδου από Stash Νέος κλάδος: Stash: + Checkout commit ή ετικέτας + Στόχος: + Προσοχή: Μετά από αυτό, το HEAD θα αποσυνδεθεί (detached) Cherry-Pick Προσθήκη πηγής στο μήνυμα commit Commit: @@ -248,6 +256,7 @@ Λεπτό(-ά) Τύποι Conventional Commit Προεπιλεγμένο απομακρυσμένο + Ενεργοποίηση `--recursive` κατά την αυτόματη ενημέρωση υπομονάδων Προτιμώμενος τρόπος συγχώνευσης ΣΥΣΤΗΜΑ ΠΑΡΑΚΟΛΟΥΘΗΣΗΣ ΖΗΤΗΜΑΤΩΝ Προσθήκη κανόνα Azure DevOps @@ -305,6 +314,7 @@ Τύπος αλλαγής: Αντιγραφή Αντιγραφή όλου του κειμένου + Αντιγραφή ως Patch Αντιγραφή πλήρους διαδρομής Αντιγραφή διαδρομής Δημιουργία κλάδου... @@ -336,7 +346,9 @@ Εξαναγκασμός απο-αρχικοποίησης ακόμη κι αν περιέχει τοπικές αλλαγές. Υπομονάδα: Διαγραφή κλάδου + Θέλετε να διαγράψετε και τον ακόλουθο απομακρυσμένο κλάδο; Κλάδος: + Εξαναγκασμένη διαγραφή ακόμη κι αν περιέχει μη συγχωνευμένα commit Πρόκειται να διαγράψετε έναν απομακρυσμένο κλάδο!!! Διαγραφή πολλαπλών κλάδων Προσπαθείτε να διαγράψετε πολλούς κλάδους ταυτόχρονα. Βεβαιωθείτε ότι ελέγξατε ξανά πριν προχωρήσετε! @@ -357,6 +369,7 @@ Ετικέτα: Διαγραφή από τα απομακρυσμένα αποθετήρια ΔΥΑΔΙΚΟ DIFF + ΚΕΝΟ ΑΡΧΕΙΟ Πρώτη διαφορά Αγνόηση αλλαγών κενών χαρακτήρων ΑΝΑΜΕΙΞΗ @@ -429,14 +442,25 @@ Ιστορικό αρχείου ΑΛΛΑΓΗ ΠΕΡΙΕΧΟΜΕΝΟ + Αλλαγή mode αρχείου: + mode διαγραμμένου αρχείου: + Κατάλογος + Εκτελέσιμο + mode νέου αρχείου: + Κανονικό + Υπομονάδα + Συμβολικός σύνδεσμος + Άγνωστο Git-Flow Κλάδος ανάπτυξης: Feature: Πρόθεμα Feature: + Ολοκλήρωση ${0}$ FLOW - Ολοκλήρωση Feature FLOW - Ολοκλήρωση Hotfix FLOW - Ολοκλήρωση Release Στόχος: + Rebase πριν τη συγχώνευση Squash κατά τη συγχώνευση Hotfix: Πρόθεμα Hotfix: @@ -445,10 +469,12 @@ Κλάδος παραγωγής: Release: Πρόθεμα Release: + Έναρξη στο: Έναρξη Feature... FLOW - Έναρξη Feature Έναρξη Hotfix... FLOW - Έναρξη Hotfix + Όνομα: Εισαγάγετε όνομα Έναρξη Release... FLOW - Έναρξη Release @@ -921,6 +947,7 @@ ΟΚ ΔΗΜΙΟΥΡΓΟΣ ΕΤΙΚΕΤΑΣ ΩΡΑ + Checkout ετικέτας... Σύγκριση 2 ετικετών Σύγκριση με... Σύγκριση με το HEAD @@ -931,11 +958,13 @@ Προσαρμοσμένη ενέργεια Διαγραφή ${0}$... Διαγραφή {0} επιλεγμένων ετικετών... + Συγχώνευση ${0}$ στο ${1}$... Push ${0}$... Ενημέρωση υπομονάδων Όλες οι υπομονάδες Αρχικοποίηση όπου χρειάζεται Υπομονάδα: + Ενημέρωση ένθετων υπομονάδων Ενημέρωση στον απομακρυσμένο κλάδο παρακολούθησης της υπομονάδας URL: Καταγραφές @@ -962,6 +991,7 @@ Αγνόηση αρχείων *{0} στον ίδιο φάκελο Αγνόηση μη παρακολουθούμενων αρχείων σε αυτόν τον φάκελο Αγνόηση μόνο αυτού του αρχείου + Αγνόηση όλων των μη παρακολουθούμενων αρχείων στον ίδιο φάκελο Τροποποίηση Μπορείτε να προσθέσετε αυτό το αρχείο στο ευρετήριο τώρα. Εκκαθάριση ιστορικού diff --git a/src/Resources/Locales/en_US.axaml b/src/Resources/Locales/en_US.axaml index ef68a67095..37d6733085 100644 --- a/src/Resources/Locales/en_US.axaml +++ b/src/Resources/Locales/en_US.axaml @@ -210,8 +210,8 @@ Tips: You can cherry-pick selected commits if the other side is HEAD (using context menu). Repository Configure COMMIT TEMPLATE - Built-in parameters: - + Built-in parameters: + ${branch_name} Current local branch name. ${files_num} Number of changed files ${files} Paths of changed files @@ -222,8 +222,8 @@ Template Name: CUSTOM ACTION Arguments: - Built-in parameters: - + Built-in parameters: + ${REPO} Repository's path ${REMOTE} Selected remote or selected branch's remote ${BRANCH} Selected branch, without ${REMOTE} part for remote branches @@ -533,7 +533,7 @@ Revision Compare Keyboard Shortcuts Reference GLOBAL - Clone new repository + Clone remote repository Close current tab Go to next tab Go to previous tab diff --git a/src/Resources/Locales/es_ES.axaml b/src/Resources/Locales/es_ES.axaml index e59e25e6ad..5f374f0934 100644 --- a/src/Resources/Locales/es_ES.axaml +++ b/src/Resources/Locales/es_ES.axaml @@ -346,7 +346,9 @@ Forzar desinicialización incluso si contiene cambios locales. Submódulo: Eliminar Rama + ¿Quieres que también se elimine la siguiente rama remota? Rama: + Forzar la eliminación incluso si contiene commit(s) sin fusionar ¡Estás a punto de eliminar una rama remota! Eliminar Múltiples Ramas Estás intentando eliminar múltiples ramas a la vez. ¡Asegúrate de comprobar dos veces antes de realizar esta acción! @@ -405,7 +407,7 @@ Cambios: Incluir archivos ignorados Incluir archivos modificados/eliminados - Incluir archivos no rastreados + Incluir archivos sin rastrear Total {0} cambios serán descartados ¡No puedes deshacer esta acción! Editar la descripción de la rama @@ -440,6 +442,15 @@ Historial de Archivos CAMBIO CONTENIDO + Cambiar modo archivo: + Modo archivo eliminado: + Directorio + Ejecutable + Modo archivo nuevo: + Normal + Submódulo + Enlace simbólico (Symlink) + Desconocido Git-Flow Rama de Desarrollo: Feature: @@ -885,7 +896,7 @@ Ruta de almacenamiento de la clave privada SSH INICIAR Stash - Incluir archivos no rastreados + Incluir archivos sin rastrear Mensaje: Opcional. Información de este stash Modo: @@ -978,8 +989,9 @@ Git Ignore Ignorar todos los archivos *{0} Ignorar archivos *{0} en la misma carpeta - Ignorar archivos no rastreados en esta carpeta + Ignorar archivos sin rastrear en esta carpeta Ignorar solo este archivo + Ignorar todos los archivos sin rastrear en la misma carpeta Enmendar Puedes hacer stage a este archivo ahora. Limpiar Historial @@ -999,7 +1011,7 @@ LOS CONFLICTOS DE ARCHIVOS ESTÁN RESUELTOS USAR MÍOS USAR SUYOS - INCLUIR ARCHIVOS NO RASTREADOS + INCLUIR ARCHIVOS SIN RASTREAR NO HAY MENSAJES DE ENTRADA RECIENTES NO HAY PLANTILLAS DE COMMIT Sin verificar diff --git a/src/Resources/Locales/fr_FR.axaml b/src/Resources/Locales/fr_FR.axaml index e68c729548..8227387c90 100644 --- a/src/Resources/Locales/fr_FR.axaml +++ b/src/Resources/Locales/fr_FR.axaml @@ -204,8 +204,8 @@ Astuce : vous pouvez cherry-pick les commits sélectionnés si l'autre côté est HEAD (via le menu contextuel). Configurer le dépôt MODÈLE DE COMMIT - Paramètres intégrés : - + Paramètres intégrés : + ${branch_name} Nom de la branche locale actuelle. ${files_num} Nombre de fichiers modifiés ${files} Chemins des fichiers modifiés @@ -216,8 +216,8 @@ Nom de modèle: ACTION PERSONNALISÉE Arguments : - Paramètres intégrés : - + Paramètres intégrés : + ${REPO} Chemin du dépôt ${REMOTE} Dépôt distant sélectionné ou dépôt distant de la branche sélectionnée ${BRANCH} Branche sélectionnée, sans la partie ${REMOTE} pour les branches distantes diff --git a/src/Resources/Locales/id_ID.axaml b/src/Resources/Locales/id_ID.axaml index 75bd5ccf7a..e5bf64e6e6 100644 --- a/src/Resources/Locales/id_ID.axaml +++ b/src/Resources/Locales/id_ID.axaml @@ -173,8 +173,8 @@ Nama Template: AKSI KUSTOM Argumen: - Parameter bawaan: - + Parameter bawaan: + ${REPO} Jalur repositori ${REMOTE} Remote yang dipilih atau remote dari branch yang dipilih ${BRANCH} Branch yang dipilih, tanpa bagian ${REMOTE} untuk remote branch diff --git a/src/Resources/Locales/it_IT.axaml b/src/Resources/Locales/it_IT.axaml index b18b821e6f..13122e41ce 100644 --- a/src/Resources/Locales/it_IT.axaml +++ b/src/Resources/Locales/it_IT.axaml @@ -196,7 +196,7 @@ ${pure_files:N} Come ${files:N}, ma senza cartelle AZIONE PERSONALIZZATA Argomenti: Parametri integrati: - + ${REPO} Percorso del repository ${REMOTE} Remoto selezionato o remoto del branch selezionato ${BRANCH} Branch selezionato, senza la parte ${REMOTE} per i branch remoti diff --git a/src/Resources/Locales/ru_RU.axaml b/src/Resources/Locales/ru_RU.axaml index 9bf74e96e8..ee438ac492 100644 --- a/src/Resources/Locales/ru_RU.axaml +++ b/src/Resources/Locales/ru_RU.axaml @@ -214,8 +214,8 @@ Подсказка: Если другая сторона является ГОЛОВОЙ (используя контекстное меню), вы можете использовать частично выбранные ревизии (cherry-pick). Настройка репозитория ШАБЛОН РЕВИЗИИ - Встроенные параметры: - + Встроенные параметры: + ${branch_name} Имя текущей локальной ветки ${files_num} Количество изменённых файлов ${files} Пути изменённых файлов @@ -226,8 +226,8 @@ Название: ПОЛЬЗОВАТЕЛЬСКОЕ ДЕЙСТВИЕ Аргументы: - Встроенные параметры: - + Встроенные параметры: + ${REPO} Путь репозитория ${REMOTE} Выбранная удаённая ветка ${BRANCH} Выбранная ветка, без ${REMOTE} удалённых веток @@ -346,7 +346,9 @@ Принудительно удалить даже если содержит локальные изменения. Подмодуль: Удалить ветку + Вы хотите также удалить следующую удалённую ветку? Ветка: + Принудительно удалить, даже если содержит неслитые ревизии Вы собираетесь удалить внешнюю ветку!!! Удаление нескольких веток Вы пытаетесь удалить несколько веток одновременно. Обязательно перепроверьте, прежде чем предпринимать какие-либо действия! @@ -440,6 +442,15 @@ История файлов ИЗМЕНИТЬ СОДЕРЖИМОЕ + Изменение режима файла: + Режим удалённого файла: + Каталог + Исполняемый + Новый режим файла: + Обычный + Подмодуль + Символическая сскла + Неизвестно Git-процесс Ветка разработчика: Свойство: @@ -980,6 +991,7 @@ Игнорировать *{0} файлы в том же каталоге Игнорировать неотслеживаемые файлы в этом каталоге Игнорировать только эти файлы + Игнорировать все неотслеживаемые файлы в одном и том же каталоге Изменить Теперь вы можете сформировать этот файл. Очистить историю diff --git a/src/Resources/Locales/zh_CN.axaml b/src/Resources/Locales/zh_CN.axaml index 36b5f21eca..cf27832e7b 100644 --- a/src/Resources/Locales/zh_CN.axaml +++ b/src/Resources/Locales/zh_CN.axaml @@ -215,7 +215,7 @@ 仓库配置 提交信息模板 内置变量: - + ${branch_name} 当前分支名 ${files_num} 变更文件数量 ${files} 变更文件路径列表 @@ -227,7 +227,7 @@ 自定义操作 命令行参数 : 内置变量: - + ${REPO} 仓库路径 ${REMOTE} 选中的远程仓库或选中分支所属的远程仓库 ${BRANCH} 选中的分支,对于远程分支不包含远程名 @@ -346,6 +346,7 @@ 强制取消,即使包含本地变更 子模块 : 删除分支确认 + 是否同时删除以下远程分支? 分支名 : 强制删除,即使包含未合并的提交 您正在删除远程上的分支,请务必小心!!! diff --git a/src/Resources/Locales/zh_TW.axaml b/src/Resources/Locales/zh_TW.axaml index 6a238a5ea4..fcf0003dd3 100644 --- a/src/Resources/Locales/zh_TW.axaml +++ b/src/Resources/Locales/zh_TW.axaml @@ -61,7 +61,7 @@ 二分搜尋進行中。請簽出另一個提交,然後標記該提交為「良好」或「錯誤」。 二分搜尋進行中。請標記目前的提交為「錯誤」,或簽出另一個提交並標記為「錯誤」。 二分搜尋進行中。請標記目前的提交為「良好」或「錯誤」,然後簽出另一個提交。 - 二分搜尋進行中。目前的提交是「良好」是「錯誤」? + 二分搜尋進行中。目前的提交是「良好」還是「錯誤」? 逐行溯源 (blame) 對上一個版本執行逐行溯源 忽略空白符號變化 @@ -118,7 +118,7 @@ 簽出 (checkout) 分支 未提交變更: 目標分支: - 您目前的分離的 HEAD 包含與任何分支/標籤無關的提交! 您要繼續嗎? + 目前的 HEAD 包含未連結至任何分支或標籤的提交! 您是否要繼續? 以下子模組需要更新: {0},您要立即更新嗎? 簽出分支並快轉 上游分支: @@ -127,13 +127,13 @@ 所選擱置: 簽出提交或標籤 目標: - 注意:執行該操作後,目前 HEAD 會變為分離 (detached) 狀態! + 注意: 執行該操作後,目前 HEAD 會變為分離 (detached) 狀態! 揀選提交 提交資訊中追加來源資訊 提交列表: 提交變更 對比的父提交: - 通常您不能對一個合併進行揀選 (cherry-pick),因為您不知道合併的哪一邊應該被視為主線。這個選項指定了作為主線的父提交,允許揀選相對於該提交的修改。 + 通常您無法揀選 (cherry-pick) 合併提交,因為無法判斷哪個父提交應視為主線。此選項可指定作為主線的父提交。 捨棄擱置變更確認 您正在捨棄所有的擱置變更,一經操作便無法復原,是否繼續? 複製 (clone) 遠端存放庫 @@ -181,7 +181,7 @@ 變更對比 個檔案已變更 搜尋變更... - 收起詳細面板 + 收合詳細面板 檔案列表 LFS 檔案 搜尋檔案... @@ -211,7 +211,7 @@ 差異提交 左側獨有提交 右側獨有提交 - 提示:如果比較的另一方是 HEAD,您可以揀選 (cherry-pick) 已選擇的提交 (使用滑鼠右鍵) + 提示: 如果比較的另一方是 HEAD,您可以揀選 (cherry-pick) 已選擇的提交 (使用滑鼠右鍵) 存放庫設定 提交訊息範本 內建參數: @@ -230,8 +230,8 @@ ${REPO} 存放庫路徑 ${REMOTE} 所選的遠端存放庫或所選分支的遠端 - ${BRANCH} 所選的分支。對於遠端分支,不包含遠端名稱 - ${BRANCH_FRIENDLY_NAME} 所選的分支。對於遠端分支,不包含遠端名稱 + ${BRANCH} 所選的分支。遠端分支不包含遠端名稱 + ${BRANCH_FRIENDLY_NAME} 所選的分支。遠端分支會包含遠端名稱 ${SHA} 所選的提交編號 ${TAG} 所選的標籤 ${FILE} 所選的檔案,相對於存放庫根目錄的路徑 @@ -282,15 +282,15 @@ 用於本存放庫的使用者名稱 編輯自訂動作輸入控制項 啟用時的指令參數: - 勾選 CheckBox 後,此值將用於指令參數中 + 勾選核取方塊後,此值將用於指令參數中 描述: 預設值: 目標路徑是否為資料夾: 名稱: 選項列表: 請使用英文「|」符號分隔選項 - 字串格式化器: - 可選。用於格式化輸出字串。當輸入為空時將被忽略。請使用 `${VALUE}` 來表示輸入字串。 + 字串格式化: + 選填。用於格式化輸出字串。若輸入為空則會忽略此設定。請使用 `${VALUE}` 來表示輸入字串。 內建變數 ${REPO}、${REMOTE}、${BRANCH}、${BRANCH_FRIENDLY_NAME}、${SHA}、${FILE} 及 ${TAG} 在此處仍可使用 類型: 輸出包含遠端的名稱: @@ -302,7 +302,7 @@ 未包含任何檔案變更! 您是否仍要提交 (--allow-empty)? 暫存全部變更並提交 僅暫存所選變更並提交 - 未包含任何檔案變更! 您是否仍要提交 (--allow-empty) 或者自動暫存變更並提交? + 未包含任何檔案變更! 您是否仍要提交 (--allow-empty) 或自動暫存變更並提交? 系統提示 您需要重新啟動此應用程式才能套用變更! 產生約定式提交訊息 @@ -346,6 +346,7 @@ 強制取消,即使包含本機變更 子模組: 刪除分支確認 + 您是否也想刪除以下遠端分支? 分支名稱: 強制刪除,即使包含未合併的提交 您正在刪除遠端上的分支,請務必小心! @@ -441,12 +442,12 @@ 檔案歷史 檔案變更 檔案內容 - 檔案類型變更: - 刪除檔案類型: + 檔案類型變更: + 刪除檔案類型: 目錄 可執行檔案 - 新增檔案類型: - 普通檔案 + 新增檔案類型: + 一般檔案 子模組 符號連結 未知 @@ -553,7 +554,7 @@ 拉取 (pull) 遠端的變更 推送 (push) 本機變更到遠端存放庫 強制重新載入存放庫 - 在歷史頁面中展開/收起詳細面板 + 在歷史頁面中展開/收合詳細面板 顯示本機變更 顯示歷史記錄 顯示擱置變更列表 @@ -574,7 +575,7 @@ 正在復原提交 互動式重定基底 自動擱置變更並復原本機變更 - 繞過 pre-rebase 鉤子 + 繞過 pre-rebase hook 起始提交: 拖曳以重新排序提交 目標分支: @@ -591,10 +592,10 @@ 目標分支: 合併方式: 合併來源: - 偵測合併衝突中... + 正在偵測合併衝突... 合併操作不會產生衝突 偵測合併衝突時發生未知錯誤 - 合併操作將存在衝突檔案 + 合併操作將產生檔案衝突 先套用我方版本 (ours),再套用對方版本 (theirs) 先套用對方版本 (theirs),再套用我方版本 (ours) 套用兩者 @@ -658,7 +659,7 @@ 附加提示詞 (請使用 '-' 列出您的要求) API 金鑰 模型 - 自動獲取可用的模型列表 + 自動取得可用的模型列表 名稱 從環境變數中 (輸入環境變數名稱) 讀取 API 金鑰 伺服器 @@ -710,7 +711,7 @@ 使用 git-credential-libsecret 取代 git-credential-manager 使用者名稱 預設 Git 使用者名稱 - 在檢出或合併分支時,預設擱置變更並自動復原 + 在簽出或合併分支時,預設擱置變更並自動復原 Git 版本 GPG 簽章 啟用提交簽章 @@ -723,7 +724,7 @@ 第三方工具整合 終端機/Shell 啟動參數 - 請使用「.」標示當前工作目錄 + 請使用「.」表示目前工作目錄 安裝路徑 終端機/Shell 清理遠端已刪除分支 @@ -760,10 +761,10 @@ 自動擱置變更並復原本機變更 繞過 pre-rebase 鉤子 目標提交: - 偵測重定基底衝突中... + 正在偵測重定基底衝突... 重定基底操作不會產生衝突 偵測重定基底衝突時發生未知錯誤 - 重定基底操作將存在衝突檔案 + 重定基底操作將產生檔案衝突 新增遠端存放庫 編輯遠端存放庫 遠端名稱: @@ -776,7 +777,7 @@ 編輯... 啟用定時自動提取 提取 (fetch) 更新 - 在瀏覽器中存取網址 + 在瀏覽器中開啟網址 清理遠端已刪除分支 刪除工作區操作確認 啟用 [--force] 選項 @@ -786,10 +787,10 @@ 新的分支名稱不能與現有分支名稱相同 分支: 中止 - 自動提取遠端變更中... + 正在自動提取遠端變更... 排序 依建立時間 - 依名稱升序 + 依名稱遞增排序 清理本存放庫 (GC) 本操作將執行 `git gc` 指令。 清空篩選規則 @@ -834,8 +835,8 @@ 只顯示合併提交的第一父提交 顯示內容 顯示失去參照的提交 - 以樹型結構展示 - 以樹型結構展示 + 以樹狀結構顯示 + 以樹狀結構顯示 跳過此提交 提交統計 子模組列表 @@ -864,7 +865,7 @@ 復原操作確認 目標提交: 復原後提交變更 - 執行操作中,請耐心等待... + 正在執行操作,請耐心等待... 儲存 另存新檔... 修補檔已成功儲存! @@ -932,8 +933,8 @@ 相對存放庫路徑: 本機存放的相對路徑。 刪除 - 更改追蹤分支 - 更改遠端網址 + 變更追蹤分支 + 變更遠端網址 狀態 未提交變更 未初始化 @@ -963,7 +964,7 @@ 更新所有子模組 如果子模組尚未初始化,則將其初始化 子模組: - 遞迴更新多層級子模組 + 遞迴更新子模組 更新至子模組的遠端追蹤分支 存放庫網址: 記錄 @@ -979,7 +980,7 @@ 支援拖放以新增目錄與自訂群組。 編輯 調整存放庫分組 - 開啟所有包含存放庫 + 開啟所有存放庫 開啟本機存放庫 開啟終端機 重新掃描預設複製 (clone) 目錄下的存放庫 @@ -1001,7 +1002,7 @@ 觸發點擊事件 提交 (修改原始提交) 自動暫存全部變更並提交 - 您正在向一個分離狀態的 HEAD 提交變更,您確定要繼續提交嗎? + HEAD 目前處於分離狀態。您確定要繼續提交變更嗎? 您已暫存 {0} 個檔案,但只顯示 {1} 個檔案 ({2} 個檔案被篩選器隱藏)。您確定要繼續提交嗎? 偵測到衝突 解決衝突 diff --git a/src/Resources/Styles.axaml b/src/Resources/Styles.axaml index 332dd6c8c1..ec6525398e 100644 --- a/src/Resources/Styles.axaml +++ b/src/Resources/Styles.axaml @@ -16,7 +16,7 @@ Red - + @@ -48,7 +48,7 @@ - + @@ -403,11 +403,11 @@ - + - + + - + - + - + - + - + - + diff --git a/src/Views/DeleteRemote.axaml b/src/Views/DeleteRemote.axaml index ea5c39b80f..f8ab1033d6 100644 --- a/src/Views/DeleteRemote.axaml +++ b/src/Views/DeleteRemote.axaml @@ -16,7 +16,7 @@ Classes="bold" Text="{DynamicResource Text.DeleteRemote}"/> - + diff --git a/src/Views/DeleteRepositoryNode.axaml b/src/Views/DeleteRepositoryNode.axaml index 15132a9f3c..5971e250d5 100644 --- a/src/Views/DeleteRepositoryNode.axaml +++ b/src/Views/DeleteRepositoryNode.axaml @@ -21,7 +21,7 @@ Text="{DynamicResource Text.DeleteRepositoryNode.TitleForRepository}" IsVisible="{Binding Node.IsRepository}"/> - + - + - + - + @@ -291,7 +291,8 @@ @@ -318,6 +319,7 @@ @@ -336,7 +338,7 @@ - + - + diff --git a/src/Views/EditRemote.axaml.cs b/src/Views/EditRemote.axaml.cs index 7d88704e53..655cbdcd2d 100644 --- a/src/Views/EditRemote.axaml.cs +++ b/src/Views/EditRemote.axaml.cs @@ -17,7 +17,12 @@ private async void SelectSSHKey(object _, RoutedEventArgs e) if (toplevel == null) return; - var options = new FilePickerOpenOptions() { AllowMultiple = false, FileTypeFilter = [new FilePickerFileType("SSHKey") { Patterns = ["*.*"] }] }; + var options = new FilePickerOpenOptions() + { + AllowMultiple = false, + FileTypeFilter = [new("SSHKey") { Patterns = ["*"] }] + }; + var selected = await toplevel.StorageProvider.OpenFilePickerAsync(options); if (selected.Count == 1) TxtSshKey.Text = selected[0].Path.LocalPath; diff --git a/src/Views/ExecuteCustomAction.axaml b/src/Views/ExecuteCustomAction.axaml index e2b938d855..6769f94814 100644 --- a/src/Views/ExecuteCustomAction.axaml +++ b/src/Views/ExecuteCustomAction.axaml @@ -150,7 +150,7 @@ IsVisible="{Binding Description, Converter={x:Static StringConverters.IsNotNullOrEmpty}}"/> - + - + - + diff --git a/src/Views/GitFlowFinish.axaml b/src/Views/GitFlowFinish.axaml index 542caecfa2..879d88d854 100644 --- a/src/Views/GitFlowFinish.axaml +++ b/src/Views/GitFlowFinish.axaml @@ -26,7 +26,7 @@ Text="{DynamicResource Text.GitFlow.FinishHotfix}" IsVisible="{Binding Type, Converter={x:Static ObjectConverters.Equal}, ConverterParameter={x:Static m:GitFlowBranchType.Hotfix}}"/> - + - + - + - + - + - + - + - + - + - + diff --git a/src/Views/Merge.axaml b/src/Views/Merge.axaml index be31f6534d..48cc9b7111 100644 --- a/src/Views/Merge.axaml +++ b/src/Views/Merge.axaml @@ -19,7 +19,7 @@ Classes="bold" Text="{DynamicResource Text.Merge}"/> - + - + - + diff --git a/src/Views/MergeConflictEditor.axaml b/src/Views/MergeConflictEditor.axaml index d73038d5cd..e5b4379661 100644 --- a/src/Views/MergeConflictEditor.axaml +++ b/src/Views/MergeConflictEditor.axaml @@ -39,7 +39,7 @@ - + - + - + diff --git a/src/Views/Preferences.axaml.cs b/src/Views/Preferences.axaml.cs index aaa0f29170..99ec73a5f2 100644 --- a/src/Views/Preferences.axaml.cs +++ b/src/Views/Preferences.axaml.cs @@ -451,8 +451,8 @@ private async void SelectExecutableForCustomAction(object sender, RoutedEventArg { var options = new FilePickerOpenOptions() { - FileTypeFilter = [new FilePickerFileType("Executable file(script)") { Patterns = ["*.*"] }], AllowMultiple = false, + FileTypeFilter = [new("Executable file(script)") { Patterns = ["*"] }] }; try diff --git a/src/Views/PruneRemote.axaml b/src/Views/PruneRemote.axaml index 0484c76dc5..10e99d3cb1 100644 --- a/src/Views/PruneRemote.axaml +++ b/src/Views/PruneRemote.axaml @@ -16,7 +16,7 @@ Classes="bold" Text="{DynamicResource Text.PruneRemote}"/> - + diff --git a/src/Views/PruneWorktrees.axaml b/src/Views/PruneWorktrees.axaml index b6e45d6116..a7f6f3f44f 100644 --- a/src/Views/PruneWorktrees.axaml +++ b/src/Views/PruneWorktrees.axaml @@ -14,7 +14,7 @@ Classes="bold" Text="{DynamicResource Text.PruneWorktrees}"/> - + diff --git a/src/Views/Pull.axaml b/src/Views/Pull.axaml index 328c1318a7..d5a4eb3a71 100644 --- a/src/Views/Pull.axaml +++ b/src/Views/Pull.axaml @@ -18,7 +18,7 @@ Classes="bold" Text="{DynamicResource Text.Pull.Title}"/> - + - + - + - + - + - + - - + - + - + { Native.OS.OpenInFileManager(fullpath); @@ -40,6 +47,7 @@ private void OpenWithExternalTools(object sender, RoutedEventArgs ev) var terminal = new MenuItem(); terminal.Header = App.Text("Repository.Terminal"); terminal.Icon = this.CreateMenuIcon("Icons.Terminal"); + terminal.Tag = isMacOS ? "Λ+`" : "Ctrl+`"; terminal.Click += (_, e) => { Native.OS.OpenTerminal(fullpath); diff --git a/src/Views/Reset.axaml b/src/Views/Reset.axaml index 639b6fed44..f521bae60b 100644 --- a/src/Views/Reset.axaml +++ b/src/Views/Reset.axaml @@ -18,7 +18,7 @@ Classes="bold" Text="{DynamicResource Text.Reset}"/> - + - + - + 0) + if (vm.RevisionFileSearchSuggestion?.Count > 0) { SearchSuggestionBox.Focus(NavigationMethod.Tab); SearchSuggestionBox.SelectedIndex = 0; diff --git a/src/Views/ScanRepositories.axaml b/src/Views/ScanRepositories.axaml index 1e53e3cff4..58c9c5665e 100644 --- a/src/Views/ScanRepositories.axaml +++ b/src/Views/ScanRepositories.axaml @@ -17,7 +17,7 @@ Classes="bold" Text="{DynamicResource Text.ScanRepositories}"/> - + - + - + - + - + diff --git a/src/Views/UpdateSubmodules.axaml b/src/Views/UpdateSubmodules.axaml index d902ebb88f..11951301fc 100644 --- a/src/Views/UpdateSubmodules.axaml +++ b/src/Views/UpdateSubmodules.axaml @@ -17,7 +17,7 @@ Classes="bold" Text="{DynamicResource Text.UpdateSubmodules}"/> - + - + - + - + @@ -220,6 +220,6 @@ FontSize="12" Text="{DynamicResource Text.Welcome.DragDropTip}" Opacity=".5"/> - + diff --git a/src/Views/Welcome.axaml.cs b/src/Views/Welcome.axaml.cs index 830b881c24..c93c27ebb8 100644 --- a/src/Views/Welcome.axaml.cs +++ b/src/Views/Welcome.axaml.cs @@ -1,5 +1,7 @@ using System; +using System.IO; using System.Threading; + using Avalonia; using Avalonia.Controls; using Avalonia.Controls.Primitives; @@ -148,22 +150,66 @@ private void OnTreeNodeContextRequested(object sender, ContextRequestedEventArgs { var menu = new ContextMenu(); - if (!node.IsRepository && node.SubNodes.Count > 0) + var edit = new MenuItem(); + edit.Header = App.Text("Welcome.Edit"); + edit.Icon = this.CreateMenuIcon("Icons.Edit"); + edit.Click += (_, e) => + { + node.Edit(); + e.Handled = true; + }; + + var move = new MenuItem(); + move.Header = App.Text("Welcome.Move"); + move.Icon = this.CreateMenuIcon("Icons.MoveTo"); + move.Click += (_, e) => { - var openAll = new MenuItem(); - openAll.Header = App.Text("Welcome.OpenAllInNode"); - openAll.Icon = this.CreateMenuIcon("Icons.Folder.Open"); - openAll.Click += (_, e) => + node.Move(); + e.Handled = true; + }; + + var delete = new MenuItem(); + delete.Header = App.Text("Welcome.Delete"); + delete.Icon = this.CreateMenuIcon("Icons.Clear"); + delete.Click += (_, e) => + { + node.Delete(); + e.Handled = true; + }; + + if (!node.IsRepository) + { + if (node.SubNodes.Count > 0) { - node.Open(); + var openAll = new MenuItem(); + openAll.Header = App.Text("Welcome.OpenAllInNode"); + openAll.Icon = this.CreateMenuIcon("Icons.Folder.Open"); + openAll.Click += (_, e) => + { + node.Open(); + e.Handled = true; + }; + + menu.Items.Add(openAll); + menu.Items.Add(new MenuItem() { Header = "-" }); + } + + var addSubFolder = new MenuItem(); + addSubFolder.Header = App.Text("Welcome.AddSubFolder"); + addSubFolder.Icon = this.CreateMenuIcon("Icons.Folder.Add"); + addSubFolder.Click += (_, e) => + { + node.AddSubFolder(); e.Handled = true; }; - menu.Items.Add(openAll); + menu.Items.Add(addSubFolder); + menu.Items.Add(edit); + menu.Items.Add(move); menu.Items.Add(new MenuItem() { Header = "-" }); + menu.Items.Add(delete); } - - if (node.IsRepository) + else if (Directory.Exists(node.Id)) { var open = new MenuItem(); open.Header = App.Text("Welcome.OpenOrInit"); @@ -197,51 +243,16 @@ private void OnTreeNodeContextRequested(object sender, ContextRequestedEventArgs menu.Items.Add(explore); menu.Items.Add(terminal); menu.Items.Add(new MenuItem() { Header = "-" }); + menu.Items.Add(edit); + menu.Items.Add(move); + menu.Items.Add(new MenuItem() { Header = "-" }); + menu.Items.Add(delete); } else { - var addSubFolder = new MenuItem(); - addSubFolder.Header = App.Text("Welcome.AddSubFolder"); - addSubFolder.Icon = this.CreateMenuIcon("Icons.Folder.Add"); - addSubFolder.Click += (_, e) => - { - node.AddSubFolder(); - e.Handled = true; - }; - menu.Items.Add(addSubFolder); + menu.Items.Add(delete); } - var edit = new MenuItem(); - edit.Header = App.Text("Welcome.Edit"); - edit.Icon = this.CreateMenuIcon("Icons.Edit"); - edit.Click += (_, e) => - { - node.Edit(); - e.Handled = true; - }; - - var move = new MenuItem(); - move.Header = App.Text("Welcome.Move"); - move.Icon = this.CreateMenuIcon("Icons.MoveTo"); - move.Click += (_, e) => - { - node.Move(); - e.Handled = true; - }; - - var delete = new MenuItem(); - delete.Header = App.Text("Welcome.Delete"); - delete.Icon = this.CreateMenuIcon("Icons.Clear"); - delete.Click += (_, e) => - { - node.Delete(); - e.Handled = true; - }; - - menu.Items.Add(edit); - menu.Items.Add(move); - menu.Items.Add(new MenuItem() { Header = "-" }); - menu.Items.Add(delete); menu.Open(grid); } diff --git a/src/Views/WelcomeToolbar.axaml b/src/Views/WelcomeToolbar.axaml index 91f2064fa7..d26613e6cf 100644 --- a/src/Views/WelcomeToolbar.axaml +++ b/src/Views/WelcomeToolbar.axaml @@ -13,7 +13,7 @@ - + @@ -24,13 +24,20 @@ - + - diff --git a/src/Views/WorkingCopy.axaml b/src/Views/WorkingCopy.axaml index b63d106490..a2adcc446f 100644 --- a/src/Views/WorkingCopy.axaml +++ b/src/Views/WorkingCopy.axaml @@ -359,7 +359,7 @@ - +