Skip to content

Commit

Permalink
fix: make beet.contrib.load work with absolute paths
Browse files Browse the repository at this point in the history
  • Loading branch information
vberlier committed Nov 8, 2021
1 parent 8926d90 commit 4971c40
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion beet/contrib/load.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
]


from glob import glob
from typing import List

from pydantic import BaseModel
Expand All @@ -28,5 +29,5 @@ def load(ctx: Context, opts: LoadOptions):
"""Plugin that loads data packs and resource packs."""
for config, pack in zip([opts.resource_pack, opts.data_pack], ctx.packs):
for pattern in config:
for path in ctx.directory.glob(pattern):
for path in glob(str(ctx.directory / pattern)):
pack.load(path)

0 comments on commit 4971c40

Please sign in to comment.