declarative-flatpak icon indicating copy to clipboard operation
declarative-flatpak copied to clipboard

`services.flatpak.UNCHECKEDpostEverythingCommand`: confusing behavior/name

Open Malix-Labs opened this issue 4 months ago • 5 comments

Does services.flatpak.UNCHECKEDpostEverythingCommand, run for each post remotes, install, and switch, or just once post switch?

If that's the later, is there a reason why it isn't named postSwitchCommand?

Malix-Labs avatar Aug 07 '25 18:08 Malix-Labs

"postEverything" does exactly what is in it's name. It runs as the last thing in the chain.

"UNCHECKED" is there to make it very clear that any errors will not abort the atomic operation

in-a-dil-emma avatar Aug 07 '25 18:08 in-a-dil-emma

If you have any ideas on better wording, let me know

in-a-dil-emma avatar Aug 07 '25 18:08 in-a-dil-emma

"postEverything" does exactly what is in it's name. It runs as the last thing in the chain.

I have been personally confused by its name

As in, "postEverything" could potentially mean "postRemotes" + "postInstall" + "postSwitch"

If you have any ideas on better wording, let me know

I think it would be clearer to name it "postSwitch", or, if the last thing in the chain is not Switch (let it be "X"), "postX"

Malix-Labs avatar Aug 07 '25 19:08 Malix-Labs

As in, "postEverything" could potentially mean "postRemotes" + "postInstall" + "postSwitch"

Yes, that's what it's supposed to mean.

Perhaps UNCKECKEDfinalizeCommand is a viable alternative. I would also need to add a notice that UNCHECKED means that the atomic operation doesn't abort on errors.

in-a-dil-emma avatar Aug 07 '25 19:08 in-a-dil-emma

that's what it's supposed to mean

I think I made you also confused

What I truly mean is that I thought it could mean: Execute the script "postRemotes" + Execute the script again "postInstall" + Execute the script again "postSwitch"

I would also need to add a notice that UNCHECKED means that the atomic operation doesn't abort on errors.

This is indeed a good idea

Malix-Labs avatar Aug 07 '25 19:08 Malix-Labs