* detect uuid requirement
add new function to detect uuid requirement
* Reduce generation time
New function doesn't need to be called at each generation of a menu entry
* Fix: Title format in grub-menu
function:
- title_format , doesn't work as expected
replace print message with default parameter (p/d/n)
* Update header
- Add Github link
- Clear up some explanations
* Fix: path to grub-mkconfig_lib
. "$pkgdatadir/grub-mkconfig_lib" doesn't work on some distribution
Replaced by . "$datarootdir/grub/grub-mkconfig_lib"
* Fix: matches kernel & initramfs
matches kernel & initramfs doesn't work as expected
Update readme to v3.xx
GRUB_BTRFS_CREATE_ONLY_HARMONIZED_ENTRIES="true"
Doesn't exist anymore
GRUB_BTRFS_IGNORE_SPECIFIC_PATH=("var/lib/docker" "nosnapshot")
Delete "nosnapshot" it is confusing
New option available :
GRUB_BTRFS_DISABLE="true"
(Disable grub-btrfs)
* Update 41_snapshots-btrfs
Enhanced error handling :
- new function available: print_error
- if btrfs-progs is not present, print a error and exit
New options in etc/default/grub
- disable this script
Enhanced menuentries:
- menuentries is now store in new grub configfile (/boot/grub/grub.cfg)
- use new functions for make a menuentry: make_menu_entries and entry
- harmonize menuentry with matching version kernel&initramfs # initramfs-linux-fallback is include and not boot with intel-ucode if exist , same as original patch in GRUB for Arch Linux
- make a menuentry in Grub menu (grub.cfg) to load our configfile
Enhanced /boot detection:
- create two separate function for make menuentries, if /boot is on a separate partition, use function boot_separate, else, boot_bounded
- if no kernel found, print a message and exit
- if no initramfs found, print a message and exit
Delete function: boot_dir
No longer uses gettext_printf function of grub-mkconfig_lib
New function to detect kernel:
- add all original standard kernel
- verifying if kernel exist before to continue
New functionto detect initramfs:
- add all original standard initramfs
- verifying if initramfs exist before to continue
New function to detect microcode
New counter:
- add a counter to show a warning if the total menuentries made exceeds 250 entries
Purge some obsolete code
Size tabulation is now 4
* Add systemd service configuration for grub updating
This configuration file causes `update-grub` to be run after
Snapper's cleanup and timeline services are run by systemd
* Make invoked command more universal
* Note the need to run systemctl daemon-reload
* Use snapper's snapshot description if available, fixes#34
* List snapper's snapshot from all configs
* fix: Title format in grub-menu, that didn't work as expected
* GRUB_BTRFS_CREATE_ONLY_HARMONIZED_ENTRIES="false"
-----> (Create entries with matching version number instead of all possible combinations of kernel and initramfs)
Fix : When a value =< 0, script stop correctly
fix : When a value => 1, script stop when the value is reached
e.g :
- GRUB_BTRFS_LIMIT="0"
script doesn't detect snapshot
- GRUB_BTRFS_LIMIT"1" or "2" "etc..."
script will stop the snapshot detection when value is reached
add a option to : specific path to ignore during run grub-mkconfig
e.g :
# Found Snapshot: 2016-03-31 10:26:52 var/lib/docker/btrfs/subvolumes/74040aee4fa
docker is not a real snapshot available to boot
add : GRUB_BTRFS_IGNORE_SPECIFIC_PATH=("var/lib/docker") to your /etc/default/grub
and this path will be skip during run grub-mkconfig
Warning : copy exactly the right path (var/lib/docker , not /var/lib/docker/), do not put the full path
- clean code
- add a option to : specific path to ignore during run grub-mkconfig
e.g :
# Found Snapshot: 2016-03-31 10:26:52 var/lib/docker/btrfs/subvolumes/74040aee4fa
docker is not a real snapshot available to boot
add : GRUB_BTRFS_IGNORE_SPECIFIC_PATH=("var/lib/docker") to your /etc/default/grub
and this path will be skip during run grub-mkconfig
Warning : copy exactly the right path (var/lib/docker , not /var/lib/docker/), do not put the full path
- add two new custom variable to /etc/default/grub :
* GRUB_BTRFS_SHOW_TOTAL_SNAPSHOTS_FOUND="true"
(Show Total of snapshots found during run "grub-mkconfig")
* GRUB_BTRFS_SHOW_SNAPSHOTS_FOUND="true"
(Show snapshots found during run "grub-mkconfig")
if no snap found, menu generate correctly, and show a warning
- overhaul
- add two new custom variable to /etc/default/grub :
* GRUB_BTRFS_SHOW_TOTAL_SNAPSHOTS_FOUND="true"
(Show Total of snapshots found during run "grub-mkconfig")
* GRUB_BTRFS_SHOW_SNAPSHOTS_FOUND="true"
(Show snapshots found during run "grub-mkconfig")
Allow user to limit the number of snapshots listed in GRUB. This also reverses
the order of the snapshots such that the more recent ones come first. That is,
if a user specifies GRUB_BTRFS_LIMIT=10, then only the 10 most recent snapshots
will be shown. The default limit is 100, which seems very large. The more
snapshots in the GRUB menu, the longer the system takes to boot.