How do I remove a special character in a file?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
1
down vote

favorite












I had to use OCR to get the text of a very large script I did not want to type by hand.



I have multiple lines like this



echo "<91>ps <97>eF|grep...


It should read;



echo "`ps -eF|grep...


Even with ":set list" the only thing I see is <91> and <97>



I tried this and other ASCII characters to insert the back quote:



sed -e 's/'$(echo "97")'/`/g'


to no avail.



Either I'm doing this all wrong or using the wrong control values.



Can you suggest something else?







share|improve this question



















  • what does hexdump or xxd show for the relevant contents of the script?
    – thrig
    Jun 27 at 18:39










  • 0000002896 | ".ps .eF|grep "|
    – Marinaio
    Jun 27 at 19:15










  • Are they periods?
    – Marinaio
    Jun 27 at 19:15














up vote
1
down vote

favorite












I had to use OCR to get the text of a very large script I did not want to type by hand.



I have multiple lines like this



echo "<91>ps <97>eF|grep...


It should read;



echo "`ps -eF|grep...


Even with ":set list" the only thing I see is <91> and <97>



I tried this and other ASCII characters to insert the back quote:



sed -e 's/'$(echo "97")'/`/g'


to no avail.



Either I'm doing this all wrong or using the wrong control values.



Can you suggest something else?







share|improve this question



















  • what does hexdump or xxd show for the relevant contents of the script?
    – thrig
    Jun 27 at 18:39










  • 0000002896 | ".ps .eF|grep "|
    – Marinaio
    Jun 27 at 19:15










  • Are they periods?
    – Marinaio
    Jun 27 at 19:15












up vote
1
down vote

favorite









up vote
1
down vote

favorite











I had to use OCR to get the text of a very large script I did not want to type by hand.



I have multiple lines like this



echo "<91>ps <97>eF|grep...


It should read;



echo "`ps -eF|grep...


Even with ":set list" the only thing I see is <91> and <97>



I tried this and other ASCII characters to insert the back quote:



sed -e 's/'$(echo "97")'/`/g'


to no avail.



Either I'm doing this all wrong or using the wrong control values.



Can you suggest something else?







share|improve this question











I had to use OCR to get the text of a very large script I did not want to type by hand.



I have multiple lines like this



echo "<91>ps <97>eF|grep...


It should read;



echo "`ps -eF|grep...


Even with ":set list" the only thing I see is <91> and <97>



I tried this and other ASCII characters to insert the back quote:



sed -e 's/'$(echo "97")'/`/g'


to no avail.



Either I'm doing this all wrong or using the wrong control values.



Can you suggest something else?









share|improve this question










share|improve this question




share|improve this question









asked Jun 27 at 18:22









Marinaio

898




898











  • what does hexdump or xxd show for the relevant contents of the script?
    – thrig
    Jun 27 at 18:39










  • 0000002896 | ".ps .eF|grep "|
    – Marinaio
    Jun 27 at 19:15










  • Are they periods?
    – Marinaio
    Jun 27 at 19:15
















  • what does hexdump or xxd show for the relevant contents of the script?
    – thrig
    Jun 27 at 18:39










  • 0000002896 | ".ps .eF|grep "|
    – Marinaio
    Jun 27 at 19:15










  • Are they periods?
    – Marinaio
    Jun 27 at 19:15















what does hexdump or xxd show for the relevant contents of the script?
– thrig
Jun 27 at 18:39




what does hexdump or xxd show for the relevant contents of the script?
– thrig
Jun 27 at 18:39












0000002896 | ".ps .eF|grep "|
– Marinaio
Jun 27 at 19:15




0000002896 | ".ps .eF|grep "|
– Marinaio
Jun 27 at 19:15












Are they periods?
– Marinaio
Jun 27 at 19:15




Are they periods?
– Marinaio
Jun 27 at 19:15










1 Answer
1






active

oldest

votes

















up vote
0
down vote













Looks like cp1252 (or similar). See What characters do not directly map from Cp1252 to UTF-8?. Use recode to repair it...






share|improve this answer





















  • Thanks. Unfortunately recode isn't available on my system (neither is installing it)
    – Marinaio
    Jun 28 at 15:04










Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);








 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f452293%2fhow-do-i-remove-a-special-character-in-a-file%23new-answer', 'question_page');

);

Post as a guest






























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
0
down vote













Looks like cp1252 (or similar). See What characters do not directly map from Cp1252 to UTF-8?. Use recode to repair it...






share|improve this answer





















  • Thanks. Unfortunately recode isn't available on my system (neither is installing it)
    – Marinaio
    Jun 28 at 15:04














up vote
0
down vote













Looks like cp1252 (or similar). See What characters do not directly map from Cp1252 to UTF-8?. Use recode to repair it...






share|improve this answer





















  • Thanks. Unfortunately recode isn't available on my system (neither is installing it)
    – Marinaio
    Jun 28 at 15:04












up vote
0
down vote










up vote
0
down vote









Looks like cp1252 (or similar). See What characters do not directly map from Cp1252 to UTF-8?. Use recode to repair it...






share|improve this answer













Looks like cp1252 (or similar). See What characters do not directly map from Cp1252 to UTF-8?. Use recode to repair it...







share|improve this answer













share|improve this answer



share|improve this answer











answered Jun 27 at 20:01









Thomas Dickey

49k583154




49k583154











  • Thanks. Unfortunately recode isn't available on my system (neither is installing it)
    – Marinaio
    Jun 28 at 15:04
















  • Thanks. Unfortunately recode isn't available on my system (neither is installing it)
    – Marinaio
    Jun 28 at 15:04















Thanks. Unfortunately recode isn't available on my system (neither is installing it)
– Marinaio
Jun 28 at 15:04




Thanks. Unfortunately recode isn't available on my system (neither is installing it)
– Marinaio
Jun 28 at 15:04












 

draft saved


draft discarded


























 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f452293%2fhow-do-i-remove-a-special-character-in-a-file%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

Peggy Mitchell

Palaiologos

The Forum (Inglewood, California)