Update on 30 Aug: A new plugin has been released that is compliant with the new plugin naming scheme. See http://www.grails.org/FCKeditor+plugin, unless for legacy reasons you need the old plugin, there is no need to keep using it.
Update on 22nd Aug 2008: As of Grails 1.0.3 the problem is still there, installed on my new mac and got the same problem. Only change for 1.0.3 is that the line numbers below are out by about 10 lines, apart from that everything else is the same.
After a discussion on the grails dev list, it has come to light that there is a “temporary hack” that allows FCK editor to install under Grails 1.0 RC4. Basically it comes down to commenting out some of the error checking code in the InstallPlugin script. Although, normally I would not advertise this sort of behaviour, it appears that at this moment in time it’s the quickest way to get this plug in working. Thanks to Juergen Melzer for suggesting this possibility.
Editing the file is actually quite trivial, and is described below:
- Open a command line or explorer and change the directory to the grails RC4 home directory.
- Change into the scripts sub-directory.
- Open file InstallPlugin.groovy using your favourite editor.
- Goto line number 165. For reference it should look like “if(!pluginManager.hasGrailsPlugin(pluginName)) {“
- Comment from the start of this line until after the else, but before the opening brace on line 175
The changed section should look like the following (for formatting <BR> indicates added line breaks):
164
165 /* if(!pluginManager.hasGrailsPlugin(pluginName)) {
166 Ant.delete(dir:"${pluginsBase}/${fullPluginName}")
167 clean()
168 def plugin = pluginManager.getFailedPlugin(pluginName)
169
170 Assert.notNull plugin, "Grails Bug: If the plugin wasn’t loaded it <BR>
should be in the failed plugins list, but is not. Please report the issue."
171
172 println "Failed to install plug-in [${fullPluginName}]. Missing <BR>
dependencies: ${plugin.dependencyNames.inspect()}"
173 event("PluginInstallFailed", [ "Plugin ${fullPluginName} failed to install"])
174 }
175 else
176 */
177 {
178
Plugin’s and multimachine development
I’m also not sure how to deal with plug-ins when working across more than one machine. What I have found by trial and error is that the plug-in needs to be installed onto each machine after checking out the project. It does not seem possible to check the plugin into subversion and checkout on another "clean" machine. (Could somebody confirm this?) Also, If I find out more I will post back.
Comments [4]
On 07-Feb-2008 20:35, Hamlet D'Arcy wrote:
Installing the plugin on Windows creates %HOME%\.grails\1.0-RC4\plugins\fck-editor folder and updates the %HOME%\.grails\1.0-RC4\plugins\plugins-list.xml file
I'm guessing these are the files that stop you from cleanly working across machines. (the plugins-list.xml file contains metadata about what plugins are installed).
On 14-Feb-2008 07:50, docblue wrote:
Many thanx to Dave Cherry and Juergen Melzer.
You saved my day.
On 15-Feb-2008 12:00, paul wrote:
Thanks a lot for the tips, they have been very helpful in my project as well!
On 09-Apr-2008 11:42, Marc Palmer wrote:
You can check in plugins/plugin-folderX into SVN fine. No need to check in the ZIPs. We do this all the time. The only hassle is when upgrading plugins you have to svn rm the plugins/pluginfolder first and commit, then install-plugin to escape SVN "is not a working copy / missing admin area" hell.
In Grails 1.1 we plan to have an improved plugin mechanism where you don't need to worry about this and can just put the zip in SVN - and grails will auto unpackage plugins if they are not already extracted, therefore solving this problem.
I thought the hyphen problem in plugin names was fixed in 1.0.2 but it seems not - I still can't install fck-editor. Bad news.