Safer File Handling in skEdit
Published January 18, 2004
Been working on improved file handling in skEdit. What I mean in this case is that skEdit will maintain a whitelist of text file types and a whitelist of image file types. When running a multi-file search and replace, only files you have explicitly defined as text files will be searched. skEdit will ship with a default list of text files, that should cover most files. When you try to open a file, skEdit will compare its type to the whitelist. If it a text or image file, it will be treated accordingly. If it is some other type, a sheet will drop down, asking you how to treat that file type.
The whitelist is organized into categories. For example, the PHP category has all of the PHP filetypes. You will be able to 'link' things like syntax highlighting and code-hinting to a category. So, after adding a new filetype to the PHP category, skEdit will automatically use PHP highlighting and code-hinting for that filetype.
This system should make it easier to tell skEdit how to deal with files and will prevent the search and replace from corrupting files its not supposed to search. I've got quite a bit of it up and running. Just need to finish up a couple loose ends and do the 'linking' part.
you might already have your work load to deal with... but, have you thought of adding an XML parser/editor? there's a real need on our platform: i only know about two and they're java (did i say sloooooow?)
misteurti on January 20, 2004 #It's something I would like to do eventually. It's a rather large task, even if you use 3rd-party, open-source libraries to do most of the heavy work. So, it probably won't become a priority until a number of other things have been completed.
Sean Kelly on January 20, 2004 #"it probably won't become a priority until a number of other things have been completed"
i know and you're doing a great job!
misteurti on January 20, 2004 #Looking forward to the whitelist. As you might recall, got bit a few weeks ago by the current blacklist scheme, when files I had not intended were being searched and changed. A whitelist is a much cleaner way to go.
Keep up the good work!
Mike May on January 20, 2004 #