Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support latest version #38

Merged
merged 2 commits into from
Dec 4, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 15 additions & 6 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ inputs:
version:
description: Specify runn version
required: false
default: "v0.114.1"
default: latest
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about setting the default version to the latest version as the runn-action?

The version of runn-action is linked to the version of runn
This version is updated when tagging by running the following job
If runn-action's latest version is specified, runn's latest version is expected to be used if the version is published in conjunction with runn-action.
https://github.com/k2tzumi/runn-action/blob/main/.github/workflows/release.yml

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Understood 👍

On the other hand, it seems a waste not to be able to specify latest.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, it looks like you should update the v0 and latest tags.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see
I guess I'll add a process to re-cut the v0 and latest tags in the workflow at the time of release.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR only allows to specify the latest version.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Issue registered
#42
#43

debug:
description: Filter runbooks to be executed
required: false
Expand Down Expand Up @@ -61,6 +61,20 @@ runs:
- name: 'Check input parameter'
shell: 'bash'
run: |
#
# subcommand check
#
if [[ ! "${{ inputs.command }}" =~ ^(run|list|loadt)$ ]]; then
echo "Error: Invalid command ${{ inputs.command }} is not supported. Please specify run or list or loadt."
exit 1
fi

#
# version check
#
if [[ "${{ inputs.version }}" == "latest" ]]; then
exit 0
fi
# vx.y.z -> x.y.z
input_version=$(echo "${{ inputs.version }}" | sed 's/^v//')
compatible_version=$(echo "v0.64.0" | sed 's/^v//')
Expand All @@ -82,11 +96,6 @@ runs:
exit 1
fi
done

if [[ ! "${{ inputs.command }}" =~ ^(run|list|loadt)$ ]]; then
echo "Error: Invalid command ${{ inputs.command }} is not supported. Please specify run or list or loadt."
exit 1
fi
- name: Setup k1LoW/runn
uses: k1LoW/gh-setup@v1
with:
Expand Down