mirror of
https://github.com/claunia/apprepodbmgr.git
synced 2025-12-16 19:24:42 +00:00
Fix exporting.
This commit is contained in:
@@ -69,16 +69,16 @@ namespace apprepodbmgr.Core
|
|||||||
}
|
}
|
||||||
|
|
||||||
string destinationFolder = "";
|
string destinationFolder = "";
|
||||||
destinationFolder = Path.Combine(destinationFolder, Context.DbInfo.Developer);
|
destinationFolder += Path.DirectorySeparatorChar + Context.DbInfo.Developer;
|
||||||
destinationFolder = Path.Combine(destinationFolder, Context.DbInfo.Product);
|
destinationFolder += Path.DirectorySeparatorChar + Context.DbInfo.Product;
|
||||||
destinationFolder = Path.Combine(destinationFolder, Context.DbInfo.Version);
|
destinationFolder += Path.DirectorySeparatorChar + Context.DbInfo.Version;
|
||||||
if(!string.IsNullOrWhiteSpace(Context.DbInfo.Languages))
|
if(!string.IsNullOrWhiteSpace(Context.DbInfo.Languages))
|
||||||
destinationFolder = Path.Combine(destinationFolder, Context.DbInfo.Languages);
|
destinationFolder += Path.DirectorySeparatorChar + Context.DbInfo.Languages;
|
||||||
if(!string.IsNullOrWhiteSpace(Context.DbInfo.Architecture))
|
if(!string.IsNullOrWhiteSpace(Context.DbInfo.Architecture))
|
||||||
destinationFolder = Path.Combine(destinationFolder, Context.DbInfo.Architecture);
|
destinationFolder += Path.DirectorySeparatorChar + Context.DbInfo.Architecture;
|
||||||
if(Context.DbInfo.Oem) destinationFolder = Path.Combine(destinationFolder, "oem");
|
if(Context.DbInfo.Oem) destinationFolder += Path.DirectorySeparatorChar + "oem";
|
||||||
if(!string.IsNullOrWhiteSpace(Context.DbInfo.TargetOs))
|
if(!string.IsNullOrWhiteSpace(Context.DbInfo.TargetOs))
|
||||||
destinationFolder = Path.Combine(destinationFolder, "for " + Context.DbInfo.TargetOs);
|
destinationFolder += Path.DirectorySeparatorChar + "for " + Context.DbInfo.TargetOs;
|
||||||
|
|
||||||
string destinationFile = "";
|
string destinationFile = "";
|
||||||
if(!string.IsNullOrWhiteSpace(Context.DbInfo.Format))
|
if(!string.IsNullOrWhiteSpace(Context.DbInfo.Format))
|
||||||
@@ -120,12 +120,9 @@ namespace apprepodbmgr.Core
|
|||||||
}
|
}
|
||||||
else if(destinationFile == "") destinationFile = "archive";
|
else if(destinationFile == "") destinationFile = "archive";
|
||||||
|
|
||||||
string destination = Path.Combine(destinationFolder, destinationFile) + ".zip";
|
string destination = destinationFolder + Path.DirectorySeparatorChar + destinationFile + ".zip";
|
||||||
|
|
||||||
Md5Context md5 = new Md5Context();
|
string mdid = Md5Context.Data(Encoding.UTF8.GetBytes(destination), out _);
|
||||||
md5.Init();
|
|
||||||
byte[] tmp;
|
|
||||||
string mdid = md5.Data(Encoding.UTF8.GetBytes(destination), out tmp);
|
|
||||||
Console.WriteLine("MDID: {0}", mdid);
|
Console.WriteLine("MDID: {0}", mdid);
|
||||||
|
|
||||||
if(dbCore.DbOps.ExistsOs(mdid))
|
if(dbCore.DbOps.ExistsOs(mdid))
|
||||||
|
|||||||
Reference in New Issue
Block a user