Skip to content

Commit

Permalink
Merge branch 'hotfix/2.1.1'
Browse files Browse the repository at this point in the history
* hotfix/2.1.1:
  Version 2.1.1
  Projects can now also be symlinked to subdirs of symlinked projects (#8)
  Fix help string for --list-archs
  • Loading branch information
wdeconinck committed Mar 21, 2024
2 parents 140c29b + 6bcb188 commit 814873b
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 4 deletions.
2 changes: 1 addition & 1 deletion bin/ecbundle-build
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def main():
parser.add_argument('--arch',
help='Path to directory containing architecture info')
parser.add_argument('--list-archs',
help='Path to directory containing architecture info',
help='List the available architectures',
action='store_true')

parser.add_argument('--src-dir',
Expand Down
2 changes: 1 addition & 1 deletion ecbundle/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@
from ecbundle.project import * # noqa
from ecbundle.util import * # noqa

__version__ = "2.1.0"
__version__ = "2.1.1"
2 changes: 2 additions & 0 deletions ecbundle/download.py
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,8 @@ def download_data(data_packages, download_dir):
or project.dir() in [p.name for p in git_projects]
or os.path.dirname(project.dir()) in [p.name for p in git_projects]
or project.dir() in [p.name() for p in symlink_projects]
or os.path.dirname(project.dir())
in [p.name() for p in symlink_projects]
):
symlink_projects.append(project)
else:
Expand Down
File renamed without changes.
16 changes: 16 additions & 0 deletions tests/bundle_download/bundle_symlinked_subdir.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
### Bundle

name : test-symlink-subdir

projects :
- project1 :
git : ${BITBUCKET}/user/project1
version : 0.0.1
bundle : false

- symlink_project1 :
dir : project1

- subdir1 :
dir : symlink_project1/subdir1
bundle : false
17 changes: 15 additions & 2 deletions tests/bundle_download/test_download.py
Original file line number Diff line number Diff line change
Expand Up @@ -313,14 +313,27 @@ def test_download_https(args, here, watcher):
assert "git -c advice.detachedHead=false checkout 0.0.1" in watcher.output


def test_symlink_subdir(args, here, project1_subdir1_dir, watcher):
def test_symlink_cloned_project_subdir(args, here, project1_subdir1_dir, watcher):
"""
Add cloned project subdir as a symlinked bundle entry
"""
args["bundle"] = "%s" % (here / "bundle_subdir.yml")
args["bundle"] = "%s" % (here / "bundle_cloned_subdir.yml")

with watcher:
BundleDownloader(**args).download()

assert ("Following projects are symlinked in") in watcher.output
assert "- subdir1 (project1/subdir1)" in watcher.output


def test_symlink_symlinked_project_subdir(args, here, project1_subdir1_dir, watcher):
"""
Add symlinked project subdir as a symlinked bundle entry
"""
args["bundle"] = "%s" % (here / "bundle_symlinked_subdir.yml")

with watcher:
BundleDownloader(**args).download()

assert ("Following projects are symlinked in") in watcher.output
assert "- subdir1 (symlink_project1/subdir1)" in watcher.output

0 comments on commit 814873b

Please sign in to comment.