Printing a new file over the old file using cat
I have a script running that will read and print out this file. Right now I am using the following code:
Code:
#!/bin/sh And this code will print it out each time over and over again taking up multiple lines. The file is four lines of text. Is there anyway to just print the 4 lines and then when it comes time to print again....just print over the previous four lines so that there is always only 4 lines of text printed instead of 4 then 8 then 12 then 16.....etc? |
Use redirection
Code:
#!/bin/sh |
I thnk the simplest solution is:-
Code:
#!/bin/sh |
I tried adding clear like the last post suggested and got a "clear not found error." I also tried using the redirection approach suggested and got no output whatsoever. Is there any other way that this task could be done?
|
Try typing "which clear" in your terminal to see if you have clear on your system - it should be there. If it is add the full path to your script.
Code:
#!/bin/sh |
All times are GMT -5. The time now is 08:33 PM. |