cauldren.sh 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. ##########
  2. ##########
  3. ##########
  4. ##########
  5. # cauldren
  6. ### dev note... should really gut out ALL functions, so no functions are defined within a function. ... it'd make it much cleaner... and probably make it work.
  7. #### once the function gutting is done, remove this guff^
  8. ## cauldren is called from the install option of witchcraft2011, and leads to the various installs (installgentoo, installfuntoo, etc)
  9. #distroselectormk2 for now.
  10. #dev notes n reminders
  11. ## partitions n fs
  12. #mountings
  13. #stage3
  14. #chroot
  15. #package managment
  16. #configure ~~~~~~
  17. #kernel
  18. #bootloader
  19. #users
  20. #startup daemons
  21. #final packages, configs n post-install scripts
  22. #cleanup & remove stage3 tarball & remove package manager tarball
  23. #mntchrt and umntchrt
  24. #one builds a chroot of a folder and the other umounts it automagically
  25. # http://pastebin.com/T9Wb0GiB http://pastebin.com/ETPZ23Ja thnx to rstrcogburn.
  26. # rstrcog's exherbo global useflags http://pastebin.com/QQbeUpk5
  27. # tho he prolly has new ones now.
  28. ############
  29. ############
  30. # stage3
  31. function stage3 {
  32. #called from second top layer in cauldren, once you select to do a proper stage3 install.
  33. #currently just calls the distroselector function, to select which route of stage3 install to use, (gentoo, funtoo, etc) and then the desktop selector
  34. #once the refunctionising is done, this may change.
  35. $WITCH/distroselect.sh
  36. if [ $DIMG_RUN == "true" ]; then
  37. echo "Skipping deskfig because you're running Disk IMaGe mode..."
  38. else
  39. $WITCH/deskfig.sh
  40. fi
  41. }
  42. ############
  43. ############
  44. # simpleinstall
  45. # dev update... there was that guy... i forget who... i think im following him on github, has that simple install... could consider hacking that up to make a direct automated (as much as possible), rowan witch install.
  46. #simpleinstall... see about adding a simplified install for presets.
  47. #one way to consider for this, add a variable that would permit stage3 install, and just automatically select all the defaults as much as is possible.
  48. function simpleinstall {
  49. echo "incomplete portion of script, sorry"
  50. sleep 2
  51. cauldren
  52. }
  53. ############
  54. ############
  55. # cauldren
  56. function cauldren {
  57. clear
  58. sleep 1
  59. echo "ok, so you want to install some hardcore nix."
  60. echo
  61. echo "cauldren first question"
  62. echo
  63. $WITCH/color.sh QUESTION "what do you want to do?"
  64. $WITCH/color.sh GREEN "
  65. A. simple install - less choices, control, flexibility. just presets.
  66. B. proper install - pick which metadistro, and which desktop config.
  67. C. v leet install - do it all yourself"
  68. read CauldrenOption
  69. case $CauldrenOption in
  70. A|a)
  71. echo "Choice was \"$CauldrenOption\". sorry, this part of the script is still under construction. running it in a couple seconds anyway"
  72. sleep 5
  73. simpleinstall
  74. ;;
  75. B|b)
  76. echo "Choice was \"$CauldrenOption\". warning, this part of the script might still be a little buggy. running it in a couple seconds anyway"
  77. sleep 5
  78. stage3
  79. ;;
  80. C|c)
  81. echo "Choice was \"$CauldrenOption\". this part of the script is complete. for full manual install, simply press ctrl-C at any time to enter fully manual mode."
  82. echo "you ub0r l33t... i have a feeling we might get hacked by you"
  83. echo "exiting to full manual mode now"
  84. exit
  85. ;;
  86. *)
  87. echo "Valid Choices are A,B,C"
  88. exit 1
  89. ;;
  90. esac
  91. }
  92. if [ "$DIMG_RUN" == "true" ]; then
  93. stage3 # proper install
  94. else
  95. cauldren
  96. fi