Skip to content

Commit

Permalink
v2.5.7
Browse files Browse the repository at this point in the history
  • Loading branch information
nilaoda committed Mar 5, 2020
1 parent 2b5af09 commit 4b5a64e
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 2 deletions.
7 changes: 7 additions & 0 deletions N_m3u8DL-CLI/FFmpeg.cs
Expand Up @@ -23,6 +23,13 @@ class FFmpeg
string poster = "", string audioName = "", string title = "",
string copyright = "", string comment = "", string encodingTool = "")
{
//同名文件已存在的共存策略
if (File.Exists($"{OutPutPath}.{muxFormat.ToLower()}"))
{
OutPutPath = Path.Combine(Path.GetDirectoryName(OutPutPath),
Path.GetFileName(OutPutPath) + "_" + DateTime.Now.ToString("yyyy-MM-dd_HH-mm-ss"));
}

string command = "-loglevel warning -i concat:\"";
string data = string.Empty;
string ddpAudio = string.Empty;
Expand Down
10 changes: 8 additions & 2 deletions N_m3u8DL-CLI/Global.cs
Expand Up @@ -30,8 +30,8 @@ class Global


/*===============================================================================*/
static string nowVer = "2.5.6";
static string nowDate = "20200302";
static string nowVer = "2.5.7";
static string nowDate = "20200305";
public static void WriteInit()
{
Console.Clear();
Expand Down Expand Up @@ -296,6 +296,12 @@ public static void PartialCombineMultipleFiles(string[] files)
/// <param name="outputFilePath"></param>
public static void CombineMultipleFilesIntoSingleFile(string[] files, string outputFilePath)
{
//同名文件已存在的共存策略
if (File.Exists(outputFilePath))
{
outputFilePath = Path.Combine(Path.GetDirectoryName(outputFilePath),
Path.GetFileNameWithoutExtension(outputFilePath) + "_" + DateTime.Now.ToString("yyyy-MM-dd_HH-mm-ss") + Path.GetExtension(outputFilePath));
}
if (files.Length == 1)
{
FileInfo fi = new FileInfo(files[0]);
Expand Down
11 changes: 11 additions & 0 deletions N_m3u8DL-CLI/Program.cs
Expand Up @@ -252,6 +252,17 @@ namespace N_m3u8DL_CLI.NetCore
/// 2020年3月2日
/// - 支持51cto的key自动解密
/// - 请求m3u8内容时,有10次自动重试
/// - 直播下载自动设置请求分段文件时间间隔
/// - 修复网络断线一直Downloading及cpu 100%
/// - 加入savename参数仍可读取N_m3u8DL-CLI.args.txt
/// - 直播下载跳过响应码为400的片段
/// 2020年3月3日
/// - 修复输出太长只在最后一行显示的问题
/// 2020年3月4日
/// - 只认第一个"#EXT-X-MAP", 其余的全部丢弃
/// - 逻辑优化
/// 2020年3月5日
/// - 增加同名文件合并时共存策略
/// </summary>
///

Expand Down

0 comments on commit 4b5a64e

Please sign in to comment.