Hi there.
I have a little problem, that I think can easily be solved by making a small application.
I need to manually sort and move a whole bunch of files, with very much random names (2CFDgfjdwFDf43Fs.txt), in some directories.
The directories contains thousands of files each, so it is a heavy task. :-S
However, I thought, it could be automated a bit, or at least made a bit more efficiant than I'm doing it now.
At the moment, I'm opening each file with less.
Then I look through the file, and decide if it should go to one or the other folder.
Then I close the file, and manually move the file with mv.
And start over.
However, this is very inefficiant.
So I had an Idea.
A program that open each file in the current directory, with a certain extension.
Displays the file on the screen, higlights certain keywords that have been predefined either on the command line, or in a configurationfile.
Then I can scroll up and down in the file, with arrowkeys, or space key, just like less.
with Certain keys, I can then tell the program to move it to different folders, depending on what was predefined, again on command line or config file.
And then it opens the next file.
Now, I think this is a simple program, File access and keyboard input.
However, I know nothing or at least very little about C.
I have programmed VisualBasic on windows, but am only just started with Linux and with C.
So I thought I could get this problem solved AND learn from it at the same.
So If any of you C/C++ guys out there could write me a small app with comments, that I can, try out. It would be great.
Regards,.
Brian Levinsen
I have a little problem, that I think can easily be solved by making a small application.
I need to manually sort and move a whole bunch of files, with very much random names (2CFDgfjdwFDf43Fs.txt), in some directories.
The directories contains thousands of files each, so it is a heavy task. :-S
However, I thought, it could be automated a bit, or at least made a bit more efficiant than I'm doing it now.
At the moment, I'm opening each file with less.
Then I look through the file, and decide if it should go to one or the other folder.
Then I close the file, and manually move the file with mv.
And start over.
However, this is very inefficiant.
So I had an Idea.
A program that open each file in the current directory, with a certain extension.
Displays the file on the screen, higlights certain keywords that have been predefined either on the command line, or in a configurationfile.
Then I can scroll up and down in the file, with arrowkeys, or space key, just like less.
with Certain keys, I can then tell the program to move it to different folders, depending on what was predefined, again on command line or config file.
And then it opens the next file.
Now, I think this is a simple program, File access and keyboard input.
However, I know nothing or at least very little about C.
I have programmed VisualBasic on windows, but am only just started with Linux and with C.
So I thought I could get this problem solved AND learn from it at the same.
So If any of you C/C++ guys out there could write me a small app with comments, that I can, try out. It would be great.
Regards,.
Brian Levinsen