Closed DarwinJS closed 3 years ago
Hmmm - so I also tried forcing au_version like the docs say and it bombed out. (did it at a global level since all packages are the same version). I also tried au_version in update for each package and received the same error because the new version is not overriden.
I see that au_version is resused in this line:
. "$Env:TEMP/au/scripts/Install-AU.ps1" $Env:au_version
so if I set it at the CI level - it messes up right there.
Having a hard time getting set_fix_version to run.
Ok I tried the third option by setting "FORCED" to two packages, but it still does not add the fix version? (please see below)
Does this line: https://github.com/majkinetor/au-packages/blob/06f52d122b6a665171202b35bead07ba20ca99fa/update_all.ps1#L9
Need to be Force = $Env:au_force -eq 'true'
?
Mhm... not sure until I see the full code. This feature is used non-stop all around.
Does your updateall
script has this line ?
Do you have repository with this setup (I looked at your GitLab repo but I don't see AU stuff). The repo should be created via au-packages template in general for it to just work as expected.
You may temporarily try setting the explicit version yourself until the problem is found, eg: pwsh:7.1.3.20210315
I just tried once for test and it works as expected.
Does this line: https://github.com/majkinetor/au-packages/blob/06f52d122b6a665171202b35bead07ba20ca99fa/update_all.ps1#L9
Need to be
Force = $Env:au_force -eq 'true'
?
THAT force is used to force ALL packages, not just some of them. You can set it up that way, but I wouldn't do so - $Env:au_force
is what you should set when working with single package. If you accidentally leave it on and in same pwsh session you latter call updateall
you can accidentally push ALL packages...
That option is mainly used in combination with Push: $false
in order to test packages
OK I think I figured out how I got myself in a twist. I ran an update from 7.1.2 to 7.1.3, but the push to git failed.
Now when I force it, the source is still 7.1.2 and 7.1.3. is up on chocolatey - so it does not know to do the fix version and then it runs into the package clash and still does not update source (the whole reason I'm pushing a fix version in the first place).
Ah yeah, that happens, if there is newer version, force can't be used, naturally. Just update version on git since its authority for AU.
Thanks for your help. I now have your automated packages framework running from a GitLab repository on a GitLab runner. It works up through pushing back to the repository - but I still have to see about configuring testing.
It is here: https://gitlab.com/guided-explorations/microsoft/chocolatey/powershell-core
Another challenge is the powershell-preview package is published on the same GitHub project, but I've been using a separate package id (because it goes to another folder and then folks can update both without having two independent ones on the same feed.
Would streams work to publish to separate package ids? Maybe I should just reunify them on the same package id?
FYI GitLab is planning NuGet.Core 2.x compatibility - once that is in the product, the internal NuGet feed in each project can be used to test packages - or if you use the virtual feed at a higher level group, your package repository tree can be your chocolatey end point.
Would streams work to publish to separate package ids? Maybe I should just reunify them on the same package id?
Yeah, just change PackageName
within stream.
once that is in the product, the internal NuGet feed in each project can be used to test packages
Nice. This is good reason to use GL with AU so you can have working packages when gallery admins wont allow them due to copyright or other reasons. I guess having runner ready template should be done to support this beside AV.
I might be misunderstanding the requirements - but the docs here: https://github.com/majkinetor/au#force-update note that using force should create chocolatey fix versions with the date. However, as you can see in the screenshot, I am successfully setting the parameter - but it ignores my wishes :(
I tried with and without NoCheckChocoVersion.
AU Version is 2020.11.21