Skip to content

Commit

Permalink
Fix DOS to UNIX conversion
Browse files Browse the repository at this point in the history
Original method corrupted files by deleting all leading capital 'M' on each line, not just ^M line endings.
  • Loading branch information
BLooD-DoG authored Aug 21, 2024
1 parent 99a235c commit e59ad3f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/install_nquakesv.sh
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ nqnecho "* Removing distribution files..."
# Convert DOS files to UNIX
nqnecho "* Converting DOS files to UNIX..."
for file in $(find ${directory} -iname "*.cfg" -or -iname "*.txt" -or -iname "*.sh" -or -iname "README"); do
[ -f "${file}" ] && sed -i 's/^M//g' ${file}
[ -f "${file}" ] && sed -i 's/^M$//' ${file}
done
nqecho "done"

Expand Down

0 comments on commit e59ad3f

Please sign in to comment.