Mercurial > hgrepos > Python > apps > py-cutils
changeset 8:048b97213a23
Change the default algorithm to SHA1 to be compatible with Perl's shasum
| author | Franz Glasner <fzglas.hg@dom66.de> |
|---|---|
| date | Fri, 04 Dec 2020 15:18:40 +0100 |
| parents | 47b4c98e4d40 |
| children | 81f28bf89c26 |
| files | shasum.py |
| diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/shasum.py Fri Dec 04 15:16:20 2020 +0100 +++ b/shasum.py Fri Dec 04 15:18:40 2020 +0100 @@ -28,7 +28,7 @@ fromfile_prefix_chars='@') aparser.add_argument( "--algorithm", "-a", action="store", type=argv2algo, - help="1, 224, 256 (default), 384, 512, 3-224, 3-256, 3-384, 3-512, blake2b, blake2s, md5") + help="1 (default), 224, 256, 384, 512, 3-224, 3-256, 3-384, 3-512, blake2b, blake2s, md5") aparser.add_argument( "--binary", "-b", action="store_false", dest="text_mode", default=False, help="read in binary mode (default)") @@ -48,7 +48,7 @@ sys.exit(78) # :manpage:`sysexits(3)` EX_CONFIG if not opts.algorithm: - opts.algorithm = argv2algo("256") + opts.algorithm = argv2algo("1") if opts.bsd: out = out_bsd
