cake-contrib / Cake.ResxConverter

Cake addin for ResxConverter
https://cakebuild.net/extensions/cake-resxconverter/
MIT License
0 stars 5 forks source link

GH3: Added Cake.Recipe for build process #4

Open gep13 opened 7 years ago

gep13 commented 7 years ago

@jzeferino @luisgoncalves as promised, here is the first pass at adding Cake.Recipe to this project.

There is some documentation about Cake.Recipe here:

https://cake-contrib.github.io/Cake.Recipe/docs/

I am aware that it is lacking, and more information is needed. What I can say is that I am now using Cake.Recipe on almost 50 repos, and it has been working exactly as required.

When running locally, you can do a normal build using:

.\build.ps1

If you want to check out the Wyam generated documentation, then you can run:

.\build.ps1 -target preview

and then you can open this:

http://localhost:5080/Cake.ResxConverter/docs

To see the generated docs.

Please let me know if you have any questions about the changes that I have made.

jzeferino commented 7 years ago

@gep13 I didn't have the time to analise all the commits, but the build.sh needs to be changed as the .ps1 was. Can you do that change and add update the PR?

Two more questions:

gep13 commented 7 years ago

@jzeferino apologies for not replying sooner, missed the notification...

@jzeferino said... I didn't have the time to analise all the commits, but the build.sh needs to be changed as the .ps1 was.

At the minute, Cake.Recipe only runs on a Windows environment. That is something that will change going forward, but at the minute it simply won't work. As a result, the build.sh wasn't updated. Is that going to be a problem? Are you actually building the addin on a non-Windows system?

@jzeferino said... Why do you removed the usage sample from readme?

Cake.Recipe includes the creation of a documentation site, using Wyam. I moved the usage example into that documentation. The result should be something similar to this:

https://cake-contrib.github.io/Cake.Http/docs/usage/examples

@jzeferino said... Why do you remove the appveyor build status badge in readme?

I didn't 😄 I moved it. You can see it here:

https://github.com/cake-contrib/Cake.ResxConverter/pull/4/files#diff-04c6e90faac2675aa89e2176d2eec7d8R21

Most addin's in the Cake Contrib Organisation have a standard readme file, so I simply used the same template, slotting in the values specific to this project.

jzeferino commented 7 years ago

@gep13 thanks for the answers.

At the minute, Cake.Recipe only runs on a Windows environment. That is something that will change going forward, but at the minute it simply won't work. As a result, the build.sh wasn't updated. Is that going to be a problem? Are you actually building the addin on a non-Windows system?

i'm running on OSX. Can I still run the old .sh?

gep13 commented 7 years ago

@jzeferino said... i'm running on OSX. Can I still run the old .sh?

Hmm, that is unlikely, at the minute anyway. We could, in theory re-instate the build.cake file that you did have, which would make it all work again, but that would mean that there would be a difference between the script that is ran on AppVeyor, compared to what you run locally.

I will have to think about this one.

gep13 commented 7 years ago

@jzeferino thinking about this some more... I don't have a Mac to test on, but if I update the build.sh, would you be willing to work with me to get Cake.Recipe running on your Mac?

luisgoncalves commented 7 years ago

I only had time to look through this today. It looks good. I have a few comments/questions though @gep13:

Regarding the changes to build.sh, I guess it can also be tested in an Ubuntu VM or something. I can do that.

gep13 commented 7 years ago

@luisgoncalves said... Why the /nuspec/nuget indirection (subfolder)?

This is a convention. Cake.Recipe understands how to package both nuget and chocolatey packages. NuGet nuspec files live in nuspec/nuget and Chocolatey nuspec files live in nuspec/chocolatey.

@luisgoncalves said... I see that flags such as ShouldPostToTwitter are true. Will this be done when running on AppVeyor? Does it use pre-configured environment variables to get credentials and stuff?

Yes, the publishing steps are only attempted when the build is happening on AppVeyor, and when it is a tagged build. All the required environment variables have been configured and setup within the AppVeyor project settings.

@luisgoncalves said... Similarly, will the Wyam docs be published to cake-contrib.github.io/Cake.ResxConverter or do we need to configure anything else?

That is correct, this is where the documentation will reside. The only thing that needs to happen outside of this PR would be to create a gh-pages branch. Once we are all happy, I can take care of this step.

@luisgoncalves said... The calculated semantic version was 1.0.1-Cake-Recipe0001 but at a first glance I was expecting 1.0.2-something. We have the 1.0.2 tag on master.. is this the cause? Did we do something wrong on the Git flow?

Where did you see that version number? The asserted version number that I am seeing is this one: 1.1.0-PullRequest.4+15.build.22 from here: https://ci.appveyor.com/project/cakecontrib/cake-resxconverter/build/1.1.0-PullRequest.4+15.build.22 which is in inline with what I would expect. The latest tag that you have on the repository is 1.0.2. The PR that I created was into the develop branch, and the next release number from develop is 1.1.0. The next hotfix release (which would be a branch from the master branch, would be 1.0.3.

@luisgoncalves said... Regarding the changes to build.sh, I guess it can also be tested in an Ubuntu VM or something. I can do that.

If you could, that would be great. I expect things to fail here, but we can address them as they come up.

Please let me know if you have any further questions.

jzeferino commented 7 years ago

@gep13 said... @jzeferino thinking about this some more... I don't have a Mac to test on, but if I update the build.sh, would you be willing to work with me to get Cake.Recipe running on your Mac?

@gep13 yes, we can do that with no problem.

gep13 commented 7 years ago

@jzeferino perfect! I will try to update this PR later today to make the necessary changes to the build.sh file, and you can take it for a spin on your Mac. Like I say, I expect several things to break 😄 as it has never been tested there, but it would be good to figure out what the problems are and get them fixed.

luisgoncalves commented 7 years ago

@gep13 Thanks for all the answers. Regarding the version number, I saw that when I checked out your fork and run the build locally.

jzeferino commented 7 years ago

@gep13 ping 👍

jzeferino commented 7 years ago

@gep13 how are we on this?

gep13 commented 7 years ago

@jzeferino honestly, I haven't forgotten about this. Just been tied up with a few other things 😢