No longer install popup directly and minor edits.
Added lua mode.