Skip to content

Commit a0c593a

Browse files
committed
zip-safe
- vis. #90 (comment)
1 parent 2cd884a commit a0c593a

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

gitfame/_gitfame.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -480,16 +480,15 @@ def main(args=None):
480480
log.debug(args)
481481
if args.manpath is not None:
482482
import sys
483-
from os import fspath, path
484-
from shutil import copyfile
483+
from pathlib import Path
485484

486485
try: # py<3.9
487486
import importlib_resources as resources
488487
except ImportError:
489488
from importlib import resources
490-
fi = fspath(resources.files('gitfame').resolve() / 'git-fame.1')
491-
fo = path.join(args.manpath, 'git-fame.1')
492-
copyfile(fi, fo)
489+
fi = resources.files('gitfame') / 'git-fame.1'
490+
fo = Path(args.manpath) / 'git-fame.1'
491+
fo.write_bytes(fi.read_bytes())
493492
log.info("written:%s", fo)
494493
sys.exit(0)
495494

0 commit comments

Comments
 (0)