File tree Expand file tree Collapse file tree 2 files changed +5
-8
lines changed
Expand file tree Collapse file tree 2 files changed +5
-8
lines changed Original file line number Diff line number Diff line change @@ -22,13 +22,9 @@ def give_hashblake(file_in, with_this):
2222
2323if __name__ == '__main__' :
2424 if len (sys .argv ) < 2 :
25- print (
26- "Usage: "
27- + sys .argv [0 ]
28- + " github-user [github-project]"
29- )
25+ print ( "Usage: hash.py files_to_copte_hash" )
3026 exit (1 )
31- file = sys .argv [1 ]
27+ files = [ str ( i ) for i in sys .argv [1 :] if str ( i )[ - 3 :]. lower () != ".py" ]
3228
3329 header = (
3430 " MD5"
@@ -53,7 +49,8 @@ def give_hashblake(file_in, with_this):
5349 print (header )
5450 print (line )
5551
56- print ("" +
52+ for file in files :
53+ print ("" +
5754 f"{ give_hash (file , hashlib .md5 )} | " +
5855 f"{ give_hash (file , hashlib .sha1 )} | " +
5956 f"{ give_hash (file , hashlib .sha256 )} | " +
Original file line number Diff line number Diff line change @@ -3,6 +3,6 @@ call C:\WPy64-3890\scripts\env.bat
33cd %~dp0
44
55rem echo %date% %time%>> gdc_counting.txt
6- python hash.py %1 >> hash_counting_%date:/ =_ % .txt
6+ python hash.py %* >> hash_counting_%date:/ =_ % .txt
77
88start notepad.exe hash_counting_%date:/ =_ % .txt
You can’t perform that action at this time.
0 commit comments