From 3a787cd41261db0a581b33e5cf277751a8fab08b Mon Sep 17 00:00:00 2001 From: Zettat123 Date: Mon, 20 Mar 2023 18:35:58 +0800 Subject: [PATCH] update readme --- README.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8032bee..570e7c3 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ This action is to compute the SHA256 hash of specified files. -**NOTE:** This action is written in Go. Please make sure the `runs-on` runner supports running Go actions. +**NOTE:** This action is written in Go. Please setup the Go environment before running this action or make sure the `runs-on` runner supports running Go actions. ## Usage @@ -27,6 +27,11 @@ This action is to compute the SHA256 hash of specified files. ## Example ``` yml +# Setup the Go environment. This step can be skipped if Go has been installed. +- uses: actions/setup-go@v3 + with: + go-version: '1.20' + - uses: actions/go-hashfiles@v0.0.1 id: get-hash with: @@ -34,6 +39,7 @@ This action is to compute the SHA256 hash of specified files. go.sum ./admin/* **/package-lock.json + - name: Echo hash run: echo ${{ steps.get-hash.outputs.hash }} ```