p
SuSE 12.3 repositories contain a stable version, check here if you want to look at the latest version from the developers.
I called my theme "quickboot" for ease of reading and understanding this page. I have used "quickboot" in all these examples. Once you are up and running, you can call your plymouth screen whatever you want.
Here is a summary, with links to the details :
[Plymouth Theme] Name=quickboot Description=My plymouth splash screen ModuleName=script [script] ImageDir=/usr/share/plymouth/themes/quickboot ScriptFile=/usr/share/plymouth/themes/quickboot/quickboot.script [script-env-vars] example_env_var=example env var value
# # # NOTE : Use this to compile plymouth into the initrd # # su - root # # cd /usr/share/plymouth/themes/quickboot # # plymouth-set-default-theme quickboot -R # #
paul@sheldon:~/linuxtips/plymouth> cat /usr/lib/systemd/system/plymouth-start.service [Unit] Description=Show Plymouth Boot Screen DefaultDependencies=no Wants=systemd-ask-password-plymouth.path After=systemd-vconsole-setup.service systemd-udev-trigger.service Before=systemd-ask-password-plymouth.service ConditionKernelCommandLine=!plymouth.enable=0 [Service] ExecStart=/bin/false paul@sheldon:~/linuxtips/plymouth>
paul@sheldon:~/linuxtips/plymouth> cat /etc/init.d/boot.cycle #! /bin/sh # # Copyright (c) 2003 SuSE Linux AG, Nuernberg, Germany. # All rights reserved. # # File: /etc/init.d/boot.loadmodules # Author: Werner Fink# ### BEGIN INIT INFO # Provides: boot.cycle # Required-Start: boot.localfs # Should-Start: boot.loadmodules # Required-Stop: boot.localfs # Should-Stop: boot.loadmodules # Default-Start: B # Default-Stop: # Description: Set default boot entry if called ### END INIT INFO # PAUL : This seemed to rewrite the OLD grub (menu.lst) boot # process with that old "last one booted is now default" chestnut. local_text=$(/usr/local/bin/reformat_confucious -l 45 -t "$(/usr/bin/fortune)") /usr/bin/plymouth display-message --text="$local_text"
# This is a quick plymouth boot screen. # # bgimage.image = Image("new_plymouth_bg.png"); my_background.sprite = Sprite(bgimage.image); my_background.sprite.SetX(0); my_background.sprite.SetY(0); my_background.sprite.SetOpacity(1.0); ############# # callbacks # ############# ########## # status # ########## statusmsg.sprite = Sprite(); counter_statusmsg = 0; fun update_status_callback (text) { counter_statusmsg++; status.image = Image.Text(counter_statusmsg + " - " + text, 1, 1, 1, 1, "droidsansmono", "left"); statusmsg.sprite.SetImage(status.image); statusmsg.sprite.SetX(150); statusmsg.sprite.SetY(660); statusmsg.sprite.SetOpacity(1.0); } Plymouth.SetUpdateStatusFunction(update_status_callback); ########### # message # ########### # This is called from the shell scripts, using the # plymouth command # plymouth display-message --text="". # messagemsg.sprite = Sprite(); fun message_callback (text) { message.image = Image.Text(text, 1, 1, 1, 1, "droidsansmono", "left"); messagemsg.sprite.SetImage(message.image); messagemsg.sprite.SetX(900); messagemsg.sprite.SetY(80); messagemsg.sprite.SetOpacity(1.0); } Plymouth.SetMessageFunction(message_callback); ################# # Boot Progress # ################# # # Boot Progress : Show the time and %age progress # bootprogressmsg.sprite = Sprite(); fun boot_progress_callback (time_taken, percentage_progress) { progress.image = Image.Text("Time : " + time_taken + "\nProgress : " + percentage_progress, 1, 1, 1, 1, "droidsansmono", "left"); bootprogressmsg.sprite.SetImage(progress.image); bootprogressmsg.sprite.SetX(1000); bootprogressmsg.sprite.SetY(600); bootprogressmsg.sprite.SetOpacity(1.0); if (Plymouth.GetMode () == "shutdown") { statusmsg.sprite.SetOpacity(1.0); bootprogressmsg.sprite.SetOpacity(1.0); } } Plymouth.SetBootProgressFunction (boot_progress_callback); ######## # quit # ######## fun quit_callback () { statusmsg.sprite.SetOpacity(1.0); my_background.sprite.SetOpacity(1.0); bootprogressmsg.sprite.SetOpacity(1.0); messagemsg.sprite.SetOpacity(1.0); } Plymouth.SetQuitFunction(quit_callback);