kubevela / velad

Lightweight KubeVela that runs as Daemon in single node with high availability.
Apache License 2.0
67 stars 16 forks source link

Chore: replace deprecated command with environment file #159

Open jongwooo opened 9 months ago

jongwooo commented 9 months ago

Description

Closes #2

Update workflows to use environment file instead of deprecated set-output command. For more information, see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/

I found the workflow files that use set-output command through the following command:

$ find . -name '*.yml' -o -name '*.yaml' | xargs egrep '\bset-output\b'

AS-IS

echo "::set-output name=version::$version"
- name: Get matrix
  id: get_matrix
  run: |
    TARGETS=${{matrix.TARGETS}}
    echo ::set-output name=OS::${TARGETS%/*}
    echo ::set-output name=ARCH::${TARGETS#*/}

TO-BE

echo "version=$version" >> $GITHUB_OUTPUT
- name: Get matrix
  id: get_matri
  shell: bash
  run: |
    TARGETS=${{matrix.TARGETS}}
    echo "OS=${TARGETS%/*}" >> $GITHUB_OUTPUT
    echo "ARCH=${TARGETS#*/}" >> $GITHUB_OUTPUT