Documenting velocity macros (aka velocimacros)

Hi devs,

FYI we didn’t have a place to document velocity macros so I started one at https://extensions.xwiki.org/xwiki/bin/view/Extension/Web%20Resources%20for%20XWiki/

I’ve also linked it from:

Let’s continue documenting them there and let’s move the ones that we put on e.x.o a long time ago. For example:

Note: I haven’t added doc for the macros.vm located in the Flamingo skin since IMO they should be considered private and not be used (except for internal templates and code only for the Flamingo skin).

Exposing them would mean users using them and being broken when a new skin is used.

@community/@everyone: please help moving the content in the listed pages above to subpages of https://extensions.xwiki.org/xwiki/bin/view/Extension/Web%20Resources%20for%20XWiki/. Please follow the format started for the 2 pages there ATM:

That’s a good way to contribute to the project!

Hi @vmassol , I have shifted one page “Error Macro (Velocity)” and want to know if I did it the right way.
I made 2 pages, since the original page had objects so I made a copy of it and moved it to:
Web Resources for XWiki / Macros.
These 2 pages are different:

  1. ErrorMacro which is similar to the examples shown (e.g. UserAvatarMacro).
  2. ErrorMacro (Original with objects) which is similar to original page at Error Macro (Velocity).

Which one is rightly done?
Thanks.

Thanks. I have now created a small app (an xclass and a sheet) for velocimacros. I have updated the error macro page to use it. And I’ve removed the copy of the original macro + cleaned the original page.

If you handle other macros please don’t delete the original page, as I’d prefer to do it to verify that all info has been ported over. Thanks! :slight_smile:

Thanks again for your help.

Sure. BTW I didn’t delete it or move, also I need access rights to do that. I used copy page from page options. Will surely won’t mess with the original one next time.
Thanks, now it’s easier and better :slight_smile:

Yep seen that, cool.