Reputation: 6327
I have a text file and I wish to remove its first character with command line batch file.
I cant read the content of the file to a var with set /p var= <myfile
because its a big file ( > 8KB)
I just need the first character, if its a whitespace, to remove it.
Upvotes: 1
Views: 246
Reputation: 41287
Using GnuSed:
@echo off
sed "1s/^[ \t]//" file.txt >file2.txt
Thanks to Endoro for the simplification.
Upvotes: 2