Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move msbuild xml logic into a C# Custom Build Task class and Create Unit Tests #15

Closed
dazinator opened this issue Jun 13, 2015 · 3 comments
Assignees

Comments

@dazinator
Copy link
Owner

The MSBuild scripts are getting quite complicated which makes things harder to maintain and pretty impossible to test.

I should create a custom build task class instead - written in C#. I can move most of the logic out into that custom task. This will then be possible to unit test and easier to maintain in the long term.

@dazinator
Copy link
Owner Author

@dazinator dazinator self-assigned this Jul 9, 2015
@dazinator dazinator added this to the Major Refactoring milestone Jul 9, 2015
@dazinator dazinator changed the title Move msbuild xml logic into a C# Custom Build Task class. Move msbuild xml logic into a C# Custom Build Task class and Create Unit Tests Dec 1, 2015
dazinator added a commit that referenced this issue Dec 3, 2015
Included new DnnPackager.Tasks.dll in NuGet Package.
Changed install.ps1 in nuget package to install the new targets file, and remove the old v1 targets file.
Attempted to get tab expansion working for the Install-Module powershell command.
dazinator added a commit that referenced this issue Dec 3, 2015
dazinator added a commit that referenced this issue Dec 3, 2015
Added test module project, so can build it and make sure its packaged up correctly!
Trying to fix issue with task not being able to be loaded from tasks assembly :(
dazinator added a commit that referenced this issue Dec 6, 2015
Now a better citizen of the msbuild process.
Adds the output zip file to FileWrites so its cleaned up when you do a clean.
Uses the IntermediateOutputDir to do packaging, this is usually within /obj folder this makes us a better citizen of msbuild.
When you do a clean, now cleans up intermediate output.
Unit tests all passing.
General betterness.
dazinator added a commit that referenced this issue Dec 6, 2015
Fixed an issue with output properties not being set correctly.
@dazinator
Copy link
Owner Author

V2 has the behaviour that any file with a build action of "content" will be included in the resources zip in the install package, which by default will be extracted to your modules install directory under DesktopModules folder when your modules install zip is installed to a Dnn instance.

However v1 never had this, it just had a hardcode list of file extensions to include in the resources zip by default.

I need to check whether it's faesible to ask people in V2 to ensure that the following file types, which would have automatically been included in V1, are set to a build action of "Content" so that they will be included in the install package in v2.

  • .ascx
  • .asmx
  • .aspx
  • .ashx
  • .cshtml
  • .css
  • .db
  • .eot
  • .gif
  • .html
  • .htm
  • .js
  • .jpg
  • .jpeg
  • .msi
  • .png
  • .resx
  • .svc
  • .ttf
  • .xml
  • .xslt

The assembly file, sqldataprovider files, licence and manifest file are dealt with separately hence they are not listed in the above.

dazinator added a commit that referenced this issue Dec 8, 2015
Closes #27 - can include dnn version specific manifest files.
Added another test case for how manifests are selected for the package.
Added loads more content to the TestModule - so can actually build it and check a more realistic install package.

TODO: Have noticed RESX files aren't being included in the install zip, so still need to add in some logic to take care of RESX files.
dazinator added a commit that referenced this issue Dec 8, 2015
Packaging now deals with RESX files correctly.
dazinator added a commit that referenced this issue Dec 9, 2015
#29 - Some headway made with this, code to attach in theory is done, just need to tie it in to the commane line.
@dazinator
Copy link
Owner Author

Completed in v2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant