diff --git a/src/pip_deepfreeze/sync.py b/src/pip_deepfreeze/sync.py index 769d5b0..5d81096 100644 --- a/src/pip_deepfreeze/sync.py +++ b/src/pip_deepfreeze/sync.py @@ -20,9 +20,9 @@ get_temp_path_in_dir, log_debug, log_info, + make_frozen_requirements_path, + make_frozen_requirements_paths, make_project_name_with_extras, - make_requirements_path, - make_requirements_paths, normalize_req_line, open_with_rollback, run_commands, @@ -55,7 +55,7 @@ def sync( ) with merged_constraints_path.open(mode="w", encoding="utf-8") as constraints: for req_line in prepare_frozen_reqs_for_upgrade( - make_requirements_paths(project_root, extras), + make_frozen_requirements_paths(project_root, extras), constraints_path, upgrade_all, to_upgrade, @@ -73,7 +73,7 @@ def sync( python, project_root, extras ) for extra, frozen_reqs in frozen_reqs_by_extra.items(): - requirements_frozen_path = make_requirements_path(project_root, extra) + requirements_frozen_path = make_frozen_requirements_path(project_root, extra) with open_with_rollback(requirements_frozen_path) as f: print("# frozen requirements generated by pip-deepfreeze", file=f) # output pip options in main requirements only diff --git a/src/pip_deepfreeze/utils.py b/src/pip_deepfreeze/utils.py index 0347fe7..5c18817 100644 --- a/src/pip_deepfreeze/utils.py +++ b/src/pip_deepfreeze/utils.py @@ -182,16 +182,16 @@ def run_commands(commands: Sequence[str], cwd: Path, command_type: str) -> None: ) -def make_requirements_path(project_root: Path, extra: Optional[str]) -> Path: +def make_frozen_requirements_path(project_root: Path, extra: Optional[str]) -> Path: if extra: return project_root / f"requirements-{extra}.txt" else: return project_root / "requirements.txt" -def make_requirements_paths( +def make_frozen_requirements_paths( project_root: Path, extras: Sequence[str] ) -> Iterator[Path]: - yield make_requirements_path(project_root, None) + yield make_frozen_requirements_path(project_root, None) for extra in extras: - yield make_requirements_path(project_root, extra) + yield make_frozen_requirements_path(project_root, extra)