Skip to content
Latchkey

What Is a Pre Step?

A pre step is a phase an action declares so that preparation logic runs before any of the job's main steps execute. Actions use it to set up credentials, restore a cache, or configure tooling early. It pairs with the post step to bracket the job with setup and teardown.

Why it matters

Some actions must act before user steps run, for example restoring a cache so later steps can use it. The pre step provides that early hook without reordering the workflow by hand. Together with post steps it lets an action manage a full lifecycle around the job.

Related guides

Tired of flaky CI? Latchkey auto-heals failed jobs and retries them for you. Start free →