Fix testing plugins install

This commit is contained in:
Aireil 2020-12-12 04:35:35 +01:00
parent 0e0ae80ac6
commit fd27b53593

View file

@ -70,10 +70,13 @@ namespace Dalamud.Plugin
try { try {
using var client = new WebClient(); using var client = new WebClient();
var isTestingExclusive = definition.IsTestingExclusive;
// We need to redownload the json, for the eventuality of the zip having changed after PM download // We need to redownload the json, for the eventuality of the zip having changed after PM download
definition = JsonConvert.DeserializeObject<PluginDefinition>( definition = JsonConvert.DeserializeObject<PluginDefinition>(
client.DownloadString(string.Format(this.PluginJsonUrl, fromTesting ? "testing" : "plugins", client.DownloadString(string.Format(this.PluginJsonUrl, fromTesting ? "testing" : "plugins",
definition.InternalName))); definition.InternalName)));
definition.TestingAssemblyVersion = fromTesting ? definition.AssemblyVersion : "0.0.0.0";
definition.IsTestingExclusive = isTestingExclusive;
var outputDir = new DirectoryInfo(Path.Combine(this.pluginDirectory, definition.InternalName, fromTesting ? definition.TestingAssemblyVersion : definition.AssemblyVersion)); var outputDir = new DirectoryInfo(Path.Combine(this.pluginDirectory, definition.InternalName, fromTesting ? definition.TestingAssemblyVersion : definition.AssemblyVersion));
var dllFile = new FileInfo(Path.Combine(outputDir.FullName, $"{definition.InternalName}.dll")); var dllFile = new FileInfo(Path.Combine(outputDir.FullName, $"{definition.InternalName}.dll"));