s243a

install-iron (draft)

Jan 19th, 2021
1,101
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #!/bin/bash
  2. mode=chroot
  3. version="84.0.4300.0"
  4. case "$mode" in
  5. chroot)
  6.   EXEC_CMD="$OS_HOME/iron_scripts/ironchroot" --chroot-command ./iron
  7.   COMMENT="Chrooted Iron Browser"
  8.   NAME="Iron ${version} ($mode)"
  9.   ;;
  10. portable)
  11.   EXEC_CMD="$OS_HOME/iron_scripts/ironchroot" --command ./iron
  12.   COMMENT="Portable Iron Browser"
  13.   NAME="Iron ${version} ($mode)"
  14.   ;;
  15. *)
  16.   echo "Undefined mode" > &2
  17.   exit 0
  18. esac
  19.  
  20. cp $OS_HOME/iron_scripts/ironchroot/iron.desktop /usr/share/applications/iron_${version}_"$mode"
  21. sed -ir -f <EOF
  22. /^Name/ s#=(.*)#$name#g
  23. /^Comment/ s#=(.*)#$COMMENT#g
  24. /^Exec/ s#=(.*)#"=$EXEC_CMD#g
  25. EOF
  26.  
  27.  
RAW Paste Data