Advertisement
Guest User

Untitled

a guest
Jan 30th, 2017
261
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #if [ -s $prefix/grubenv ]; then
  2. set have_grubenv=true
  3. load_env
  4. #fi
  5. #removed if structure above (required-NO)
  6. #if [ "${next_entry}" ] ; then
  7. # set default="${next_entry}"
  8. # set next_entry=
  9. # save_env next_entry
  10. # set boot_once=true
  11. #else
  12. set default="3"
  13. #fi
  14. #removed if structure above (required-NO)
  15. #if [ x"${feature_menuentry_id}" = xy ]; then
  16. # menuentry_id_option="--id"
  17. else
  18. menuentry_id_option=""
  19. #fi
  20. #removed if structure above (required-NO)
  21. export menuentry_id_option
  22.  
  23. #if [ "${prev_saved_entry}" ]; then
  24. # set saved_entry="${prev_saved_entry}"
  25. # save_env saved_entry
  26. # set prev_saved_entry=
  27. # save_env prev_saved_entry
  28. # set boot_once=true
  29. #fi
  30. #removed code block above (required-NO)
  31. #function savedefault {
  32. # if [ -z "${boot_once}" ]; then
  33. # saved_entry="${chosen}"
  34. # save_env saved_entry
  35. # fi
  36. #removed code block above (required-NO)
  37. #}
  38. #function recordfail {
  39. # set recordfail=1
  40. # if [ -n "${have_grubenv}" ]; then if [ -z "${boot_once}" ]; then save_env recordfail; fi; fi
  41. #}
  42. #removed code block above (required-NO)
  43. function load_video {
  44. if [ x$feature_all_video_module = xy ]; then
  45. insmod all_video
  46. else
  47. insmod efi_gop
  48. insmod efi_uga
  49. insmod ieee1275_fb
  50. insmod vbe
  51. insmod vga
  52. insmod video_bochs
  53. insmod video_cirrus
  54. fi
  55. }
  56. #removed and replaced code block above (required-Yes)
  57. if [ x$feature_default_font_path = xy ] ; then
  58. font=unicode
  59. else
  60. insmod part_msdos
  61. insmod ext2
  62. #set root=UUID=0c627e59-15d2-4c47-9b4e-771ddaff0f74 changed to below method which works fine
  63. search --no-floppy --set=root --label freedom
  64. #if [ x$feature_platform_search_hint = xy ]; then
  65. search --no-floppy --set=root --label freedom
  66. #else
  67. # search --no-floppy --fs-uuid --set=root 0c627e59-15d2-4c47-9b4e-771ddaff0f74
  68. #fi
  69. #removed if structure above (required-NO)
  70. font=/boot/grub/fonts/unicode.pf2 #changed font path
  71. fi
  72.  
  73. if loadfont $font ; then
  74. set gfxmode=auto
  75. #changed =640x480 to =auto on line above seems fine.
  76. load_video
  77. insmod gfxterm
  78. set locale_dir=/boot/grub/locale
  79. #changed line above $prefix to /boot/grub seems fine.
  80. set lang=en_US
  81. insmod gettext
  82. fi
  83. terminal_output gfxterm
  84. ### section begin
  85. #if [ "${recordfail}" = 1 ] ; then
  86. # set timeout=-1
  87. #else
  88. # if [ x$feature_timeout_style = xy ] ; then
  89. # set timeout_style=menu
  90. # set timeout=10
  91. # else
  92. # set timeout=10
  93. # fi
  94. #fi
  95. ###comment out section above - required-no - autoboot not required
  96. insmod part_msdos
  97. insmod ext2
  98. search --set=root --label freedom #replaced line below with this one
  99. #search --no-floppy --fs-uuid --set=root 0c627e59-15d2-4c47-9b4e-771ddaff0f74
  100. ### Begin Background setup ###
  101. insmod png
  102. set menu_color_normal=yellow/black
  103. set menu_color_highlight=black/light-gray
  104. if background_image /boot/grub/splash.png; then
  105. true
  106. else
  107. set menu_color_normal=yellow/black
  108. set menu_color_highlight=black/light-gray
  109. fi
  110. ### END Background setup ###
  111.  
  112. ### BEGIN setup graphics ###
  113. function gfxmode {
  114. set gfxpayload="${1}"
  115. if [ "${1}" = "keep" ]; then
  116. set vt_handoff=vt.handoff=7
  117. else
  118. set vt_handoff=
  119. fi
  120. }
  121. if [ "${recordfail}" != 1 ]; then
  122. if [ -e ${prefix}/gfxblacklist.txt ]; then
  123. if hwmatch ${prefix}/gfxblacklist.txt 3; then
  124. if [ ${match} = 0 ]; then
  125. set linux_gfx_mode=keep
  126. else
  127. set linux_gfx_mode=text
  128. fi
  129. else
  130. set linux_gfx_mode=text
  131. fi
  132. else
  133. set linux_gfx_mode=keep
  134. fi
  135. else
  136. set linux_gfx_mode=text
  137. fi
  138. export linux_gfx_mode
  139. ### End setup graphics ###
Advertisement
RAW Paste Data Copied
Advertisement