diff --git a/.github/workflows/development.yml b/.github/workflows/development.yml index af6b384..e87cac7 100644 --- a/.github/workflows/development.yml +++ b/.github/workflows/development.yml @@ -13,17 +13,18 @@ jobs: - name: "set current datetime" env: TZ: "Asia/Tokyo" - run: | # do not remove the space after `date +`. you need this. - echo "CURRENT_DATETIME=$(date +"%Y-%m-%d %H:%M:%S")" >> $GITHUB_ENV + # do not remove the space after `date +`. you need this. + run: | + echo "CURRENT_DATETIME=$(date +"%Y-%m-%d %H:%M:%S")" >> "$GITHUB_ENV" - name: "set arguments" id: "arguments" run: | - echo '::set-output name=message::"[info][title](beer)what time is it now?[/title]it is ${{ env.CURRENT_DATETIME }} now.[/info]"' + echo "MESSAGE=[info][title](beer)what time is it now?[/title]it is ${{ env.CURRENT_DATETIME }} now.[/info]" >> "$GITHUB_ENV" - uses: ./ with: apiToken: "${{ secrets.API_KEY }}" roomId: "${{ secrets.ROOM_ID }}" - message: "${{ steps.arguments.outputs.message }}" + message: "${{ env.MESSAGE }}" - uses: ./ with: apiToken: "${{ secrets.API_KEY }}" diff --git a/.github/workflows/example.yml b/.github/workflows/example.yml index 0db45d6..398d5d5 100644 --- a/.github/workflows/example.yml +++ b/.github/workflows/example.yml @@ -13,14 +13,15 @@ jobs: - name: "set current datetime" env: TZ: "Asia/Tokyo" - run: | # do not remove the space after `date +`. you need this. - echo "CURRENT_DATETIME=$(date +"%Y-%m-%d %H:%M:%S")" >> $GITHUB_ENV + # do not remove the space after `date +`. you need this. + run: | + echo "CURRENT_DATETIME=$(date +"%Y-%m-%d %H:%M:%S")" >> "$GITHUB_ENV" - name: "set arguments" id: "arguments" run: | - echo '::set-output name=message::"[info][title](beer)what time is it now?[/title]it is ${{ env.CURRENT_DATETIME }} now.[/info]"' + echo "MESSAGE=[info][title](beer)what time is it now?[/title]it is ${{ env.CURRENT_DATETIME }} now.[/info]" >> "$GITHUB_ENV" - uses: "okuzawats/chatwork-messaging-action@v1.1" with: apiToken: "${{ secrets.API_KEY }}" roomId: "${{ secrets.ROOM_ID }}" - message: "${{ steps.arguments.outputs.message }}" + message: "${{ env.MESSAGE }}"