Project

General

Profile

Creating a plug-in for automatic doxygen generation

Added by Alexandre Tuleu about 13 years ago

Hi,

I am currently thinking about developing a redmine plugin that will automatically generate the documentation of a project from its repository, and display it through redmine. I am still a beginner with ruby and on rails, so I have some question about the feasibility of such project.

First of all, the build process will be costly in computation time. So I was thinking about putting it in a subprocess, and displaying a notice to the user that the documentation he is visiting will be updated soon. In order not to generate the documentation several time I will need to specify in some database that the documentation is beeing build. I will also need to access it in the child process once the build will be finished. So I think i will need to reconnect to the database to avoid a crash ...

So is there in redmine anyway to perform this subprocessing and reconnect to the database ?

Best regards


Replies (3)

RE: Creating a plug-in for automatic doxygen generation - Added by Felix Schäfer about 13 years ago

There's already a plugin to display arbitrary html in a redmine project's "tab" which is typically used to show documentation, generate the documentation from a post-commit hook of your repository, case closed.

RE: Creating a plug-in for automatic doxygen generation - Added by Alexandre Tuleu about 13 years ago

Hi

SO maybe my title was badly formulated, but my question was more on how to to add a subprocess to redmine application. It may also help for development of other plugin that may need lot of computation before to display some thing (like I don't know subnailing a directory of 200 hundred jpeg ...). I am sorry for that.

I already think about the solution of tabs + post-update hook (and already implemented it), but this is not suitable for our redmine. We use it for a robotic lab, of 20 people, each of them managing a lot of project. For security reason there could only be one or maybe two people that may have administrator rights on the web server. We are Phd students or postdoc, so we don't want to spend lot of time administrating the webserver. So I think it is for each project "manager" to set-up this thing (and don't ask for the webserver administrator for each project), and they don't have any right to do it on the server (add the post-update hook). And also for security reason let anybody put any post-update hook ... Whow that's bad ! The plug-in will only be able to run some trusted command like doxygen to build the documentation ....

Other reason I don't like the tab solution :
- Only one tab per project. I would like generate several type of documentation (user, developer, new major release ...), and let user switch among them
- There is a nasty display of the project setting in the project settings home page (at least for redmine distributed with ubunutu lucid)
- You choose the tab name for every project, not per project basis. Could be hacked by some custom settings, but I really don't like the display on the homepage.

So since I did not found any solution for this problem, I'm starting developing my own. Maybe it will only be useful for us, maybe not ....

Bests regards

RE: Creating a plug-in for automatic doxygen generation - Added by Felix Schäfer about 13 years ago

Alexandre Tuleu wrote:

SO maybe my title was badly formulated, but my question was more on how to to add a subprocess to redmine application.

There's no facility in redmine for that, it's a beaten-to-death horse in rails development though, you might want to have a look at delayed_job, beanstalkd, backgroundjob, … and use that for your redmine plugin.

    (1-3/3)