a blob commit
authorJosuer08 <josuer08@gmail.com>
Wed, 16 Dec 2020 17:32:19 +0000 (12:32 -0500)
committerJosuer08 <josuer08@gmail.com>
Wed, 16 Dec 2020 17:32:19 +0000 (12:32 -0500)
archivo.pdf [new file with mode: 0644]
errores.txt [new file with mode: 0644]
updaterarch [new file with mode: 0755]
updaterdeb [new file with mode: 0755]
updaterfed [new file with mode: 0755]
updaternpm [new file with mode: 0755]
updaterpip [new file with mode: 0755]
updaterselector [new file with mode: 0755]

diff --git a/archivo.pdf b/archivo.pdf
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/errores.txt b/errores.txt
new file mode 100644 (file)
index 0000000..3328feb
--- /dev/null
@@ -0,0 +1 @@
+No manual entry for masdfasfsafasdfdsan
diff --git a/updaterarch b/updaterarch
new file mode 100755 (executable)
index 0000000..d4c1234
--- /dev/null
@@ -0,0 +1,7 @@
+#!/bin/bash
+if [ $2 == "0" ]
+then
+  a
+else
+  a
+fi
diff --git a/updaterdeb b/updaterdeb
new file mode 100755 (executable)
index 0000000..9beb553
--- /dev/null
@@ -0,0 +1,2 @@
+#!/bin/bash
+echo $@;
diff --git a/updaterfed b/updaterfed
new file mode 100755 (executable)
index 0000000..e69de29
diff --git a/updaternpm b/updaternpm
new file mode 100755 (executable)
index 0000000..e69de29
diff --git a/updaterpip b/updaterpip
new file mode 100755 (executable)
index 0000000..e69de29
diff --git a/updaterselector b/updaterselector
new file mode 100755 (executable)
index 0000000..9d78ceb
--- /dev/null
@@ -0,0 +1,55 @@
+#!/bin/bash
+
+
+eval 'resize'; #this creates variables for the size of the terminal
+
+
+#In the next line we do the trick of asignning the output to a variable, but we invert stdout and stderr via the "3>&1 1>&2 2>&3" part, because whiptail exports via stderr
+
+
+value1=$(whiptail --title "Global package manager" --menu "What are we managing today?" $(( $LINES - 8 )) $(( $COLUMNS - 4 )) $(( $LINES - 16 )) \
+"1" "APT" \
+"2" "PACMAN" \
+"3" "YAY" \
+"4" "DNF" \
+"5" "PIP (python installer)" \
+"6" "NODE.JS Modules in this directory" \
+"7" "CLOSE THIS" 3>&1 1>&2 2>&3)
+
+
+if [ $value1 == "7" ]
+then
+  exit 0;
+fi
+
+
+value2=$(whiptail --title "Global package manager" --menu "What do you want to do?" $(( $LINES - 8 )) $(( $COLUMNS - 4 )) $(( $LINES - 16 )) \
+"1" "Install package" \
+"2" "Update/reinstall specific package" \
+"3" "Uninstall package" \
+"4" "See installed packages" \
+"5" "Search for a package" \
+"6" "CLOSE THIS" 3>&1 1>&2 2>&3)
+
+
+case $value1 in
+1)
+  . $(pwd)/updaterdeb $value2;
+  ;;
+2)
+  . $(pwd)/updaterarch $value2 0;
+  ;;
+3)
+  . $(pwd)/updaterarch $value2 1;
+  ;;
+3)
+  . $(pwd)/updaterfed $value2;
+  ;;
+5)
+  . $(pwd)/updaterpip $value2;
+  ;;
+6)
+  . $(pwd)/updaternpm $value2;
+  ;;
+esac
+