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

Replace Mercurial code with Git code #19

Merged
merged 6 commits into from Mar 1, 2021
Merged

Conversation

@Wuzzy2
Copy link
Contributor

@Wuzzy2 Wuzzy2 commented Feb 9, 2021

PREVIEW PR! DO NOT MERGE BEFORE #13 AND #14!

This fixes #10. I have checked the Makefiles and scripts and replaced all legacy uses of hg commands (that no longer work) with equivalen git commands. I also replaced .hgignore with .gitignore.

This PR is only a preview, I will probably need to do some minor changes after #13 and #14 got merged. The scripting changes will likely stay the same, however.

@Wuzzy2 Wuzzy2 force-pushed the Wuzzy2:makefile_git branch from 06ce0db to 73e7b6b Feb 14, 2021
@Wuzzy2
Copy link
Contributor Author

@Wuzzy2 Wuzzy2 commented Feb 15, 2021

I have added a few commits authored by glx22. It's about a few bugfixes in the Makefile.

Also, GitHub Actions support will be added. Note that the PR as a whole is NOT mergable yet, the merge of #14 is still a precondition for this.

@Wuzzy2 Wuzzy2 force-pushed the Wuzzy2:makefile_git branch from 73e7b6b to 07ddad2 Feb 25, 2021
@Wuzzy2
Copy link
Contributor Author

@Wuzzy2 Wuzzy2 commented Feb 25, 2021

Alright, I have updated and rebased this PR to include the changes of previous PRs.

However, I noticed a problem: OpenSFX no longer shows up in the menu when I copied the files to ~/.openttd/baseset/opensfx.
What did I do wrong?

@Wuzzy2 Wuzzy2 force-pushed the Wuzzy2:makefile_git branch from 07ddad2 to f727413 Feb 25, 2021
@Wuzzy2
Copy link
Contributor Author

@Wuzzy2 Wuzzy2 commented Feb 25, 2021

Alright, I figured out the cause of the problem. The description in the .obs file was no longer generated. I deleted a script that I shouldn't have deleted. :D So I restored it.

@orudge orudge force-pushed the Wuzzy2:makefile_git branch from d47c986 to ea5c500 Feb 25, 2021
@orudge orudge force-pushed the Wuzzy2:makefile_git branch from ea5c500 to 9d54a59 Feb 25, 2021
@orudge
Copy link
Contributor

@orudge orudge commented Feb 25, 2021

So, this took a bit longer than expected... needed to implement a few fixes:

  1. The unix2dos execution was failing for me on Debian 10.
  2. The -source.tar bundles weren't being generated correctly. The git archive needed to be combined with files that were being written into opensfx-1.2.3-source directory.
  3. Tagged builds weren't being named correctly - the tags was basically being ignored. Tagged builds will be named correctly now (e.g., 1.0.0), and development git builds will get a hashed name, similar to OpenTTD itself.
  4. The GitHub Actions workflow wasn't quite working correctly (was referring to an -all.zip which didn't exist, and a README.md which also didn't exist). I've tested the new workflow (short of actually publishing to openttd.org) and it's now working correctly.

I've cleaned up the commit history a bit, and personally I'm now happy with what's here. Would like a second opinion from another developer if one is available though.

@glx22
Copy link
Contributor

@glx22 glx22 commented Feb 25, 2021

Basically the release workflow was just a copy/paste from opengfx, with only dependencies corrected. So it was expected to not work ;)

@Wuzzy2
Copy link
Contributor Author

@Wuzzy2 Wuzzy2 commented Feb 26, 2021

Thank you for reviewing and working this. I don't know how I could continue my further here. Do you want to take over from now?

@orudge
Copy link
Contributor

@orudge orudge commented Feb 26, 2021

@glx22 It was pretty close, to be fair. :) Would you mind reviewing the PR, or at least my changes to it?

# Move bundles in their own folder
mkdir bundles
mv opensfx-${{ steps.vars.outputs.version }}-source.tar.xz bundles/
mv opensfx-${{ steps.vars.outputs.version }}.zip bundles/opensfx-${{ steps.vars.outputs.version }}-all.zip

This comment has been minimized.

@glx22

glx22 Feb 26, 2021
Contributor

Maybe it would be better to fix Makefile to add "-all"
I guess it should be Makefile:352

with:
token: ${{ secrets.DEPLOYMENT_TOKEN }}
repository: OpenTTD/workflows
event-type: update_cdn

This comment has been minimized.

@glx22

glx22 Feb 28, 2021
Contributor

Issue spotted in OpenGFX, and as I copied the workflow :)

Suggested change
event-type: update_cdn
event-type: update-cdn
@orudge orudge force-pushed the Wuzzy2:makefile_git branch from 9d54a59 to ec14645 Mar 1, 2021
# Move bundles in their own folder
mkdir bundles
mv opensfx-${{ steps.vars.outputs.version }}-source.tar.xz bundles/
mv opensfx-${{ steps.vars.outputs.version }}-all.zip bundles/opensfx-${{ steps.vars.outputs.version }}-all.zip

This comment has been minimized.

@glx22

glx22 Mar 1, 2021
Contributor

Suggested change
mv opensfx-${{ steps.vars.outputs.version }}-all.zip bundles/opensfx-${{ steps.vars.outputs.version }}-all.zip
mv opensfx-${{ steps.vars.outputs.version }}-all.zip bundles/

This comment has been minimized.

@orudge

orudge Mar 1, 2021
Contributor

Ah yes, that would be more straightforward!

@orudge orudge force-pushed the Wuzzy2:makefile_git branch from ec14645 to 8bd1d99 Mar 1, 2021
@glx22
glx22 approved these changes Mar 1, 2021
Copy link
Contributor

@glx22 glx22 left a comment

Should be ok now

@orudge orudge merged commit 8b9376e into OpenTTD:master Mar 1, 2021
@Wuzzy2 Wuzzy2 mentioned this pull request Mar 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

3 participants