Skip to content

Commit

Permalink
improvements/fixes for --no_cache_galaxy
Browse files Browse the repository at this point in the history
- allow for forks and branches
- tar extracts into `"galaxy-" + branch`, hence we need to add `--strip-components 1`
  • Loading branch information
bernt-matthias committed Jul 17, 2023
1 parent 135cef8 commit b08209e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions planemo/galaxy/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -1230,9 +1230,12 @@ def _install_galaxy(ctx, galaxy_root, env, kwds):

def _install_galaxy_via_download(ctx, galaxy_root, env, kwds):
branch = _galaxy_branch(kwds)
source = _galaxy_source(kwds)
if source.startswith("https://github.com/"):
source = source[len("https://github.com/"):]
untar_to(
"https://codeload.github.com/galaxyproject/galaxy/tar.gz/" + branch,
tar_args=["-xvzf", "-", "galaxy-" + branch],
f"https://codeload.github.com/{source}/tar.gz/{branch}",
tar_args=["--strip-components", "1", "-xvzf", "-", "galaxy-" + branch],
dest_dir=galaxy_root,
)
_install_with_command(ctx, galaxy_root, env, kwds)
Expand Down

0 comments on commit b08209e

Please sign in to comment.