Added by Claas Thiele, last edited by Jonas Kilian on Dec 05, 2008  (view change)

Labels

 
(None)

Content

Release the Molybdenum Firefox extension

What you have to know...

For the Molybdenum extension, three maturity levels are defined

  • preview
  • beta
  • release

Molybdenum version string has the following format:
For preview and beta releases this should be the following: <version number>-<preview|beta|rc><release number>.
For releases it is the plain version number.
A version number for Molybdenum consists of 3 one digit numbers separated by dots.

To access the release areas on molyb.org a ssh key has to be provided. This key and your molyb.org username has to be referenced in your Maven settings.xml

<settings>
   <profiles>
      <profile>
         <id>molybdenum</id>
         <properties>
             <ssh.username>user1</ssh.username>
             <ssh.key>/home/user1/.ssh/id_dsa.molyb</ssh.key>
         </properties>
      </profile>
   </profiles>
   .
   .
   .
</settings>
  1. Choose the right maturity level for your release and put it in the pom of molybdenum-dist.
  2. Check the version you want to deploy.
  3. recheck the dependency versions
  4. commit your changes
  5. checkout a fresh copy to initiate a clean build
    1. build the dependencies mvn clean install (This is not done automatically - MOLYB-74)
      1. testserver
      2. molybdenum-env
      3. molybdenum-xpi
    2. deploy molybdenum-dist mvn -Pdeploy clean install
    3. tag the version: tag name VERSION_<version dots replaced with underscores>
      Example: VERSION_0_7_0beta1
  6. make the release public via wiki

Re-create Molybdenum Reference (API Docs) in Confluence

molybdenum-xpi$> mvn clean install

Will created latest JAR file containing XPI and molydoc.xml, that is the command line reference in XML format.

molybdenum-dist$> mvn clean generate-resources -P confluence

Now check that molybdenum-dist/target/api-docs/confluence contains the following folders:

 |_ moly
 |_ moly-readonly
 |_ selenium-core
 |_ selenium-core-readonly
 |_ reference.txt

The -readonly directories do contain the content maintained in confluence.
The directories "moly" and "selenium-core" do contain the content generated from JsDocs. Those are the directories you want to import in confluence, thus overriding previous API Docs with new content. You'll need the reference.txt as well as it contains the overview page.

  1. Login to molyb.org via SSH and go to /tmp folder
  2. mkdir import-`date +%F`
  3. Copy all content from molybdenum-dist/target/api-docs/confluence into that folder
  4. Make it accessible for tomcat user running confluence:
    sudo chown -R tomcat:tomcat /tmp/import-`date +%F`/
  5. Compare reference index with previous version (see an example):
    diff -by --suppress-common-lines \
      /home/kilian/temp-imports/import-2008-08-10/reference.txt \
      /tmp/import-`date +%F`/reference.txt \
      > /tmp/import-`date +%F`_reference_index_diff.txt

    and make sure which commands have been added and removed.
    If Selenium commands are affected, remember them to document em in wiki later on (in the associated readonly file)

  6. Now examine the new or changed molybdenum commands (see example):
    1. Get a list of changed files
      TODO: improve this script
      for i in ` diff -by --width=300 --suppress-common-lines \
        /home/kilian/temp-imports/old-stuff/reference.txt \
        /tmp/import-2008-12-05/reference.txt \
        | grep -v selcore \
        | awk ' BEGIN {FS="|"; RS="]"} { print $2 }'`; \
        do find /tmp/import-2008-12-05/ -name $i-apidoc.txt >> /tmp/import-2008-12-05_affected_moly_files.txt; \ 
        done;
    2. Make sure @since annotation is present
      for i in `cat /tmp/import-2008-12-05_affected_moly_files.txt` ;\
       do grep --files-without-match  "since 0.7.1" $i;\
       done;
  7. Log in to confluence as Space Admin
  1. Goto Dashboard -> Sandbox -> Browse Space -> Space Admin -> Import Pages from Disk
  2. Choose folder "/tmp/import-<date>/moly" and select checkboxes "Trim file extensions" as well as "Overwrite existing pages" (1)
  3. Repeat with folder "/tmp/import-<date>/selenium-core"
  4. If new commands have been added to Molybdenum:
    Choose folder "/tmp/import-<date>/moly-readonly" and select checkboxes "Trim file extensions" but DO NOT use "Overwrite existing pages"
  5. If new commands have been added to Selenium:
    Choose folder "/tmp/import-<date>/selenium-core-readonly" and select checkboxes "Trim file extensions" but DO NOT use "Overwrite existing pages"
  6. Now for the index file reference.txt simple use the base folder "/tmp/import-<date>/" ignoring any warnings for the already imported sub dirs. TODO: this can be improved.
  7. Check that content has been imported correctly in Sandbox by examining page "reference". Note that the "xyz-apidoc" pages are including their counterpart with space key "MOLYB:". You need to change one of those includes to "SAND:" for testing.
  8. Now you're ready to repeat the last steps in the Molybdenum Space
  9. Now copy the contents of imported "reference" page into the page "Molybdenum Command Reference"

(1) if you don't check "Override existing pages", during import, pages being overwritten will have been renamed: e.g. "loadVars-action-moly-apidoc" to "loadVars-action-moly-apidoc2" etc. From time to time, delete these old, orphaned pages

I have not found any mechanism or plugin to bulk delete orphaned pages in confluence. But you may use these simple moly scripts: deleteOrphanedPagesInSandbox.xml
deleteOrphanedPages.xml


Be aware of thooe issues:
Issue: Included pages appear as orphaned pages
Issue: Orphaned Pages Query is slow