Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/actionify/src/job.ts>Job#outputs

Create and manage your GitHub workflows with TypeScript and Deno.
Latest
method Job.prototype.outputs
import { Job } from "https://deno.land/x/actionify@0.3.0/src/job.ts";

You can use jobs.<job_id>.outputs to create a map of outputs for a job. Job outputs are available to all downstream jobs that depend on this job. For more information on defining job dependencies, see jobs.<job_id>.needs.

Outputs are Unicode strings, and can be a maximum of 1 MB. The total of all outputs in a workflow run can be a maximum of 50 MB.

Job outputs containing expressions are evaluated on the runner at the end of each job. Outputs containing secrets are redacted on the runner and not sent to GitHub Actions.

To use job outputs in a dependent job, you can use the needs context. For more information, see "Contexts."

import { workflow, e } from 'https://deno.land/x/actionify@0.3.0/mod.ts';

const ci = workflow({ name: "ci", fileName: "ci" })
  .job('firstJob', (job) => {
    return job
      .name('A')
      .outputs(ctx => {
        return { action: e.expr(ctx.env.GITHUB_ACTION) }
      })
  });

Type Parameters

Options extends DefaultOutputOptions

Parameters

outputs: WithContext<Options, Base, "jobs:jobId:outputs:outputId">

Returns

Job<CombineAsUnion<Base | { jobOutputs: StringKeyOf<Options>; }>>