第一种:需要把调试方法改成debug代码用 #if DEBUG 包裹 using System; using System.Collections.Generic; using System.Text; using System.IO; namespace SplitPackage { public static class EnvConfig { static EnvConfig() { #if DEBUG ToolsPath = @"D:\workspace\shopstyle\tool&q…