GitHub Actions Integration

Run GitHub Actions workflows locally using act to test workflows without pushing to GitHub. Workspace Tasks provides a rich interface for discovering and executing workflows with full input support.

Table of Contents

  1. Overview
    1. Task Tree Structure
  2. Requirements
  3. Features
  4. Configuration
    1. workspaceTasks.applicationPath.act
    2. workspaceTasks.act.envFile
    3. workspaceTasks.act.secretsFile
    4. workspaceTasks.act.variablesFile
    5. workspaceTasks.act.variables
  5. Usage Example
  6. Tips
  7. Next Steps

Overview

Workspace Tasks automatically discovers all GitHub Actions workflow files in .github/workflows/*.yml and exposes them as runnable tasks. Each workflow appears with its individual jobs and supported trigger events.

Task Tree Structure

GitHub Actions
└── Build & Test
    β”œβ”€β”€ Run Workflow (push)
    β”œβ”€β”€ Run Workflow (workflow_dispatch)  ← Shows input prompts
    └── Run Job: build

Requirements

  • act β€” Must be installed on your system
  • Docker β€” Must be running (act uses containers)
  • Configure workspaceTasks.applicationPath.act if act is not in your system PATH

Features

  • Automatic Discovery β€” Scans .github/workflows/*.yml files
  • Event Support β€” Run workflows for push, pull_request, workflow_dispatch, and custom events
  • Job Execution β€” Run individual jobs from multi-job workflows
  • Input Prompts β€” Interactive prompts for workflow_dispatch inputs with validation
  • Status Indicators β€” Real-time visual feedback during execution

Configuration

Configure act in your VS Code settings.json:

{
  // Path to act executable
  "workspaceTasks.applicationPath.act": "act",

  // Environment files
  "workspaceTasks.act.envFile": ".env",
  "workspaceTasks.act.secretsFile": ".act.secrets",
  "workspaceTasks.act.variablesFile": ".act.vars",

  // Inline variables
  "workspaceTasks.act.variables": {
    "ENVIRONMENT": "development",
    "VERSION": "1.0.0"
  }
}

workspaceTasks.applicationPath.act

Type: string Default: "act" Scope: resource

Path to the act executable. On Windows, if the path ends with act, .exe will be appended automatically. ~/ is expanded to the user’s home directory.

{
  // Use an act binary bundled inside the project
  "workspaceTasks.applicationPath.act": "tools\\act\\act.exe"
}

workspaceTasks.act.envFile

Type: string Default: ""

Path to a .env file containing environment variables for act. See the Act documentation for file format details.

workspaceTasks.act.secretsFile

Type: string Default: ""

Path to a secrets file for act. Secrets are used to provide sensitive values to workflows without exposing them in configuration.

workspaceTasks.act.variablesFile

Type: string Default: ""

Path to a variables file for act.

workspaceTasks.act.variables

Type: object Default: {}

Inline key/value pairs passed as variables to act runs.


Usage Example

Given this workflow at .github/workflows/build.yml:

name: Build & Test
on:
  push:
  workflow_dispatch:
    inputs:
      environment:
        description: 'Deployment environment'
        required: true
        default: 'staging'
        type: choice
        options: [development, staging, production]

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - run: npm run build

Workspace Tasks will display:

GitHub Actions
└── Build & Test
    β”œβ”€β”€ Run Workflow (push)
    β”œβ”€β”€ Run Workflow (workflow_dispatch)
    └── Run Job: build

When you run β€œRun Workflow (workflow_dispatch)”, Workspace Tasks will prompt you to fill in the environment input before executing.


Tips

  • Store secrets in a .secrets file and add it to .gitignore to keep credentials out of source control
  • Test workflow_dispatch inputs locally before pushing to verify your workflow logic
  • Run individual jobs to debug specific workflow steps without re-running the entire workflow
  • Use the workspaceTasks.act.variables setting for environment-specific values that change between runs

Next Steps


© 2026 Ryan Conrad. All rights reserved.

This site uses Just the Docs, a documentation theme for Jekyll.