Skip to content

Instantly share code, notes, and snippets.

@MarcelFox
Forked from nderjung/list-grub-entries.sh
Created December 7, 2022 19:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save MarcelFox/bd29dd0da85bc22469b54e280ce494f2 to your computer and use it in GitHub Desktop.
Save MarcelFox/bd29dd0da85bc22469b54e280ce494f2 to your computer and use it in GitHub Desktop.
List grub entries
awk -F\' '$1=="menuentry " || $1=="submenu " {print i++ " : " $2}; /\tmenuentry / {print "\t" i-1">"j++ " : " $2};' /boot/grub/grub.cfg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment