fmt lint etc. pp.

This commit is contained in:
Manuel Barkhau 2020-09-06 21:44:23 +00:00
parent 75563672b4
commit 31f9d51bf3
7 changed files with 32 additions and 16 deletions

View file

@ -15,14 +15,15 @@ import logging
import subprocess as sp
import click
import pycalver2.version as v2version
import pycalver.cli as v1cli
import pycalver2.cli as v2cli
import pycalver.version as v1version
import pycalver2.version as v2version
from pycalver import vcs
from pycalver import config
# import pycalver2.cli as v2cli
_VERBOSE = 0

View file

@ -77,7 +77,9 @@ def iter_file_paths(
def rewrite_lines(
pattern_strs: typ.List[str], new_vinfo: version.VersionInfo, old_lines: typ.List[str]
pattern_strs: typ.List[str],
new_vinfo : version.VersionInfo,
old_lines : typ.List[str],
) -> typ.List[str]:
"""Replace occurances of pattern_strs in old_lines with new_vinfo.
@ -112,7 +114,9 @@ def rewrite_lines(
def rfd_from_content(
pattern_strs: typ.List[str], new_vinfo: version.VersionInfo, content: str
pattern_strs: typ.List[str],
new_vinfo : version.VersionInfo,
content : str,
) -> RewrittenFileData:
r"""Rewrite pattern occurrences with version string.
@ -137,7 +141,8 @@ def rfd_from_content(
def iter_rewritten(
file_patterns: config.PatternsByGlob, new_vinfo: version.VersionInfo
file_patterns: config.PatternsByGlob,
new_vinfo : version.VersionInfo,
) -> typ.Iterable[RewrittenFileData]:
r'''Iterate over files with version string replaced.