aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar MarkKoz <[email protected]>2020-03-11 10:57:38 -0700
committerGravatar MarkKoz <[email protected]>2020-03-11 10:57:38 -0700
commitc392ff64ac4c64ef4baa9834e6e0046e415ce0d9 (patch)
treeeecfb305b99f99c0e0ae5b6856de6cfe629defce
parentCI: don't do a user install for pre-commit venv (diff)
CI: rename UsePythonVersion task
"python" is a shorter and clearer name.
-rw-r--r--azure-pipelines.yml18
1 files changed, 9 insertions, 9 deletions
diff --git a/azure-pipelines.yml b/azure-pipelines.yml
index 3557410c6..16e4489c0 100644
--- a/azure-pipelines.yml
+++ b/azure-pipelines.yml
@@ -26,7 +26,7 @@ jobs:
steps:
- task: UsePythonVersion@0
displayName: 'Set Python version'
- name: PythonVersion
+ name: python
inputs:
versionSpec: '3.8.x'
addToPath: true
@@ -34,11 +34,11 @@ jobs:
- task: Cache@2
displayName: 'Restore Python environment'
inputs:
- key: python | $(Agent.OS) | "$(PythonVersion.pythonLocation)" | 0 | ./Pipfile | ./Pipfile.lock
+ key: python | $(Agent.OS) | "$(python.pythonLocation)" | 0 | ./Pipfile | ./Pipfile.lock
restoreKeys: |
- python | "$(PythonVersion.pythonLocation)" | 0 | ./Pipfile.lock
- python | "$(PythonVersion.pythonLocation)" | 0 | ./Pipfile
- python | "$(PythonVersion.pythonLocation)" | 0
+ python | "$(python.pythonLocation)" | 0 | ./Pipfile.lock
+ python | "$(python.pythonLocation)" | 0 | ./Pipfile
+ python | "$(python.pythonLocation)" | 0
cacheHitVar: PY_ENV_RESTORED
path: $(PYTHONUSERBASE)
@@ -59,16 +59,16 @@ jobs:
# pipenv entirely, which is too dumb to know it should use the system interpreter rather than
# creating a new venv.
- script: |
- printf '%s\n%s' '#!/bin/bash' '"${@:2}"' > $(PythonVersion.pythonLocation)/bin/pipenv \
- && chmod +x $(PythonVersion.pythonLocation)/bin/pipenv
+ printf '%s\n%s' '#!/bin/bash' '"${@:2}"' > $(python.pythonLocation)/bin/pipenv \
+ && chmod +x $(python.pythonLocation)/bin/pipenv
displayName: 'Mock pipenv binary'
- task: Cache@2
displayName: 'Restore pre-commit environment'
inputs:
- key: pre-commit | "$(PythonVersion.pythonLocation)" | 0 | .pre-commit-config.yaml
+ key: pre-commit | "$(python.pythonLocation)" | 0 | .pre-commit-config.yaml
restoreKeys: |
- pre-commit | "$(PythonVersion.pythonLocation)" | 0
+ pre-commit | "$(python.pythonLocation)" | 0
path: $(PRE_COMMIT_HOME)
# pre-commit's venv doesn't allow user installs - not that they're really needed anyway.