From ab64b8bf06baaf11afc6c9a070df6f7fb26f8c23 Mon Sep 17 00:00:00 2001 From: Don Syme Date: Thu, 14 Aug 2025 10:15:12 +0100 Subject: [PATCH] add server_url --- docs/workflow-structure.md | 1 + pkg/cli/templates/instructions.md | 1 + pkg/constants/constants.go | 1 + 3 files changed, 3 insertions(+) diff --git a/docs/workflow-structure.md b/docs/workflow-structure.md index 23b1c20b4a..4d36b58367 100644 --- a/docs/workflow-structure.md +++ b/docs/workflow-structure.md @@ -136,6 +136,7 @@ The following GitHub Actions context expressions are permitted in workflow markd - `${{ github.repository }}` - The owner and repository name (e.g., `octocat/Hello-World`) - `${{ github.run_id }}` - A unique number for each workflow run within a repository - `${{ github.run_number }}` - A unique number for each run of a particular workflow in a repository +- `${{ github.server_url }}` - Base URL of the server, e.g. https://github.com - `${{ github.workflow }}` - The name of the workflow #### Special Pattern Expressions diff --git a/pkg/cli/templates/instructions.md b/pkg/cli/templates/instructions.md index f67f03fecc..a74507db04 100644 --- a/pkg/cli/templates/instructions.md +++ b/pkg/cli/templates/instructions.md @@ -194,6 +194,7 @@ Use GitHub Actions context expressions throughout the workflow content. **Note: - **`${{ github.repository }}`** - Repository name in "owner/name" format - **`${{ github.run_id }}`** - Unique ID of the workflow run - **`${{ github.run_number }}`** - Number of the workflow run +- **`${{ github.server_url }}`** - Base URL of the server, e.g. https://github.com - **`${{ github.workflow }}`** - Name of the workflow #### Special Pattern Expressions diff --git a/pkg/constants/constants.go b/pkg/constants/constants.go index 0639bca373..32fb9f7956 100644 --- a/pkg/constants/constants.go +++ b/pkg/constants/constants.go @@ -36,5 +36,6 @@ var AllowedExpressions = []string{ "github.repository", "github.run_id", "github.run_number", + "github.server_url", "github.workflow", } // needs., steps. already allowed