Copy and Renaming files
Hi there :)
I'm quite new to Linux and bash scripting, and I've hit a roadblock in a script I'm writing. At the moment I have it so that a user can enter a file path and the name of an editor, like pico, and it will automatically bring up their file for them to edit. I am trying to figure out how to add code to this so that the file will be copied before any edits and saved as a separate file from the main file. I don't know how to copy the contents of a file, or a file before it's been edited, and I don't know how to write code to automatically generate a name for the previous versions of the file. Below is the code that I have written so far: Code:
echo "Please Enter a Text Editor: " Any help would be greatly appreciated :) |
How about:
Code:
#!/bin/bash Evo2. |
All times are GMT -5. The time now is 05:09 PM. |