調整:所有版本號改成從 Gitea 變數取得
This commit is contained in:
@@ -27,3 +27,7 @@
|
|||||||
`ci.yaml` 用 `uses: ./` 實際執行一次。
|
`ci.yaml` 用 `uses: ./` 實際執行一次。
|
||||||
|
|
||||||
圖示:`icon.svg`(Gitea 儲存庫頭像用 `icon.png`)。
|
圖示:`icon.svg`(Gitea 儲存庫頭像用 `icon.png`)。
|
||||||
|
|
||||||
|
## 內部引用的版本
|
||||||
|
|
||||||
|
`ci-cache`、`ci-env` 的版本取自呼叫端 repo 的 Gitea 變數 `ACTION_CI_CACHE_VERSION`、`ACTION_CI_ENV_VERSION`,不寫死在 `action.yml`,所以呼叫端要先設好這兩個變數。
|
||||||
|
|||||||
+3
-3
@@ -1,5 +1,5 @@
|
|||||||
name: ci-run
|
name: ci-run
|
||||||
description: "跑一個 CI 工作:還原快取(ci-cache)→ 在 ci-env 容器裡執行指令。要在 checkout 之後使用,需要工具鏈時呼叫的工作流要有 env: GO_VERSION、NODE_VERSION"
|
description: "跑一個 CI 工作:還原快取(ci-cache)→ 在 ci-env 容器裡執行指令。內部用的 ci-cache、ci-env 版本取自呼叫端的 Gitea 變數 ACTION_CI_CACHE_VERSION、ACTION_CI_ENV_VERSION。要在 checkout 之後使用,需要工具鏈時呼叫的工作流要有 env: GO_VERSION、NODE_VERSION"
|
||||||
inputs:
|
inputs:
|
||||||
command:
|
command:
|
||||||
description: "要在 ci-env 容器裡執行的 shell 指令"
|
description: "要在 ci-env 容器裡執行的 shell 指令"
|
||||||
@@ -16,11 +16,11 @@ inputs:
|
|||||||
runs:
|
runs:
|
||||||
using: composite
|
using: composite
|
||||||
steps:
|
steps:
|
||||||
- uses: https://gitea.jsc.idv.tw/actions/ci-cache@v0.0.1
|
- uses: https://gitea.jsc.idv.tw/actions/ci-cache@${{ vars.ACTION_CI_CACHE_VERSION }}
|
||||||
with:
|
with:
|
||||||
key: ${{ inputs.cache_key }}
|
key: ${{ inputs.cache_key }}
|
||||||
restore_keys: ${{ inputs.cache_restore_keys }}
|
restore_keys: ${{ inputs.cache_restore_keys }}
|
||||||
- name: ${{ inputs.name }}
|
- name: ${{ inputs.name }}
|
||||||
uses: https://gitea.jsc.idv.tw/actions/ci-env@v0.0.1
|
uses: https://gitea.jsc.idv.tw/actions/ci-env@${{ vars.ACTION_CI_ENV_VERSION }}
|
||||||
with:
|
with:
|
||||||
command: ${{ inputs.command }}
|
command: ${{ inputs.command }}
|
||||||
|
|||||||
Reference in New Issue
Block a user