Skip to content

Commit

Permalink
Fix slow touch response and update install script (#1070)
Browse files Browse the repository at this point in the history
* update install script

* downgrade to electron 9 to improve performance
  • Loading branch information
UnchartedBull committed Oct 11, 2020
1 parent e2395a6 commit 6d08f3c
Show file tree
Hide file tree
Showing 4 changed files with 40 additions and 35 deletions.
2 changes: 1 addition & 1 deletion angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"builder": "@angular-devkit/build-angular:browser",
"options": {
"aot": true,
"allowedCommonJsDependencies": ["angular-svg-round-progressbar"],
"allowedCommonJsDependencies": ["angular-svg-round-progressbar", "lodash", "ajv"],
"outputPath": "dist",
"index": "src/index.html",
"main": "src/main.ts",
Expand Down
12 changes: 6 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@
"@typescript-eslint/eslint-plugin": "^4.0.0",
"@typescript-eslint/parser": "^3.10.1",
"codelyzer": "^6.0.1",
"electron": "^10.1.3",
"electron": "~9.3.2",
"electron-builder": "^22.8.1",
"eslint": "7.11.0",
"eslint-plugin-import": "^2.22.1",
Expand Down
59 changes: 32 additions & 27 deletions scripts/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -669,7 +669,7 @@ text_input() {


releaseURL=$(curl -s "https://api.github.com/repos/UnchartedBull/OctoDash/releases/latest" | grep "browser_download_url.*armv7l.deb" | cut -d '"' -f 4)
dependencies="libgtk-3-0 libnotify4 libnss3 libxss1 libxtst6 xdg-utils libatspi2.0-0 libuuid1 libappindicator3-1 libsecret-1-0 xserver-xorg ratpoison x11-xserver-utils xinit libgtk-3-0 bc desktop-file-utils libavahi-compat-libdnssd-dev"
dependencies="libgtk-3-0 libnotify4 libnss3 libxss1 libxtst6 xdg-utils libatspi2.0-0 libuuid1 libappindicator3-1 libsecret-1-0 xserver-xorg ratpoison x11-xserver-utils xinit libgtk-3-0 bc desktop-file-utils libavahi-compat-libdnssd1"
IFS='/' read -ra version <<< "$releaseURL"

echo "Installing OctoDash "${version[7]}
Expand All @@ -684,38 +684,43 @@ elif [ -d "/home/pi/oprint" ]; then
DIRECTORY="/home/pi/oprint"
else
echo "Neither /home/pi/OctoPrint/venv nor /home/pi/oprint can be found."
text_input "Please specify OctoPrints full virtualenv path manually (no trailing slash)" DIRECTORY
echo "If your OctoPrint instance is running on a different machine just type - in the following prompt."
text_input "Please specify OctoPrints full virtualenv path manually (no trailing slash)." DIRECTORY
fi;

if [ ! -d $DIRECTORY ]; then
if [ $DIRECTORY == "-" ]; then
echo "Not installing any plugins for remote installation. Please make sure to have Display Layer Progress installed."
elif [ ! -d $DIRECTORY ]; then
echo "Can't find OctoPrint Installation, please run the script again!"
exit 1
fi;

plugins=( 'Display Layer Progress (mandatory)' 'Filament Manager' 'Preheat Button' 'Enclosure' 'Print Time Genius' 'Ultimaker Format Package' 'PrusaSlicer Thumbnails' )
checkbox_input "Which plugins should I install (you can also install them via the Octoprint UI)?" plugins selected_plugins
echo "Installing Plugins..."

if [[ " ${selected_plugins[@]} " =~ "Display Layer Progress (mandatory)" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/OllisGit/OctoPrint-DisplayLayerProgress/releases/latest/download/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Filament Manager" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/OllisGit/OctoPrint-FilamentManager/releases/latest/download/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Preheat Button" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/marian42/octoprint-preheat/archive/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Enclosure" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/vitormhenrique/OctoPrint-Enclosure/archive/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Print Time Genius" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/eyal0/OctoPrint-PrintTimeGenius/archive/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Ultimaker Format Package" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/jneilliii/OctoPrint-UltimakerFormatPackage/archive/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "PrusaSlicer Thumbnails" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/jneilliii/OctoPrint-PrusaSlicerThumbnails/archive/master.zip"
if [ $DIRECTORY != "-" ]; then
plugins=( 'Display Layer Progress (mandatory)' 'Filament Manager' 'Preheat Button' 'Enclosure' 'Print Time Genius' 'Ultimaker Format Package' 'PrusaSlicer Thumbnails' )
checkbox_input "Which plugins should I install (you can also install them via the Octoprint UI)?" plugins selected_plugins
echo "Installing Plugins..."

if [[ " ${selected_plugins[@]} " =~ "Display Layer Progress (mandatory)" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/OllisGit/OctoPrint-DisplayLayerProgress/releases/latest/download/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Filament Manager" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/OllisGit/OctoPrint-FilamentManager/releases/latest/download/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Preheat Button" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/marian42/octoprint-preheat/archive/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Enclosure" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/vitormhenrique/OctoPrint-Enclosure/archive/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Print Time Genius" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/eyal0/OctoPrint-PrintTimeGenius/archive/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "Ultimaker Format Package" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/jneilliii/OctoPrint-UltimakerFormatPackage/archive/master.zip"
fi;
if [[ " ${selected_plugins[@]} " =~ "PrusaSlicer Thumbnails" ]]; then
"$DIRECTORY"/bin/pip install -q --disable-pip-version-check "https://github.com/jneilliii/OctoPrint-PrusaSlicerThumbnails/archive/master.zip"
fi;
fi;

echo "Installing OctoDash ..."
Expand Down

0 comments on commit 6d08f3c

Please sign in to comment.