mirror of
https://github.com/actions/setup-python.git
synced 2024-12-22 13:42:09 -05:00
Get poetry cache implementation when requested
This commit is contained in:
parent
59cb3f4919
commit
95824fd246
1 changed files with 5 additions and 1 deletions
|
@ -1,9 +1,11 @@
|
|||
import PipCache from './pip-cache';
|
||||
import PipenvCache from './pipenv-cache';
|
||||
import PoetryCache from './poetry-cache';
|
||||
|
||||
export enum PackageManagers {
|
||||
Pip = 'pip',
|
||||
Pipenv = 'pipenv'
|
||||
Pipenv = 'pipenv',
|
||||
Poetry = 'poetry'
|
||||
}
|
||||
|
||||
export function getCacheDistributor(
|
||||
|
@ -16,6 +18,8 @@ export function getCacheDistributor(
|
|||
return new PipCache(pythonVersion, cacheDependencyPath);
|
||||
case PackageManagers.Pipenv:
|
||||
return new PipenvCache(pythonVersion, cacheDependencyPath);
|
||||
case PackageManagers.Poetry:
|
||||
return new PoetryCache(pythonVersion, cacheDependencyPath);
|
||||
default:
|
||||
throw new Error(`Caching for '${packageManager}' is not supported`);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue