Skip to content

I made a SHA256SUM-Checker-for-Windows, need help! #21481

Answered by airtower-luna
gingshow asked this question in General
Discussion options

You must be logged in to vote
gingshow:

But how can I make the program remove those unnecessary part for me?

Each line in the SHA-256 sums file has the hash, then spaces, then the filename. You can split that using a regular expression with two capturing groups. One thing to consider is how to find the right file(s) in that list. A common approach would be to expect the files in the list exist and have the same name on the local system, and to check them all (nonexistent files get an error message). The pathlib module might be helpful with handling file names.

A few other things I’m thinking of reading that code:

  • When posting code, please use a code block (enclosed in triple backticks, ```). That preserves inden…

Replies: 12 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants