Browse code

Now it's possible to add an app to an apphoard by drag/dropping its folder (or its .Installers folder) onto the 00-App Manager folder while using the Rox-Filer file manager.

Apollia authored on05/07/2018 00:34:14
Showing1 changed files
... ...
@@ -4,7 +4,7 @@
4 4
 #
5 5
 # Part of APSK Apphoard Manager
6 6
 #
7
-# by Apollia - http://apollia.org/
7
+# by Apollia - http://apollia.com/
8 8
 
9 9
 
10 10
 # 10:02:02 04/12/2018.  Like Ramize-Physave - https://github.com/Apollia/Ramize-Physave -
... ...
@@ -59,21 +59,44 @@ fi
59 59
 
60 60
 readonly Follpath____Apphoard_Home="$Follpath____Possible_Apphoard_Home"
61 61
 
62
+readonly Fillepath____Add_App_To_This_Apphoard="$Follpath____This_Script/Add App/add-app"
62 63
 
63
-Arg____Action="$1"
64 64
 
65
-echo "Arg____Action: $Arg____Action"
65
+Arg_1="$1"
66 66
 
67
-case "$Arg____Action" in
67
+
68
+
69
+case "$Arg_1" in
68 70
 	"add")
69
-		readonly Fillepath____Add_App_To_This_Apphoard="$Follpath____This_Script/Add App/add-app"
71
+		
70 72
 
71 73
 		echo "Add action!"
72 74
 		shift
73 75
 		bash "$Fillepath____Add_App_To_This_Apphoard" "$@"
74
-		echo "test"
76
+
75 77
 		;;
76
-	*)
78
+	"")
77 79
 		rox --dir "$Follpath____This_Script"
78 80
 		;;
81
+	*)
82
+		if [ -d "$Arg_1" ]
83
+		then
84
+			Follpath____Arg_1=$(realpath "$Arg_1")
85
+			
86
+			folname=$(basename "$Follpath____Arg_1")
87
+
88
+			
89
+			case "$folname" in
90
+				".Installers")
91
+					Follpath____App=$(realpath "$Follpath____Arg_1/..")
92
+
93
+					;;
94
+				*)
95
+					Follpath____App="$Follpath____Arg_1"
96
+			esac
97
+			
98
+			echo "Arg #1 is a folderpath - trying to add app!  $Follpath____App"
99
+			
100
+			bash "$Fillepath____Add_App_To_This_Apphoard" "$Follpath____App" --default
101
+		fi
79 102
 esac
80 103
\ No newline at end of file