10freedos 517 B

1234567891011121314151617181920212223
  1. #!/bin/sh
  2. . /usr/share/os-prober/common.sh
  3. partition="$1"
  4. mpoint="$2"
  5. type="$3"
  6. # Weed out stuff that doesn't apply to us
  7. case "$type" in
  8. vfat) debug "$1 is a FAT32 partition" ;;
  9. msdos) debug "$1 is a FAT16 partition" ;;
  10. fat) debug "$1 is a FAT partition (mounted by GRUB)" ;;
  11. *) debug "$1 is not a FAT partition: exiting"; exit 1 ;;
  12. esac
  13. if item_in_dir -q kernel.sys "$2" && item_in_dir -q command.com "$2"; then
  14. label="$(count_next_label FreeDOS)"
  15. result "$1:FreeDOS:$label:chain"
  16. exit 0
  17. else
  18. exit 1
  19. fi