diff --git a/Day/2024-Q3/Helper-2024-07-11.cs b/Day/2024-Q3/Helper-2024-07-11.cs index 8158320..3203a86 100644 --- a/Day/2024-Q3/Helper-2024-07-11.cs +++ b/Day/2024-Q3/Helper-2024-07-11.cs @@ -24,7 +24,7 @@ internal static partial class Helper20240711 string remoteToRemoveFilter = args[4]; string sourceDirectory = Path.GetFullPath(args[0]); string lastRemoteSegment = remoteToRemove.Split('/')[^1]; - string extension = args[7].Length > 2 ? args[6] : string.Empty; + string extension = args[7].Length > 2 ? args[7] : string.Empty; string[] files = Directory.EnumerateFiles(sourceDirectory, searchPattern, new EnumerationOptions() { IgnoreInaccessible = true, RecurseSubdirectories = true, AttributesToSkip = FileAttributes.None }).ToArray(); logger.LogInformation("Found {files} file(s)", files.Length); foreach (string file in files) @@ -69,8 +69,8 @@ internal static partial class Helper20240711 continue; try { messages = Helpers.HelperGit.PushBranch(parentDirectory, remoteToAddName, branchName, CancellationToken.None); } - catch (Exception) - { messages = new([]); } + catch (Exception ex) + { messages = new([ex.Message]); } foreach (string message in messages) logger.LogInformation("{function} => {parentDirectoryName}: [{message}]", nameof(Helpers.HelperGit.PushBranch), parentDirectoryName, message); }