Reverse Source Control
-
Are there any Version Control Systems out there that will monitor a a directory and when it detects a change to a file check it in automatically for you, or are there any programs that will do something simliar to this? I have a request that when files are copied over to a directory whether they're new or being replaced their updates are checked into some Source Control environment. Thank You
-
Are there any Version Control Systems out there that will monitor a a directory and when it detects a change to a file check it in automatically for you, or are there any programs that will do something simliar to this? I have a request that when files are copied over to a directory whether they're new or being replaced their updates are checked into some Source Control environment. Thank You
You could always use a FileSystemWatcher in .NET to monitor file changes. Most source control systems have an API that you can hook into programatically.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith
As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
-
Are there any Version Control Systems out there that will monitor a a directory and when it detects a change to a file check it in automatically for you, or are there any programs that will do something simliar to this? I have a request that when files are copied over to a directory whether they're new or being replaced their updates are checked into some Source Control environment. Thank You
You'll wind up with a bunch of needless rubbish in your Version Control System. Never put anything into Version Control unless you're confident that it's correct.
-
You could always use a FileSystemWatcher in .NET to monitor file changes. Most source control systems have an API that you can hook into programatically.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith
As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
But dont you think FileSystemWatcher of .NET kills a lot of CPU. I have used it in a windows service and it started killing almost 50% of CPU all the time. Then I left out that and made a new Timer Thread to manually see the changes to the files. I dont know how many polls the FileSystemWatcher makes in a single second. :confused:
Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.
-
But dont you think FileSystemWatcher of .NET kills a lot of CPU. I have used it in a windows service and it started killing almost 50% of CPU all the time. Then I left out that and made a new Timer Thread to manually see the changes to the files. I dont know how many polls the FileSystemWatcher makes in a single second. :confused:
Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.
Abhishek Sur wrote:
But dont you think FileSystemWatcher of .NET kills a lot of CPU.
No, on our site we use it extensively, watching for files to appear in multiple directories for automatic processing. Perhaps you did not configure it correctly?
Bob Ashfield Consultants Ltd Proud to be a 2009 Code Project MVP
-
Abhishek Sur wrote:
But dont you think FileSystemWatcher of .NET kills a lot of CPU.
No, on our site we use it extensively, watching for files to appear in multiple directories for automatic processing. Perhaps you did not configure it correctly?
Bob Ashfield Consultants Ltd Proud to be a 2009 Code Project MVP
I am doing the same thing. I have used FileSystemWatcher to process some files automatically through a windows service. The windows service watches the FTP folder, so that when a file comes it processes it. I have just created an object of FileSystemWatcher and hooked up its Renamed Event. It generates event properly, and processes it.. But after using this I saw the service always takes 50% of my CPU. It seemed to me odd and just created a Thread myself, which checks after every 1 second. It saved 25% of my CPU now. Dont know where I was wrong. Its really seemed weird to me. :doh:
Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.