Files
octodocker_deploy/plugins.sh
paukstelis 8d57a478be Rework (#94)
* split

* split2

* more splitting

* working

* towards working

* menu changes

* run through prepare

* minorfix

* octoprint_generic

* break in template

* replace daemonpath with octoexec

* move first install to instance

* move BASE to instance

* instance fix

* double period

* damn loop!

* add camera to deploy

* fix camera

* toward functional

* main_menu if not ready

* not equal or  -ne?

* template copy

* clean ups

* byid camera detect

* do byid detect by default

* classwebcam

* classicwebcam

* appned_value camera work

* use users for modification in cameras

* fancy colors

* updating colors

* status menu colors and cams

* surpress errors on no files

* remove most logging

* dnf mods

* selinux

* redirect error output to /dev/null

* package cleanup

* remove udev, cloud

* octopi update

* resource prepare from menu

* quick fix

* pacman fix

* more echos

* add udev flag in /etc/octoprint_deploy

* opensuse fixes

* zypper, minor fixes

* change_streamer

* diagnostics, octoprint_cameras, etc

* diagnostic menu

* logging for diagnostics

* add config.yaml to diagnostics

* add logging for config.yaml

* readme work, add deb_pacakges for octopi,

* README

* port fixing

* port fixes

* add deb_packages command for troubleshooting

* fix ports

* add octopi flag, I fucking hate octopi

* udev rule work

* add/remove udev

* menu fix

* menu fixes

* add detect printer for add_udev

* better detection for remove_udev

* remove udev

* working on sed for udev

* fixed udev remove

* camera udev

* add instace to add_udev_camera

* readme, cleanup

* choose what parts of template to copy

* rsync as user

* additionalPorts

* remove cameras from camera list
2023-06-25 17:09:01 -04:00

41 lines
1.1 KiB
Bash
Executable File

#!/bin/bash
install_plugin() {
echo "Installing $plugin...."
$OCTOPIP install "$plugin_path"
}
plugin_menu() {
echo
echo
get_settings
PS3="${green}Select recommended plugins to install: ${white}"
readarray -t plugins < <(cat $SCRIPTDIR/plugins_list | sed -n -e 's/^plugin:\(.*\) path:.*/\1/p')
plugins+=("All")
plugins+=("Quit")
select plugin in "${plugins[@]}"
do
if [ "$plugin" == Quit ]; then
break
fi
#some special thing to do if All Recommended
if [ "$plugin" == All ]; then
for plugin in "${plugins[@]}"; do
plugin_path=$(cat $SCRIPTDIR/plugins_list | sed -n -e "s/^plugin:$plugin path:\([[:graph:]]*\)/\1/p")
if [ -n "$plugin_path" ]; then
install_plugin $plugin $plugin_path
fi
done
break
fi
#install single plugin
#get plugin path
plugin_path=$(cat $SCRIPTDIR/plugins_list | sed -n -e "s/^plugin:$plugin path:\([[:graph:]]*\)/\1/p")
install_plugin
done
}