此功能已于2022年9月26日 添加到GitHub Actions。
截至2022年9月3日,似乎无法实现此功能。在GitHub Actions社区论坛上有一个未回答的功能请求讨论,但尚未做出任何明显决定。
只需指定接受表达式的run-name
即可:
run-name: Deploy to ${{ github.event.inputs.env }} by @${{ github.actor }}
on:
push:
branches: ["master"]
workflow_dispatch:
inputs:
env:
description: 'env'
required: true
type: choice
options: ...