Skip to content

Commit

Permalink
allow steting mtime with envvar, show default
Browse files Browse the repository at this point in the history
  • Loading branch information
purarue committed Aug 29, 2023
1 parent c4fdad4 commit 3b83b0d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion mpv_history_daemon/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,9 @@ def parse(data_files: Sequence[str], all_events: bool, debug: bool) -> None:
"--mtime-seconds",
type=int,
default=3600,
show_default=True,
envvar="MPV_HISTORY_MTIME_SECONDS",
show_envvar=True,
help="If files have been modified in this amount of time, don't merge them",
)
def merge(
Expand All @@ -145,7 +148,7 @@ def merge(
"""
merges multiple files into a single merged event file
"""
json_files = list(_resolve_paths(data_files))
json_files = list(_resolve_paths(list(data_files)))
if move is not None:
move.mkdir(parents=True, exist_ok=True)
res = merge_files(json_files, mtime_seconds_since=mtime_seconds)
Expand Down

0 comments on commit 3b83b0d

Please sign in to comment.