-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaction.yml
More file actions
50 lines (45 loc) · 1.54 KB
/
action.yml
File metadata and controls
50 lines (45 loc) · 1.54 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
---
name: Changed Diff-Tree for Files or Directories
author: Rishav Dhar (@rdhar)
description: Changed diff-tree for a list of changed files or directories between branches with GitHub Action event triggers.
runs:
using: composite
steps:
- shell: bash
run: |
# Check for required tools.
which gh > /dev/null 2>&1 || { echo "Please install GitHub CLI before running this action as it is required for interacting with GitHub."; exit 1; }
which jq > /dev/null 2>&1 || { echo "Please install jq before running this action as it is required for processing JSON outputs."; exit 1; }
if [[ "$GITHUB_SERVER_URL" != "https://github.com" ]]; then echo GH_HOST=$(echo "$GITHUB_SERVER_URL" | sed 's/.*:\/\///') >> "$GITHUB_ENV"; fi
- shell: bash
id: approvals
env:
GH_API: X-GitHub-Api-Version:2022-11-28
GH_TOKEN: ${{ inputs.token }}
run: |
# Placeholder
exit 0
outputs:
placeholder:
description: "placeholder."
value: placeholder
inputs:
source_ref:
default: ""
description: "Source branch or commit SHA to compare from."
required: false
target_ref:
default: ""
description: "Target branch or commit SHA to compare against."
required: false
format:
default: "raw"
description: "Format output as: 'raw', 'json', or 'matrix'."
required: false
token:
default: ${{ github.token }}
description: "GitHub access token with 'read:org' scope (e.g., secrets.CI_PAT)."
required: true
branding:
color: gray-dark
icon: file-plus