To this point, the only way I’ve been able to pass a variable (for example, a token) from one step to another is to write a file which contains that value.
This has been asked on here before, but I just want to check again and see if anything has changed and/or if others have come up with more elegant methods of doing this.
I assume you’ve tried it: can you set environment variables in one step and read them in another? I have the vague recollection I’ve done that with CircleCI, but I could be wrong.
CircleCI just has terrible support for passing information from one step to another. Here’s the relevant documentation with their recommended workaround:
The corner CircleCI has painted itself into, however, is that you can’t really use a BASH_ENV to pass a parameter to an orb or command. I’m not sure there’s actually any way to pass an interpolated value as a parameter to a command or an orb with the current set up.
My advice is that if you are this negative about any CI system, your CI project will fail - a positive mental attitude (and an inclination towards pragmatism) is essential to get it working and finished. If you want something that fits your use-case exactly, install Jenkins and maintain it yourself.
(I tend towards the view that hosted systems save time and frustration in the long run, even when taking work-arounds into account).
I meant to follow up on this before, but apeschel actually posted the link to what I ended up doing anyway. It’s not elegant, but it works, at least for our use case.
I disagree about CircleCI having terrible support. They’ve always been very responsive for us whenever we submit a ticket or email a rep.
I don’t think anyone is criticizing CircleCI support. The support quote was taken out of context. It was meant to point out specifically that the CircleCI platform has poor support for the specific feature of passing information between job steps.