Sign in to follow this  
Followers 0
HoangTuHieu

How to keep trace a file after it's renamed or moved?

4 posts in this topic

Hi guys!

I want to figure a way to keep trace of a number of certain files. Let's say I have a list of files at a time, and the next time I run the code, if any file was moved or renamed, it would be able to notice and report the new name or new path corresponding to the old one. It would be great if it's gonna notice had the file been deleted or any other type of changes made since the last time it checked. Can anyone help or throw me an idea?

It would help also if anyone can tell me is there a way to identify a file other than using a long full name?

I've been searching for a while but without result :unsure:.

Share this post


Link to post
Share on other sites



hi HoangTuHieu,

How about making a file indexing script? :unsure:

Question #1: What do you mean file indexing?

Answer #1: Specifically speaking, file indexing (here) refers to the process of creating and maintaining a relational database of file attributes.

A synopsis/roadmap:

Index the files (using SQLite, and a recursive implementation of _FileListToArray() perhaps), with hashes (), filename, filepath etc.

After some changes, index them (the files) again then compare results of indexing with some nifty SQL queries (learn SQL), and display/write a report to your liking using one (or many) of the various available methods of displaying/

Hope this helps. :>

-smartee

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

Hi guys!

I want to figure a way to keep trace of a number of certain files. Let's say I have a list of files at a time, and the next time I run the code, if any file was moved or renamed, it would be able to notice and report the new name or new path corresponding to the old one. It would be great if it's gonna notice had the file been deleted or any other type of changes made since the last time it checked. Can anyone help or throw me an idea?

It would help also if anyone can tell me is there a way to identify a file other than using a long full name?

I've been searching for a while but without result :unsure:.

Maybe will help?

Or

Edited by JoHanatCent

Share this post


Link to post
Share on other sites

Wow, this is quite a new stuff to me. Thanks for your guides, Smartee and JohanatCent. I haven't really found my answer yet but it's a lot to play with now. I'll be back later when I get some progress.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0