improve linux compatibility
move init to plugin file