On Wed, 2008-03-05 at 17:58 +0100, Enrico Tröger wrote:
On Wed, 5 Mar 2008 16:35:40 +0000, Nick Treleaven nick.treleaven@btinternet.com wrote: I don't like what geanyprj is doing currently. I didn't have a deeper look but Yura, you call reload_project() on every document-activate event? So, everytime a user switch between files, the plugin searches for ".geanyprj" and checks the type of the current project. I really don't like this. Disk-IO on every tab change.
You are correct. But this stuff is going to be in separate plugin that will handle geany native projects (2). It is really very useful for me. No need to bother with open/close projects, with this approach all I care are files. I think it is geany way of doing things. ;-)
Why don't you like Disk-IO on document-activate? Most time it is just access check and it is really quick (no lag in interface). On ftp or sshfs it can takes time (didn't check). Is this is the reason?
As a first step I suggest to write patch that will add "Generate files" and "Type" to project properties.If you have better idea how tag management should be handled lets discuss it.
Furthermore, I don't like the .geanyprj files at all. But of course, some kind of cache is necessary. I'm not sure.
And just while testing the plugin a little bit, it crashed away ;-). Backtrace is attached, steps to reproduce:
- open geany with an open project and some project session files
- load the geanyprj with the plugin manager
- Tools->Project->New
- Name: "tmp" Location: "/tmp" Base path: "/tmp" Generate files: yes Type: All
-> crash on Create.
Thanks, fixed in git.