6 Replies Latest reply on Nov 18, 2011 1:30 PM by vanamee

    automating generation of web help for a daily build?

    vanamee

      There's a desire at my work to automate the generation of web help so that it can easily be picked up by the daily build. The (vaguely expressed) idea is to somehow kick off an automatic conversion of the latest version of our admin guide (which is the only document we single source) at the end of each day. Has anyone set up something like this? I was unable to find any traces in these forums or elsewhere.

       

      We use RoboHelp 8,  FrameMaker 9, and CVS for source control.  

       

      Many thanks in advance for your help!

        • 1. Re: automating generation of web help for a daily build?
          vanamee Level 1

          I meant to add that I expect some combination of scripts could achieve something like the desired end, but I don't know which scripts or combination would work best.

           

          -Ryan

          • 2. Re: automating generation of web help for a daily build?
            kmaddox1 Level 1

            Hi Vanamee,

             

            My company generates Web Help output automatically during the nightly software build process. The build process gets the latest RH files from source control (we use Surround), then uses the RH command line in the build script to generate each help system. (We have a very large merged help system with a lot of individual projects.) The process seems to work just fine.

             

            To learn more about generating help from a command line, go to Robohelp > Help and search for "RHCL" (robohelp command line). The basic syntax is:

             

            rhcl [project path] [-l] [layout name]

             

            Hope this helps,

             

            Kathy

            • 3. Re: automating generation of web help for a daily build?
              vanamee Level 1

              Thanks, Kathy. The command line looks like a promising path. But that just picks up the already generated RH files, correct? Does that mean you still have to do the conversion from, say, FM to RH manually?

              • 4. Re: automating generation of web help for a daily build?
                kmaddox1 Level 1

                The command line actually generates the Webhelp from the files in source control; it doesn't copy already generated files. You do have to set up the layout in RH first; then, you can specify the layout name in the command line. As far as automating the conversion from Frame to RH, I can't help you since we don't use Framemaker.

                • 5. Re: automating generation of web help for a daily build?
                  Willam van Weelden Adobe Community Professional & MVP

                  Hi,

                   

                  Take a look at the following thread: http://forums.adobe.com/message/203012#203012 That contains an example script you can use to update the linked documents before generating. Also take look at the following help topic: http://help.adobe.com/en_US/robohelp/robohtml/WS98613C7C-EF5B-48e9-A91A-D2AABB882687.html It tells you more about scripts and it tells you how you can run those scripts from the command line.

                   

                  Greet,

                   

                  Willam

                  • 6. Re: automating generation of web help for a daily build?
                    vanamee Level 1

                    Thanks again Kathy and William for your help. I've almost got this to the point where it can be completeley automated.

                     

                    Here are the steps I'm using (likely old hat to most people, but wanted to share for other rookies like me):

                     

                    • Update the RH project by invoking the update script:

                     

                           "D:\Program Files\Adobe\Adobe RoboHelp 10\RoboHTML\RoboHTML.exe" -x  Z:\techpubs\ER10\AG\UpdateFM.jsx

                     

                     

                    • Generate the output:

                     

                             rhcl c:\techpubs\AG\SentrionAdminGuide.xpj -l WebHelp -o c:\cvs\mmc-appl-mgmt\src\doc\WebHelp

                     

                    • Commit those files to CVS. I don't know what would be required to automate that part. I would guess something like:

                           

                            cvs update -P c:\cvs\mmc-appl-mgmt\src\doc\WebHelp\  and then cvs commit -m  "comment" -- [files] 

                     

                             I'll update this if/when I get some developer help for the entire automation.

                     

                    Also, I had some trouble getting the example script William pointed me to to work as I expected. My colleague (Robert Lauriston) solved it for me: the problem was in the error handling part of the script:

                     

                    if(projectPath = '')

                            {

                                   //Error!. Quit RoboHelp

                                   alert("Project path is not defined. \nPlease update the 'projectPath' variable in the script.");

                                   RoboHelp.quit();

                            }

                     

                    Once I removed that, the stripped-down version worked just as I had hoped:

                     

                    var projectPath = "C:\\techpubs\\AG\\SentrionAdminGuide.xpj";

                    // User should update the project path.

                    // e.g. "C:\\Users\\mayank\\Documents\\My RoboHelp Projects\\RH8_1\\RH8_1.xpj"

                    //PLEASE NOTE:  Replace '\' with '\\' in the path above.

                     

                     

                    main();

                     

                     

                    function main()

                    {

                            RoboHelp.openProject(projectPath); //Open the project

                            RoboHelp.project.updateAll(true); //Update all linked documents (pass true for Force update)

                    }