actions / runner

The Runner for GitHub Actions :rocket:
https://github.com/features/actions
MIT License
4.81k stars 946 forks source link

Show composite action name at step level #1877

Open bombillazo opened 2 years ago

bombillazo commented 2 years ago

Describe the bug Given the use of a custom composite action:

# Composite Action ./.github/actions/build-api/action.yml
name: 'Build API'
description: 'Build the API'
runs:
  using: 'composite'
  steps:
    ...

# Main Workflow
name: Deploy
on:
  push:
    branches:
      - main

jobs:
  deploy:
    name: Build API
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repo code
        uses: actions/checkout@v3
      # Configure Environments
      - uses: ./.github/actions/build-api

The runners do not show the step name of the composite action, instead a generic Run action... step name. Having to update this step name when it can be extracted from the action itself can get tedious when managing lots of actions and workflows.

To Reproduce Steps to reproduce the behavior:

  1. Setup a composite action
  2. Do not give a name to the step when using the composite action
  3. Run the action

Expected behavior The runner shows the name of the composite action for the step taken from the composite action metadata.

Runner Version and Platform

Version of your runner?

OS of the machine running the runner? All

What's not working?

image
ruvceskistefan commented 2 years ago

Hi @bombillazo,

Thanks for reporting this issue! I agree with everything written, if the step name is not defined, the name of the action itself should be displayed. I added this to the board so we will work on it and create a PR that solves this problem.

AlekSi commented 2 years ago

The same can be done for action steps. For example, given that composite action

name: 'Action name'
runs:
  using: 'composite'
  steps:
    - name: Action step 1
      run: go mod download
      working-directory: ${{ github.action_path }}
      shell: bash

I get

image

Both "Action name" and "Action step 1" are not visible. runs.steps.name is a required field, but seems to be unused.

acabarbaye commented 1 year ago

I would be also great if each step could be "collapsable" in the same way it is for other types of actions

zupo commented 1 year ago

Until this is properly fixed, is there any workaround to show a nicer name in the action output?

joaoluiznaufel commented 1 year ago

still waiting for this

anthonwellsjo commented 1 year ago

Still waiting for this too 🙏 This is a big advantage to be able to create a clean code bases with composite actions, without compromising readability in the UI...

cezar-tech commented 1 year ago

still waiting for this as well

asvishnyakov commented 1 year ago

+1 awaiter here

basimbd commented 11 months ago

+1 awaiter here (2)

bombillazo commented 11 months ago

It's been a while since I created this issue, I just wanted to follow up with the GH Actions team, given it's had much support since then.

@DanRigby @TingluoHuang @vanZeben @fhammerl

alan-sanchez2-kr commented 11 months ago

*anxiously awaiting for this as well 😅

jamesloosli commented 11 months ago

+1

Marcin-Lach commented 10 months ago

+1

brandonja991 commented 9 months ago

+1 Still waiting

ArminArdekani commented 8 months ago

+1 waiting too

fabianorosa1 commented 8 months ago

+1 awaiter here

KarimGl commented 8 months ago

+1 still waiting

nuryupin-kr commented 7 months ago

+1 still waiting

paveldedourek-eaton commented 7 months ago

+1 awaiter here

jaymecd commented 6 months ago

Knowing that GHA renders 1st line of the run script as step title, this workaround allows to have nicer rendering:

    - name: Verify installed ASDF tools
      shell: bash
      run: |
        : Verify installed ASDF tools
        awk '{print $1}' .tool-versions \
          ...

that provides nice rendering:

collapsed:

Screenshot 2024-03-10 at 14 11 01

expanded:

Screenshot 2024-03-10 at 14 09 40

Instead of : step name, one might use true shell - step name

Screenshot 2024-03-10 at 14 12 44

Both : and true commands do not affect execution flow

dkfellows commented 6 months ago

Knowing that GHA renders 1st line of the run script as step title, this workaround allows to have nicer rendering:

Clever workaround... but we shouldn't have to do that.

afernandez-01 commented 5 months ago

+1

ramilbakhshyiev commented 5 months ago

+1

setoelkahfi commented 4 months ago

I would like to have this ❤️

atsu85 commented 4 months ago

+1

bombillazo commented 4 months ago

I forgot to celebrate my baby's second birthday... 😞 Happy birthday, #1877!

jackhicks-thrive commented 4 months ago

And another +1 👍

ziadsarour commented 3 months ago

+42

kifir23917 commented 3 months ago

+100500

radiomix commented 2 weeks ago

Still not working :exclamation: ;-////