Use XeTeX with latexmk

Just find out that it is easy to set XeTex to work with latexmk. From TeX on Mac OS X mailing list by Herb Schulz:

Move the engine files from ~/Library/TeXShop/Engines/Inactive/Latexmk/ two directories up, to ~/Library/TeXShop/Engines/ to activate them. Once that is done restart TeXTShop.

To use the xelatexmk engine simply put the line

% !TEX TS-program = xelatexmk

at the top of the source file.