Skip to content

Conversation

@AlanDrake
Copy link
Contributor

Preliminary version.

Perhaps it's possible to remove repetition with reusable workflows. I just read they exist, so I don't really know possible issues yet.
Each run could clean up after uploading the artifacts, would just need to add a prefix to them.

Note: I'm not fetching specific versions of the ags4 branch, but arguably this whole sync thing is just a mechanic to waste our time.
There will never be a case in which we build an older manual through the CI. We might as well just always get the latest both on ags3 and 4 doc sources.

Unless anyone's got time to improve on this, we could merge and start using the ags4 artifacts for ags4 builds.
Though the v4 manual is still a WIP, I added almost all apis.

Next step will be figuring out the multiversion web manual.

preliminary version
@ericoporto
Copy link
Member

How are the artifacts named? I can't pickup from the change

@AlanDrake
Copy link
Contributor Author

If I can believe the job summary, the new artifacts are like this:
ags4_chm_Linux_3.0--with-chmcmd
ags4_chm_Windows_3.0
ags4_chm_Windows_3.0--with-chmcmd
ags4_chm_macOS_3.0--with-chmcmd
ags4_website_Linux_3.0
ags4_website_Windows_3.0
ags4_website_macOS_3.0

@ericoporto
Copy link
Member

ericoporto commented Jun 20, 2025

ok, re-reading now, what I see in the previous build it has uploaded the artifacts before, then it runs the ags4 version of things and uploads new artifacts. It would be better if the ags-help.chm was renamed to ags4-help.chm but this could alternatively be done later in the check and release step. This would make it easier to keep both ags-help.chm for all current, future, and previous ags3 releases, and then we would need only to adjust ags4 branch to download the ags4-help.chm artifact and rename it, on the main ags repo ci.

The other thing is that currently the release of the website will just publish the web build artifact that was uploaded, so it will need an intermediate step to add a new ags4 subfolder and create a new artifact from the previous two.

I am more commenting that as is, this doesn't publish any artifact to a release that can be consumed from the main ags repository.

@AlanDrake
Copy link
Contributor Author

Right, I didn't pay attention to the release script. So we download from the release files rather than the artifacts, right?
I guess that needs changing then.

The web version needs more work, I need to add a version selector, build the correct folder structure, possibly also enact the redirection from current urls to explicit version subfolder. Still not there yet.

@ericoporto
Copy link
Member

Looks alright now. We can change the how it accomplishes this workflow later if we want, as long we keep the release assets with the same name.

Once this is merged, the ags4 branch in AGS main repository needs to fetch this specific one in cirrus CI and rename it as only ags-help.chm and it should all workout.

@AlanDrake AlanDrake merged commit 9ce833f into adventuregamestudio:master Jun 20, 2025
5 checks passed
@AlanDrake
Copy link
Contributor Author

Alright then, on to the next step.

@ericoporto
Copy link
Member

ericoporto commented Jun 21, 2025

Something broke with the edit link somehow, see the commit below. Also, for some reason the github page got deployed twice?

712614c

Erh, running locally, I tried git -C source branch --show-current and got blank, I think this doesn't work for submodules?

Edit: it doesn't work because the submodule has a specific commit and not a specific branch I think. This would work if it was a regular branch that was git cloned.

Edit2: perhaps a possible fix would be to scrap the git submodule altogether for now and put a git clone command that creates source in the bootstrap script? It is called by CI here.

@ericoporto
Copy link
Member

Made the change to the ags4 branch in main repository

adventuregamestudio/ags@f8f3915

@AlanDrake
Copy link
Contributor Author

Erh, running locally, I tried git -C source branch --show-current and got blank, I think this doesn't work for submodules?

Edit: it doesn't work because the submodule has a specific commit and not a specific branch I think. This would work if it was a regular branch that was git cloned.

Edit2: perhaps a possible fix would be to scrap the git submodule altogether for now and put a git clone command that creates source in the bootstrap script? It is called by CI here.

God forsaken submodules...
What do you think of #287 ?

I'm using a github action to clone the repository, I actually wanted to use a bash if directory exist, to then shallow clone with both branches. Of course it keeled over with error code 128, so I gave up and let checkout@v4 do the task,

@ericoporto
Copy link
Member

ericoporto commented Jun 21, 2025

Yeah, that should work fine. The error 128 is from GitHub web somehow or this is a git thing? I need to check it out. One thing with submodules is that often I fall in an issue where I can't solve with any git command I am used in my computer and then I need to delete the folder (like ags-manual not source) an reclone it. Like, when the submodule source changed from the wiki, it never changed locally for me and when they desynced I started getting "failed to find commit errors", and then it turned out that it was using the wrong remote url for the submodule even through was supposed to be in the correct one, so delete the and reclone it I went.

@AlanDrake
Copy link
Contributor Author

AlanDrake commented Jun 21, 2025

I don't know, maybe I had forgotten to remove the source folder from the repo, but there was no error to be seen from the web log, so I lost my patience.
I'm about to leave for a couple days, no time to experiment until I return.

EDIT: Never mind, mountain excursion canceled.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants