-
Notifications
You must be signed in to change notification settings - Fork 1
/
action.yaml
40 lines (37 loc) · 1.19 KB
/
action.yaml
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
#
# Copyright 2023 The OpenVEX Authors
# SPDX-License-Identifier: Apache-2.0
#
name: generate-vex
author: The OpenVEX Authors
description: 'Generates VEX data using the OpenVEX tooling'
branding:
icon: 'package'
color: 'blue'
# This is pinned to the last major release, we have to bump it for each action version.
inputs:
templates-dir:
description: 'OpenVEX templates directory'
required: false
default: ${GITHUB_WORKSPACE}/.openvex/templates
product:
description: 'Identifier of the product to be VEXed'
required: true
file:
description: 'Path to the file where the OpenVEX document will be written'
required: false
runs:
using: "composite"
steps:
- uses: openvex/setup-vexctl@e85ca48f3c8a376289f6476129d59cda82147e71 # v0.1.1
- shell: bash
run: |
#!/bin/bash
if [ -z "$NO_COLOR" ]; then
alias log_info="echo -e \"\033[1;32mINFO\033[0m:\""
alias log_error="echo -e \"\033[1;31mERROR\033[0m:\""
else
alias log_info="echo \"INFO:\""
alias log_error="echo \"ERROR:\""
fi
vexctl generate "${{ inputs.product }}" --file="${{ inputs.file }}" --templates="${{ inputs.templates-dir }}"