From c53dadce505b4460f1cf914203c3a6c40e2e9d8e Mon Sep 17 00:00:00 2001 From: Joshua Li Date: Mon, 15 Dec 2025 17:39:12 -0800 Subject: [PATCH 1/2] support wd for .python-version --- action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/action.yml b/action.yml index 1243a30..407290f 100644 --- a/action.yml +++ b/action.yml @@ -27,7 +27,7 @@ runs: id: setup-python with: python-version: ${{ inputs.python-version }} - python-version-file: ${{ hashFiles('.python-version') == '' && '' || '.python-version' }} + python-version-file: ${{ hashFiles(inputs.working-directory + '/.python-version') == '' && '' || inputs.working-directory + '/.python-version' }} - run: echo '::remove-matcher owner=python::' shell: bash @@ -54,4 +54,4 @@ runs: - run: ${{ inputs.install-cmd }} if: inputs.install-cmd != '' && steps.cache-venv.outputs.cache-hit != 'true' shell: bash - working-directory: ${{ inputs.working-directory }} \ No newline at end of file + working-directory: ${{ inputs.working-directory }} From 7acb66f8226c9170009a774bfcec671b097ebe0f Mon Sep 17 00:00:00 2001 From: Joshua Li Date: Mon, 15 Dec 2025 17:42:22 -0800 Subject: [PATCH 2/2] plz to fmt string --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 407290f..fbd8ea8 100644 --- a/action.yml +++ b/action.yml @@ -27,7 +27,7 @@ runs: id: setup-python with: python-version: ${{ inputs.python-version }} - python-version-file: ${{ hashFiles(inputs.working-directory + '/.python-version') == '' && '' || inputs.working-directory + '/.python-version' }} + python-version-file: ${{ hashFiles(format('{0}/.python-version', inputs.working-directory)) == '' && '' || format('{0}/.python-version', inputs.working-directory) }} - run: echo '::remove-matcher owner=python::' shell: bash