Skip to content

Commit 3a33712

Browse files
authored
fix(workflows-onboarding): Fixes the name of workflow name if not provided (#26)
Signed-off-by: Javier Rodriguez <[email protected]>
1 parent dfc395b commit 3a33712

File tree

4 files changed

+82
-1
lines changed

4 files changed

+82
-1
lines changed

.github/workflows/chainloop_onboard.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ jobs:
3636
run: |
3737
workflow_name=${{ inputs.workflow_name }}
3838
if [[ "$workflow_name" = "" ]]; then
39-
workflow_name=$(basename "$PARENT_WORKFLOW" | sed "s/\..*$//g")
39+
# Extract the parent workflow name and convert to lowercase with hyphens
40+
workflow_name=$(basename "$PARENT_WORKFLOW" | sed 's/\..*$//g; s/[[:space:]]/-/g; s/_/-/g' | tr '[:upper:]' '[:lower:]')
4041
fi
4142
echo "workflow_name=$workflow_name" >> $GITHUB_OUTPUT
4243

.idea/labs.iml

+4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/vcs.xml

+6
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/workspace.xml

+70
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)