A utility to facilitate the maintenance of your EFI bootstub.
Written in rust.
The aim of bootstub-updater is to simplify the process of maintaining a bootstub entry. After figuring out the command that creates a bootstub, you pretty much set it and forget it!
bootstub-updater can be installed through one of the methods listed below.
First, install rust, and then run the following command:
cargo install bootstub-updater
To update after installation, run:
cargo install bootstub-updater --force
For those using Arch Linux you can find the package on the AUR here. However, if you're using an AUR helper, the package can be installed through that. For example, If using yay, run the following command:
yay -S bootstub-updater
- Download the latest binary from the releases page
- (Optional) To ensure the file you downloaded is correct and was not tampered with, do the following:
- Download the respective
.sha256
file - Run
sha256sum
on the.tar.gz
file - Compare the output of the command with the contents of the
.sha256
file. If they are the same, then your file has not been tampered with
- Download the respective
- Unpack the
.tar.gz file
by running
tar -zxvf bootstub-updater.tar.gz
- You can now run it by running
./bootstub-updater
in the directory the binary was unpacked. It is recommended to place the binary in your $PATH (ex./usr/bin
, which is commonly used), so you can use it from anywhere
Before anything, figure out the command to create an efibootstub that boots your current kernel. Instructions can be found here. NOTE: The program requires administrative privilages
-
-c, --command <COMMAND>
Enter full efibootmgr command to be run when kernel is updated, replacing the kernel version number with%v
. Surround command with quotation marks. -
-b, --bootnum <NUM>
Entry number of current entry inefibootmgr
. Will be removed and replaced with the new one. -
-f, --format <FILENAME>
Example of naming convention of kernel for your current distro. Replace version number with%v
.
ex.vmlinuz-%v
-
-t, --toml <FILEPATH>
Specify the location of a TOML file to configure the program through a config file. An example can be found here. -
-k, --kernel-dir <DIRECTORY>
Optional. If your kernel directory lies somewhere other than at/boot
, specify it here.
bootstub-updater can also be configured through a TOML-formatted config file. You can specify the location of the config file through the --path
option.
Through this config file, you can use the same configuration options as through the command line. An example can be found here.