how to remove hash from output file
hi, i cracked passwords using hashcat and in the output file the lines are in user:hash:pass but i need user:pass.
to do it i did: hashcat64.exe -m 0 --username hashes.txt wordlists
then after it finished: -m 0 --username --show hashes.txt --outfile-format=2 -o cracked.txt      <- this was from a tutorial i found and i would like to not have the hash in the final output file.
--outfile-format 2 combined with --username will only output the username and the password.

What you should know is that -o always appends to the file and therefore the file cracked.txt won't be overridden (or emptied before written).

This means, that whenever you wrote (or instructed hashcat to write) to cracked.txt file in the past, there could be "incorrect" lines before the correct output.
Therefore to test it you need to make sure that you eighter use a completely new file or delete/empty it before you output to the file cracked.txt

The reason why hashcat always appends to a file instead of overriding it, is that this prevents data loss and -o can also be used with --stdout and within a "non-show" run of hashcat and in those cases you normally want to append to the file (and this just makes it more consistent that the output will always be appended to the file with -o)
this happened the first time used. also, i deleted all the contents in the file and saved it when i retried.
I can't reproduce this problem and I now tried a lot of different commands etc.

Which version of hashcat do you use?

make sure that you use the latest release version (3.6 currently).