From dbdcae7de1b767303b17ef0d0c13bf7d4f163830 Mon Sep 17 00:00:00 2001 From: Eric Coissac Date: Mon, 14 Apr 2025 11:36:00 +0200 Subject: [PATCH] Actualiser action.yaml --- action.yaml | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/action.yaml b/action.yaml index 1a14d1c..0e1d3c5 100644 --- a/action.yaml +++ b/action.yaml @@ -47,7 +47,9 @@ runs: check_command ${{ inputs.build_command }} - tags=(${{ inputs.image_tags }}) + IFS=' ' read -r -a tags <<< "${{ inputs.image_tags }}" + debug "Tags parsed: ${tags[*]}" + sep="" if [[ -n "${tags[0]}" ]] ; then sep=":" @@ -59,13 +61,19 @@ runs: && success "Image build" "${{ inputs.image_name }}" - name: tag images - shell: bash - run: | + shell: bash + run: | source "${{ github.action_path }}/bashlib.sh" - tags=(${{ inputs.image_tags }}) - + check_command ${{ inputs.tag_command }} + IFS=' ' read -r -a tags <<< "${{ inputs.image_tags }}" + + sep="" + if [[ -n "${tags[0]}" ]] ; then + sep=":" + fi + image=${{ inputs.registry_server }}/${{ inputs.image_name }}${sep}${tags[0]} if [[ "${{ inputs.build_command }}" != "${{ inputs.tag_command }}" ]] ; then