Look through my RB scripts and see how this is done in detail...
for a simple menu item
SUBMENU=UI.menu("Plugins").add_submenu("Haujiet") #Or other menu by name e.g. 'Tools' SUBMENU.add_item("Add..."){Sketchup.active_model.select_tool(Haujiet_Tool.new())} SUBMENU.add_item("Settings..."){Haujiet_Module;;settings()}for a command
CMD1=UI;;Command.new("Tool_name"){Haujiet_Module;;some_module_action()} CMD1.tooltip="How_to_use_tool..." CMD1.status_bar_text="How_to_use_tool..." CMD1.small_icon=File.join(FOLDER_path, 'icon.png') CMD1.large_icon=File.join(FOLDER_path, 'icon.png')and for Toolbar
TOOLBAR=UI;;Toolbar.new("Haujiet...") TOOLBAR.add_item(CMD1) TOOLBAR.restore if TOOLBAR.get_last_state.abs == 1 #TB_VISIBLE/NEVERfor a context menu
UI.add_context_menu_handler{|menu| sub = menu.add_submenu("Haujiet...") sub.add_item(CMD1) # perhaps with tests to see if it should show - e.g. the selection is a group? }See here...
http://ruby.sketchup.com/UI/Command.html
http://ruby.sketchup.com/UI/Toolbar.html