2013-12-21, 01:44
This addon will reboot your linux pc once into another OS of your choice then boot back into linux. It uses GRUB so a working multi-boot setup with GRUB is required. It has been tested with GRUB 1.99 + 2.00, but it will probably work with any distro that uses GRUB. Manual editing of system files and files contained within the addon zip is required to get this addon working (edit icon.png preferably before installation):
script.reboot2oos\addon.xml
Edit the name= tag to your liking. I currently have it named Games because I reboot into windows to play games and emulators.
script.reboot2oos\default.py
This is the message that is contained in the Yes/No dialog
script.reboot2oos\icon.png
The addon icon can be changed based on your needs. It is currently a Atari 2600 joystick as I reboot into windows to play games.
script.reboot2oos\reboot2oos.sh
The entries following the above options correspond to your GRUB menu entries - REBOOT_TO= is the OS you want to reboot once to, DEFAULT_OS= is your default OS.
You can get a listing of OS's recognised by GRUB with the following command:
After installing the addon edit /etc/default/grub and change the line
to
then exit and now you need to edit the sudoers file so the commands that require root can run without a password:
At the end of the file after #includedir /etc/sudoers.d add (note you need to edit the username, mine is xbmc):
Now time to make the reboot2oos.sh script executable and update GRUB:
Now select 'Games' under Programs to use the addon and reboot once to the OS of your choice.
DOWNLOAD
script.reboot2oos\addon.xml
Code:
name=
script.reboot2oos\default.py
Code:
if dialog.yesno("Reboot to windows...", "XBMC needs to reboot for Games"):
script.reboot2oos\icon.png
The addon icon can be changed based on your needs. It is currently a Atari 2600 joystick as I reboot into windows to play games.
script.reboot2oos\reboot2oos.sh
Code:
REBOOT_TO=
DEFAULT_OS=
You can get a listing of OS's recognised by GRUB with the following command:
Code:
sed -n '/menuentry/s/.*\(["'\''].*["'\'']\).*/\1/p' /boot/grub/grub.cfg
After installing the addon edit /etc/default/grub and change the line
Code:
GRUB_DEFAULT=
Code:
GRUB_DEFAULT=saved
Code:
sudo visudo
Code:
%xbmc ALL = NOPASSWD: /sbin/reboot, /usr/sbin/grub-set-default, /usr/sbin/grub-reboot
Now time to make the reboot2oos.sh script executable and update GRUB:
Code:
chmod +x ~/.xbmc/addons/script.reboot2oos/reboot2oos.sh
sudo update-grub
Now select 'Games' under Programs to use the addon and reboot once to the OS of your choice.
DOWNLOAD