Skip to content

Commit

Permalink
overwrite output files if already exist, properly insert _NetDeepL to…
Browse files Browse the repository at this point in the history
… output files
  • Loading branch information
penCsharpener committed Mar 8, 2020
1 parent 9ceff4c commit 113c0c9
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ public async Task TranslateAsync()
Directory.CreateDirectory(_options.Value.OutputPath.FullName);
}

var xlsxCopy = Path.Combine(_options.Value.OutputPath.FullName, xlsx.Name.Replace(".xlsx", "_NetDeepL.xlsx"));
File.Copy(xlsx.FullName, xlsxCopy);
var xlsxCopy = Path.Combine(_options.Value.OutputPath.FullName, xlsx.Name.Insert(xlsx.Name.Length - 5, "_NetDeepL"));
File.Copy(xlsx.FullName, xlsxCopy, true);

using (var wbCopy = new XLWorkbook(xlsxCopy))
{
Expand Down

0 comments on commit 113c0c9

Please sign in to comment.