From 6158fa072b43bfa8de2364abbae07f0d9a95e607 Mon Sep 17 00:00:00 2001 From: glax Date: Thu, 1 Jun 2023 22:32:11 +0200 Subject: [PATCH] File permissions --- Tranga/Connector.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Tranga/Connector.cs b/Tranga/Connector.cs index 3c1bda3..42ba377 100644 --- a/Tranga/Connector.cs +++ b/Tranga/Connector.cs @@ -84,6 +84,8 @@ public abstract class Connector string newFilePath = Path.Join(publicationFolder, $"cover.{Path.GetFileName(fileInCache).Split('.')[^1]}" ); logger?.WriteLine(this.GetType().ToString(), $"Cloning cover {fileInCache} -> {newFilePath}"); File.Copy(fileInCache, newFilePath, true); + if(RuntimeInformation.IsOSPlatform(OSPlatform.Linux)) + File.SetUnixFileMode(newFilePath, GroupRead | GroupWrite | OtherRead | OtherWrite | UserRead | UserWrite); } ///