Ok, version 1.0.2 is now on my website.
This brings the following :-
1. Duplicate handling, two files with the same name are now annotated with their respective id’s e.g. two ’Freds’ become ’Fred-1.html’ and ’Fred-2.html’ for instance.
2. You can now checkout SVN repo’s recursively using the new ’checkoutmode’ option. This greatly eases the initial importing and setting up your db mount as an SVN working directory. See the SUBVERSION.TXT file.
3. There is now a Tools directory. This contains modxfs versions of standard linux tools that unfortunately don’t seem to work on fuse mounted file systems e.g. getfattr. So we now have a modxfs-getffatr which if you supply it with the name of an entity returns its attributes, i.e its database properties, an example :-
[steve@cngateway php]$ ../tools/modxfs-getfattr ../modx300/db/modx/Resources/Uncategorized/Comments.html
id:86
type:document
contentType:text/html
longtitle:
description:
alias:
link_attributes:
published:1
pub_date:1970-01-001 00:00:00
unpub_date:1970-01-001 00:00:00
parent:0
isfolder:0
introtext:
richtext:1
template:fusetestforms
menuindex:0
searchable:1
cacheable:1
createdon:1970-01-001 00:00:00
createdby:admin
editedby:admin
editedon:1970-01-001 00:00:00
deleted:0
deletedon:1970-01-001 00:00:00
deletedby:0
publishedon:1970-01-001 00:00:00
publishedby:admin
menutitle:
donthit:0
haskeywords:0
hasmetatags:0
privateweb:0
privatemgr:0
content_dispo:0
hidemenu:0
The attributes are handled smartly, i.e. template id’s are turned into names, user id’s are turned into names etc. You can only read at the mo and I think I’ll keep it this way.
Ok, testing is going well, its getting difficult if not impossible for me to crash the mount point now. but more is needed before I’m happy to release the code out of development, especially on platforms I haven’t got. Please join in if you can. Also I’m becoming a bit blind to this now, fresh eyes are lots better.
I’ve been pleasantly surprised by the fact that if you edit say a resource in the db it is not only reflected through to the mount point but SVN sees it as a change, i.e if you click on its directory and do ’commit’ it is picked up. I was worried this wouldn’t work because of not implementing atime/ctime/utime. I guess SVN must see a file size change.
I want to freeze at this point for a while(other things to look at) but I’ll experiment a bit with Git and Mercurial, see what we get here. Also I’ll do a revo version.
Use MODx, or the cat gets it!
If you take a copy of the modxfs-php script and call it say modxfs-php1, then edit its params to mount a different database, you can run the two scripts, this starts two fuse processes so you have two mounted db’s.
Now in the file manager of your choice if you split the window in two you can have one window in one db and one in the other, so now you can drag and drop entities between the databases. If one(or both) is linked to SVN these changes can be committed of course.
You can have as many mounts as you need and the db’s need not be on the same host.
This is quite nifty for templates, snippets etc but you don’t get any attributes, so for resources you just get pagetitle and content, not published, published on etc. You will have to fill these in manually at the mo.
Possibly in the future we can somehow get the attributes from the source entity using modxfs-getfattr and create with these.
Use MODx, or the cat gets it!
Thanks for the feedback. I will do a revo version and look at the TV editing, also thanks for the warning about PHP 5.3. Its not moving as such at the mo as I was hoping for a little feedback from users like yourself as to its stability etc. In the testing I’ve done, like you say it looks OK so I think it may be time to push it up to a release version. Stay tuned.
Use MODx, or the cat gets it!
Ok, I’ve updated this to allow it work with PHP 5.3 now, so it should cover 5.1, 5.2 and 5.3 versions(I can’t test it against every minor version here BTW but it shouldn’t be sensitive to these variations hopefully) also I’ve put in a configuration option to allow selection of either evo or revo databases(revo databases just don’t have modules at the mo.).
As for mounting TV’s the only sane field I can see to edit here is the default_text field which contains stuff like this ’@EVAL if ($modx->getLoginUserID()) return ’Logout’...’ this is the main guts of the TV I suppose but you don’t get the display_params and the display(control type), these also affect its output. I’ll do this anyway and see how we go.
I’ll release this for devel testing soon now and hopefully sync the full release to Revo’s GA.
Use MODx, or the cat gets it!
Neat, looking forward to the release. Sounds like you have both Revo & Evo working now. How well would setting up two parallel mounts work to move content from Evo to Revo? Obviously it wouldn’t alter the chunks and things to the new format but it could be a quick transfer method.
Yes, you can do this, just copy the code into two directories, configure each one for its own database and mount point then run modxfs-php in both of them, you’ll have two mounted file systems that you can now drag’n’drop between. You can actually do this on as many databases as you like.
I’m just finishing the user guide documentation at the mo, I’ve got one annoying feature to fix to do with integration with subversion but it’s proving to be tricky, I’ll take a view on this over the next few days but if it can’t be done soon I’m still going for the GA release to extra’s next week, it’s not something that can’t be lived with for now, it can be fixed in a point release.
Use MODx, or the cat gets it!
Ok, the good news is I’m pushing the GA release into Extra’s tomorrow barring some really last minute testing fails tonight. The bad news is there is no subversion integration with this release. It’s 90% there but I need to fix the mtime/ctime/atime issue in the mount point to stop Subversion seeing ’svn up’ commands as conflicts, this will also help with all VCS integration. I’ve got the code changes done but its a bit too intrusive to push at the mo, it will be in the next release.
Just looking casually we seem to the first here with this, Wordpress, Joomla and Drupal don’t do this, although this technique was mentioned on Drupal’s forums but never followed up. Anybody seen this for a CMS?
Use MODx, or the cat gets it!