workaround: open system font book to let user click 'Install'
[webi-installers/.git] / flutter / install.sh
index 4feb311e5e14fd754cd2c7be62272effdd2032a8..9626eb36f987a62f0f91707adc9338ac44a1f28d 100644 (file)
@@ -8,10 +8,19 @@ set -u
 #       pkg_src, pkg_src_bin, pkg_src_cmd
 #       pkg_dst, pkg_dst_bin, pkg_dst_cmd
 #
-# Their defaults are defined in webi/template.bash at https://github.com/webinstall/packages
+# Their defaults are defined in _webi/template.sh at https://github.com/webinstall/packages
 
+# Every package should define these 6 variables
 pkg_cmd_name="flutter"
 
+pkg_dst_cmd="$HOME/.local/opt/flutter/bin/flutter"
+pkg_dst_dir="$HOME/.local/opt/flutter"
+pkg_dst="$pkg_dst_dir"
+
+pkg_src_cmd="$HOME/.local/opt/flutter-v$WEBI_VERSION/bin/flutter"
+pkg_src_dir="$HOME/.local/opt/flutter-v$WEBI_VERSION"
+pkg_src="$pkg_src_dir"
+
 pkg_get_current_version() {
     # 'flutter --version' outputs a lot of information:
     #       Flutter 1.19.0-4.1.pre • channel beta • https://github.com/flutter/flutter.git
@@ -20,7 +29,7 @@ pkg_get_current_version() {
     #       Tools • Dart 2.9.0 (build 2.9.0-14.1.beta)
     # This trims it down to just the version number:
     #       1.19.0-4.1.pre
-    echo "$(flutter --version 2>/dev/null | head -n 1 | cut -d' ' -f2)"
+    echo "$(flutter --version 2> /dev/null | head -n 1 | cut -d' ' -f2)"
 }
 
 pkg_format_cmd_version() {