I have
1. Lorem He he he % not sure spelling 2. Lorem ipsun I want to have
\textbf{1. Lorem} He he he % not sure spelling \textbf{2. Lorem} ipsun My pseudocode attempt
perl -000pe 's/\n\n\d./; s/\n\d.\n\\textbf\{ /g; s/$/\}/' which is based on my two previous questions about regex here. I try to match the thing which starts with a number. Replace the beginning of the match and the end of the match.
The code gives me
Backslash found where operator expected at -e line 1, near "s/\n\n\d./; s/\" Backslash found where operator expected at -e line 1, near "n\" Backslash found where operator expected at -e line 1, near "n\" Backslash found where operator expected at -e line 1, near "textbf\" Backslash found where operator expected at -e line 1, near "$/\" (Missing operator before \?) syntax error at -e line 1, near "s/\n\n\d./; s/\" Execution of -e aborted due to compilation errors. How can you bold the given text?