2 deleted 1 characters in body
source | link

Starting from the command in question, you can remove the option g (recursive) and add the hat character ^ before the pipe to check only the first occurrencecharacter:

sed 's/^|//' file1.txt

Starting from the command in question, you can remove the option g (recursive) and add the hat character ^ before the pipe to check only the first occurrence:

sed 's/^|//' file1.txt

Starting from the command in question, you can remove the option g (recursive) and add the hat character ^ before the pipe to check only the first character:

sed 's/^|//' file1.txt
1
source | link

Starting from the command in question, you can remove the option g (recursive) and add the hat character ^ before the pipe to check only the first occurrence:

sed 's/^|//' file1.txt