Live Chat!

Substitute a Keyword In a File

* * * *   1 votos

October 9th, 2006 liewsheng

Sometime I need to replace a keyword with another, I can’t just open a file and substitute 1 by 1. It is faster to using a single command line. There have more than 2 ways to do it, but I prefer this 2 command: perl and sed.
To substitute a word ‘abc’ to ‘def’ in [...]

Posted in Text Manipulation, perl, sed | Hits: 5647 | 2 Comments »

convert perl scripts into binaries

          0 votos

September 26th, 2006 mysurface

You can covert perl script into ELF binary files, c source code, bytecode etc. You do this my using perlcc.
You can have list of examples by just
man perlcc
But here, i gonna only show you few. First let us generate a perl script, create a file call hello
#!/usr/bin/perl
print “hello world. “;
Convert it into executable,
chmod +x hello
Try [...]

Posted in Developer, Misc, file, perl, perlcc | Hits: 6410 | No Comments »