initial working version of plugin