ons 2009-02-25 klockan 11:12 +0100 skrev Laurent Léonard: > Hi, > > Thank you for your script, but I got some errors when I tried to use it... > > P: Begin executing local hooks... > /root/keyboard.sh: line 6: : command not found > /root/keyboard.sh: line 7: : command not found > /root/keyboard.sh: line 9: : command not found > /root/keyboard.sh: line 11: : command not found > > Any idea ? It seems to be a problem with $PATH... > > -- > Laurent Léonard >
Hmm, tricky... I'm afraid I can't help you with the errors, but I can at least tell you how I get this script executed. I assume that you have live-helper installed on your Debian Live build machine and that keyboard.sh is the script provided by me. Note that I execute nearly everything using my normal user account. Root is only used for executing lh_build: 1. Fire up a terminal in the Debian Live build directory. 2. Run lh_config with your selected options. You should at least include --bootappend-live "keyb=XX" (I guess XX should be fr for you?). You should now have a config/ directory in your build directory. 3. Copy my script (keyboard.sh) to config/chroot_local-hooks/. Make sure that the script is executable (chmod +x). This ensures that the script will be executed in the Debian Live chroot by lh_build shortly before it generates the squashfs file. 4. Build your Debian Live image as root using lh_build (sudo lh_build). If you scroll up a bit while lh_build is generating the squashfs file, you should see a line telling that it was " Correcting keyboard settings for the console" (the echo command in my script). If I understand correctly, this is where you get your error messages instead. That should be all! I have never experienced these problems with my script, at least not here on my Debian Live build computer. I send my script as an attachment again, to make sure it went clear through yesterday. Regards, Mikael Petersson, Sweden > Le mercredi 25 février 2009 00:20:57 Mikael Petersson, vous avez écrit : > > tis 2009-02-24 klockan 15:11 +0100 skrev Laurent Léonard: > > > Hi, > > > > > > I'm not sure this mailing list is the right one for user support, but I > > > didn't find other lists about Debian Live... > > > > > > This page explain how it is possible to set a keyboard layout for X or > > > the console : http://live.debian.net/manual/html/language.html > > > keymap=XX-latin1 give a right keyboard layout for the console > > > keymap=XX give a right keyboard layout for X > > > > > > How can I set the right keyboard layout for both X and the console ? > > > > > > Thank you, > > > -- > > > Laurent Léonard > > > > Hello, > > > > I have the following executable hack in config/chroot_local-hooks/. It > > appends '-latin1' to carefully selected places in the live-initramfs > > file /usr/share/initramfs-tools/scripts/live-bottom/19keyboard: > > > > #!/bin/sh > > > > # Correct keyboard settings for the console > > if [ -f /usr/share/initramfs-tools/scripts/live-bottom/19keyboard ] > > then > > echo " Correcting keyboard settings for the console" > > sed -i 's/^\tchroot \/root \/usr\/sbin\/install-keymap ${kbd}/&-latin1/' > > \ /usr/share/initramfs-tools/scripts/live-bottom/19keyboard > > sed -i 's/^\tlive-preseed \/root debian-installer\/keymap > > "${kbd}"/&-latin1/' \ > > /usr/share/initramfs-tools/scripts/live-bottom/19keyboard > > sed -i 's/^\tlive-preseed \/root kbd-chooser\/method "${kbd}"/&-latin1/' > > \ /usr/share/initramfs-tools/scripts/live-bottom/19keyboard > > fi > > > > This makes it possible for me to append "keyb=se" to the boot parameters > > for my Debian Live system and have a working swedish keyboard both on > > the console and in X > > > > Good luck! > > > > Mikael Petersson > >
keyboard.sh
Description: application/shellscript