File tree 1 file changed +4
-7
lines changed
1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -45,15 +45,12 @@ grub_btrfs_config="${sysconfdir}/default/grub-btrfs/config"
45
45
46
46
# # Exit the script, if:
47
47
disable_script () {
48
- # Disable Grub-btrfs is set to true (default=false)
49
- [[ " ${GRUB_BTRFS_DISABLE:- " false" } " == " true" ]] && return 1
50
- # btrfs-progs isn't installed
51
- if ! type btrfs > /dev/null 2>&1 ; then return 1; fi
52
- # grub-mkconfig_lib couldn't be found
53
- [[ -f " $datarootdir /grub/grub-mkconfig_lib" ]] && . " $datarootdir /grub/grub-mkconfig_lib" || return 1
48
+ [[ " ${GRUB_BTRFS_DISABLE:- " false" } " == " true" ]] && exit 0 # Disable Grub-btrfs is set to true (default=false)
49
+ if ! type btrfs > /dev/null 2>&1 ; then exit 0; fi # btrfs-progs isn't installed
50
+ [[ -f " $datarootdir /grub/grub-mkconfig_lib" ]] && . " $datarootdir /grub/grub-mkconfig_lib" || exit 0 # grub-mkconfig_lib couldn't be found
54
51
# Root filesystem isn't btrfs
55
52
root_fs=$( ${grub_probe} --target=" fs" / 2> /dev/null)
56
- [[ " $root_fs " != " btrfs" ]] && return 1
53
+ [[ " $root_fs " != " btrfs" ]] && exit 0
57
54
return 0
58
55
}
59
56
disable_script
You can’t perform that action at this time.
0 commit comments