beet-observer 0.2.0__tar.gz → 0.2.1__tar.gz

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: beet-observer
3
- Version: 0.2.0
3
+ Version: 0.2.1
4
4
  Summary: A beet plugin to automatically generate overlays from previous datapacks
5
5
  License: MIT
6
6
  Author: BPR02
@@ -1,3 +1,3 @@
1
- __version__ = "0.2.0"
1
+ __version__ = "0.2.1"
2
2
 
3
3
  from .plugin import *
@@ -65,7 +65,7 @@ def gen_dp_overlays(ctx: Context, ctx_overlay: Context, overlay_dir: str) -> Non
65
65
  for overlay in ctx.data.overlays:
66
66
  # check if it's the top-level overlay
67
67
  if overlay == ctx.meta["observer"]["default_dir_dp"]:
68
- # delete pack.mcmeta from overlay (requuired for tests)
68
+ # delete pack.mcmeta from overlay (required for tests)
69
69
  default_dir = ctx.meta["observer"]["default_dir_dp"]
70
70
  if ctx.data.overlays[default_dir].mcmeta:
71
71
  del ctx.data.overlays[default_dir].mcmeta
@@ -91,7 +91,8 @@ def gen_dp_overlays(ctx: Context, ctx_overlay: Context, overlay_dir: str) -> Non
91
91
  )
92
92
 
93
93
  # save overlay entries in pack.mcmeta
94
- ctx.data.mcmeta.data.update({"overlays": {"entries": entries}})
94
+ if len(entries) > 0:
95
+ ctx.data.mcmeta.data.update({"overlays": {"entries": entries}})
95
96
 
96
97
 
97
98
  def check_registry(
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "beet-observer"
3
- version = "0.2.0"
3
+ version = "0.2.1"
4
4
  description = "A beet plugin to automatically generate overlays from previous datapacks"
5
5
  authors = ["BPR02 <dev@bpr02.com>"]
6
6
  license = "MIT"
File without changes
File without changes