mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-04-15 01:51:46 +04:00
Remove use of 'rvm-download' rbenv plugin
This commit is contained in:
parent
5bc56889e9
commit
ab6dab3660
4 changed files with 3 additions and 12 deletions
|
|
@ -91,7 +91,6 @@ def _install_rbenv(
|
|||
# Only install ruby-build if the version is specified
|
||||
if version != C.DEFAULT:
|
||||
plugins_dir = os.path.join(envdir, 'plugins')
|
||||
_extract_resource('ruby-download.tar.gz', plugins_dir)
|
||||
_extract_resource('ruby-build.tar.gz', plugins_dir)
|
||||
|
||||
|
||||
|
|
@ -99,11 +98,8 @@ def _install_ruby(
|
|||
prefix: Prefix,
|
||||
version: str,
|
||||
) -> None: # pragma: win32 no cover
|
||||
try:
|
||||
helpers.run_setup_cmd(prefix, ('rbenv', 'download', version))
|
||||
except CalledProcessError: # pragma: no cover (usually find with download)
|
||||
# Failed to download from mirror for some reason, build it instead
|
||||
helpers.run_setup_cmd(prefix, ('rbenv', 'install', version))
|
||||
# build from source using rbenv + ruby-build
|
||||
helpers.run_setup_cmd(prefix, ('rbenv', 'install', version))
|
||||
|
||||
|
||||
def install_environment(
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -18,11 +18,6 @@ from typing import Sequence
|
|||
REPOS = (
|
||||
('rbenv', 'https://github.com/rbenv/rbenv', '38e1fbb'),
|
||||
('ruby-build', 'https://github.com/rbenv/ruby-build', '9d92a69'),
|
||||
(
|
||||
'ruby-download',
|
||||
'https://github.com/garnieretienne/rvm-download',
|
||||
'09bd7c6',
|
||||
),
|
||||
)
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ def test_uses_system_if_both_gem_and_ruby_are_available(find_exe_mck):
|
|||
|
||||
@pytest.mark.parametrize(
|
||||
'filename',
|
||||
('rbenv.tar.gz', 'ruby-build.tar.gz', 'ruby-download.tar.gz'),
|
||||
('rbenv.tar.gz', 'ruby-build.tar.gz'),
|
||||
)
|
||||
def test_archive_root_stat(filename):
|
||||
with resource_bytesio(filename) as f:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue