ics-builder 4.1.91 → 4.1.92

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ics-builder",
3
- "version": "4.1.91",
3
+ "version": "4.1.92",
4
4
  "description": "",
5
5
  "main": "./src/app.js",
6
6
  "preferGlobal": true,
@@ -20,30 +20,14 @@ var CsprojFile = /** @class */ (function (_super) {
20
20
  function CsprojFile() {
21
21
  return _super !== null && _super.apply(this, arguments) || this;
22
22
  }
23
- CsprojFile.prototype.addPostBuildCopy = function (copyToPath) {
23
+ CsprojFile.prototype.setPublishPath = function (publishPath) {
24
24
  if (!this._xmlObj)
25
25
  this._readFile();
26
26
  if (!this._xmlObj.Project)
27
27
  this._xmlObj.Project = {};
28
- this._xmlObj.Project.Target = {
29
- $: {
30
- Name: "CopyTarget",
31
- AfterTargets: "PostBuildEvent"
32
- },
33
- ItemGroup: {
34
- OutputFiles: {
35
- $: {
36
- Include: "$(TargetDir)\\*.*"
37
- }
38
- }
39
- },
40
- Copy: {
41
- $: {
42
- SourceFiles: "@(OutputFiles)",
43
- DestinationFolder: copyToPath,
44
- }
45
- }
46
- };
28
+ if (!this._xmlObj.Project.PropertyGroup)
29
+ this._xmlObj.Project.PropertyGroup = {};
30
+ this._xmlObj.Project.PropertyGroup.PublishDir = publishPath;
47
31
  };
48
32
  return CsprojFile;
49
33
  }(xmlFile_1.XmlFile));
@@ -58,7 +58,7 @@ var Net5ApiBuilder = /** @class */ (function (_super) {
58
58
  var m = _b[_i];
59
59
  utils_1.Utils.copyFile(m.Project, m.TempProject);
60
60
  var csproj = new csprojFile_1.CsprojFile(m.Project);
61
- csproj.addPostBuildCopy(m.OutputPath);
61
+ csproj.setPublishPath(m.OutputPath);
62
62
  csproj.save(m.Project);
63
63
  }
64
64
  dotnetUtils_1.DotnetUtils.addProjectsToSln(tempSlnPath, this.modules.map(function (m) { return m.Project; }));
@@ -23,7 +23,7 @@ var WebConfigFile = /** @class */ (function (_super) {
23
23
  WebConfigFile.prototype.addDotnetProcessPath = function () {
24
24
  if (!this._xmlObj)
25
25
  this._readFile();
26
- var aspNetCoreSectionOptions = this._xmlObj.configuration.location[0]["system.webServer"][0].aspNetCore[0].$;
26
+ var aspNetCoreSectionOptions = this._xmlObj.configuration.location["system.webServer"].aspNetCore.$;
27
27
  aspNetCoreSectionOptions.processPath = "dotnet";
28
28
  aspNetCoreSectionOptions.arguments = ".\\Mdt.WebApi.dll";
29
29
  aspNetCoreSectionOptions.stdoutLogEnabled = "false";
@@ -10,7 +10,7 @@ var XmlFile = /** @class */ (function () {
10
10
  XmlFile.prototype._readFile = function () {
11
11
  var _this = this;
12
12
  var file = fs.readFileSync(this._path);
13
- xml2js.parseString(file, function (err, result) { return _this._xmlObj = result; });
13
+ xml2js.parseString(file, { explicitArray: false }, function (err, result) { return _this._xmlObj = result; });
14
14
  };
15
15
  XmlFile.prototype.save = function (path) {
16
16
  if (path === void 0) { path = null; }