#Version mismatch when building using tauri-action

53 messages · Page 1 of 1 (latest)

tawny summit
hollow dune
#

So the issue is that each job checks out the repo completely fresh so the build job doesn't see that the other one changed the package.json version

tawny summit
#

i thought that by checking it out it would grab the newest commit?

hollow dune
#

only on the next run i think

#

afaik all jobs use the same commit the workflow was triggered with

tawny summit
#

shoot. afaik i can't tell tauri the version tag to use when setting the name of artifacts

#

any ideas?

hollow dune
#

the first idea would be to split up the workflow runs similar to how tauri's release works

#

but syncing the github release may be a bit tricky then 🤔

#

actually no it wouldn't

tawny summit
#

yeaa. I've already had a lot of trouble with github actions

#

wdym?

hollow dune
#

lemme reset my brain real quick

tawny summit
#

lol fair enough

#

alright

#

perhaps a simpler question, isn't the action supposed to update the latest.json in the repository?

hollow dune
#

it uploads it to the release

#

if you use the dev version that is

tawny summit
#

hmm, I thought it would also update the repo

#

yea I am

#

none of the others worked for me

#

I'll try to just add another job that downloads it and commits it to the repo ig

hollow dune
#

especially since we're talking about multiple platforms, we can't "merge" them internally in the action

tawny summit
#

oh? I just need my app to be able to get it from a static url

#

i.e. not one with a version in it

hollow dune
#

doesn't matter for the action itself, but makes your life easier i guess

#

you probably don't even need the generator then? Wouldn't it be easier to do it yourself (in the workflow, not by hand)

tawny summit
#

I tried that, but I couldn't get it to work since I am compiling for two platforms

#

since I need the signature for both platforms

hollow dune
#

ah right the signature, forgot about that

tawny summit
#

yea, its a bit unfortunate lol. I should be able to just fetch it in a follow up workflow and update the repository tho ig

#

but still doesn't fix the version mismatch

hollow dune
#

i mean, you could try to force it to use a different commit than the one that triggered the workflow, like a simple git pull or by configuring the checkout action to pull from the correct branch instead of just the commit (ref: 'release' maybe?)

#

but idk how reliable that will be tbh

tawny summit
#

hmm. Maybe I could do the followup workflow like you said and try to grab the changelog and tag from the most recent draft release?

#

then I could get the new commit and version for the assets

#

and then run a 3rd workflow to update the latest.json and publish the release

hollow dune
#

Sounds like pain too 🙃

tawny summit
#

it all sounds like pain lol

hollow dune
#

yea

tawny summit
#

I've done 65 workflow runs to get to this point xD

hollow dune
#

i know that pain kkushLUL

#

i think that's just how CI is

#

painful

tawny summit
#

yea, but worth it once it works lol

#

especially in this case bc I can't compile my app on linux myself

hollow dune
#

true

tawny summit
#

like u said earlier, use ref: release

#

it worked!

#

awesome