aboutsummaryrefslogtreecommitdiff
path: root/i18n/fr_FR/docs/grub
diff options
context:
space:
mode:
authorLibreboot Contributor <contributor@libreboot.org>2020-03-18 17:20:14 +0100
committerLibreboot Contributor <contributor@libreboot.org>2020-03-18 17:20:27 +0100
commit0f6ea1c9e0a25a9b7546f96f27cef8841f0d09b5 (patch)
treea28b9403123dd6204eb2dd8cb44eada12c169f4b /i18n/fr_FR/docs/grub
parent6e5bdd1271059a9c61c80b21001fd3d14ff25045 (diff)
downloadlibrebootfr-0f6ea1c9e0a25a9b7546f96f27cef8841f0d09b5.tar.gz
librebootfr-0f6ea1c9e0a25a9b7546f96f27cef8841f0d09b5.zip
Creation of i18n folder containing translations of the libreboot project. Added french one, not finished.
Diffstat (limited to 'i18n/fr_FR/docs/grub')
-rw-r--r--i18n/fr_FR/docs/grub/grubeditor.md121
-rw-r--r--i18n/fr_FR/docs/grub/index.md103
2 files changed, 224 insertions, 0 deletions
diff --git a/i18n/fr_FR/docs/grub/grubeditor.md b/i18n/fr_FR/docs/grub/grubeditor.md
new file mode 100644
index 00000000..628d184f
--- /dev/null
+++ b/i18n/fr_FR/docs/grub/grubeditor.md
@@ -0,0 +1,121 @@
+# GRUB EDITOR
+
+Libreboot ROM images now support fluid _grub.cfg_ and _grubtest.cfg_
+configuration editing with the grubeditor.sh script! Instead of manually running
+cbfstool to manipulate these configuration files, this script will handle the
+work for you so you can focus on actually modifying your GRUB configuration
+files to your setup's needs.
+
+At the time of this writing, grubeditor.sh supports extracting and editing
+either the grub.cfg or grubtest.cfg file in any cbfstool-compatible Libreboot
+ROM image that contains these files, even ones that have been previously
+modified. It can also swap these configuration files in an existing ROM image,
+handy if you have a working grubtest.cfg and want to make it the default or if
+you broke the main grub.cfg and know that your grubtest.cfg still works. Lastly,
+it can also run diff on these two configuration files to show you how they
+differ.
+
+## Requirements
+
+grubeditor.sh requires an x86, x86\_64, or armv7l environment, since these are
+the environments for which cbfstools binaries are provided. Additionally,
+grubeditor.sh needs a Bash environment with extended getopt functionality that
+can run the **diff** command and write to /tmp. Lastly, the script expects to
+live in the top directory of the Libreboot utilities package so it can properly
+call cbfstool.
+
+Chances are that you already meet these requirements if you are on a Linux
+environment of the listed architectures and downloaded the Libreboot utilities
+package from an official source. If not, it shouldn't be too hard to use a
+Linux LiveCD of your choice which provides these essentials.
+
+Optionally, you should make sure your EDITOR variable is set. Otherwise,
+grubeditor.sh will default to using vi, which may not exist on your system. You
+can override this default or the contents of your EDITOR variable using the
+**-e** or **--editor** command.
+
+## Usage help
+
+grubeditor.sh takes a number of options, the only one which is required being a
+valid Libreboot ROM image that uses the GRUB2 payload and contains both
+_grub.cfg_ and _grubtest.cfg_ files. Additional options should come _before_ the
+ROM image file on the command line.
+
+grubeditor.sh supports combining several short options with a single hyphen
+like **-ris**, but you can also list them separately like **-r -i -s**. Long
+options must always be written as standalone arguments.
+
+You can use the **-h** or **--help** option to view a brief summary of the
+options available. Consider this guide a more extensive version of this screen.
+
+Lastly, you can check which version of grubeditor.sh you are using with the
+**-v** or **--version** option.
+
+## Editing configuration files
+
+Invoked without any arguments except for the ROM image, grubeditor.sh will
+attempt to extract the _grubtest.cfg_ file from the provided ROM image and
+launch it in your editor of choice. If you make changes to the file,
+grubeditor.sh will incorporate your changes into a new ROM image with the same
+name in the same directory, except that the new ROM file will end with
+".modified". You can then flash this ROM image to your platform's BIOS chip.
+
+If you would prefer to edit the actual _grub.cfg_ configuration file, use the
+**-r** or the **--realcfg** option. Everything else will work the same except
+that your editor will open the _grub.cfg_ instead.
+
+If you would prefer to overwrite your existing ROM image instead of creating a
+new one ending in ".modified" use the **-i** or **--inplace** option.
+Naturally, you can combine this option with the **-r/--realcfg** option
+described above.
+
+## Swapping grub.cfg and grubtest.cfg
+
+grubeditor.sh supports swapping the _grub.cfg_ and _grubtest.cfg_ configuration
+files with the **-s** or **--swap** option. This will create a new ROM image
+alongside the existing ROM image ending with ".modified" which has these files
+swapped. Naturally, you can request this operation overwrite the existing file
+instead using the **-i/--inplace** option.
+
+Note that the script will automatically modify the "Load test configuration
+(grubtest.cfg)" menu entry in both configuration files during this operation.
+If this was not done, these entries would end up being self-referential after
+the rename, breaking their intended functionality of changing between the
+configuration files.
+
+For best results, please do not modify this section without studying the source
+code of _grubeditor.sh_ and making sure your edits do not impact the script's
+ability to perform this modification
+
+## Swapping grub.cfg and grubtest.cfg
+
+grubeditor.sh supports comparing _grub.cfg_ and _grubtest.cfg_ files for
+differences with the **-d** or **--diffcfg** option. This uses the diff command
+by default, but if you want to use another program (e.g. vimdiff), you can
+specify it with the **-D** or **--differ** option. Note that this mode is only
+intended to show differences in the files and does not support updating the
+configs themselves, so any changes you make in an interactive differ will be
+ignored.
+
+## Extracting a configuration file
+
+You can simply extract a configuration file using the **-x** or **--extract**
+option. This option is responsive to the **-r/--realcfg** option for choosing
+between grubtest.cfg and grub.cfg.
+
+## Pending development
+
+TODO:
+- allow injecting configuration files to complement the extractor.
+- detect potentially devastating corner cases, however rare they may actually be
+- i can't specify a quoted command line with arguments to -e or -D, why?
+- support editing both config files if using an interactive differ
+- work with other types of files besides the grub configuration files.
+
+## Conclusion
+
+I hope that grubeditor.sh will significantly ease modifying your configuration
+files in your Libreboot ROM files.
+
+Should you find any bugs or want any feature requests, please don't hesitate to
+email me or bug me on IRC.
diff --git a/i18n/fr_FR/docs/grub/index.md b/i18n/fr_FR/docs/grub/index.md
new file mode 100644
index 00000000..65d4863f
--- /dev/null
+++ b/i18n/fr_FR/docs/grub/index.md
@@ -0,0 +1,103 @@
+---
+title: GRUB payload
+x-toc-enable: true
+...
+
+This section relates to the GRUB payload used in libreboot.
+
+Changing the background image in GRUB
+=====================================
+
+Use cbfstool from libreboot\_util, or
+libreboot\_src/coreboot/util/cbfstool/ if you want to build from source.
+
+ $ ./cbfstool yourrom.rom remove background.png -n background.png
+ $ ./cbfstool yourrom.rom add -f background.png -n background.png -t raw
+
+When you've done this, re-flash your ROM and you should have a new
+background at boot time.
+
+Setting font in GRUB (for reference)
+====================================
+
+You don't need to do this unless you would like to change the default
+font yourself. (this is just for reference. It has already been done for
+you)
+
+The old font used was Unifont, and this had some missing characters: for
+instance, the border showed ??? characters instead of lines.
+
+I tried DeJavu Sans Mono from this website:
+[dejavu-fonts.org](http://dejavu-fonts.org/wiki/Download)
+
+Specifically, the version that I chose was the latest at the time of
+writing (Saturday 21 June 2014): [this
+one](http://sourceforge.net/projects/dejavu/files/dejavu/2.34/dejavu-fonts-ttf-2.34.tar.bz2)
+
+This is a free font that is also contained in GNU+Linux distributions
+like Debian, Devuan or Parabola.
+
+ $ cd libreboot\_src/grub
+
+compile grub (the build scripts info on how to do this)\
+come back out into libreboot\_src/resources/grub:
+
+ $ cd ../libreboot\_src/resources/grub/font
+
+I took Dejavu Sans Mono from dejavu (included in this version of
+libreboot) and did:
+
+ $ ../../../grub/grub-mkfont -o dejavusansmono.pf2 dejavu-fonts-ttf-2.34/ttf/DejaVuSansMono.ttf
+
+I then added the instructions to 'gen.sh' script in grub-assemble to
+include resources/grub/dejavusansmono.pf2 in all of the ROM images, at
+the root of the GRUB memdisk.\
+I then added that instructions to the grub.cfg files (to load the
+font):
+
+ loadfont (memdisk)/dejavusansmono.pf2
+
+GRUB keyboard layouts (for reference)
+=====================================
+
+Custom keyboard layout in GRUB (for reference)
+----------------------------------------------
+
+Keymaps are stored in resources/utilities/grub-assemble/keymap/.
+
+Example (French Azerty):
+
+ $ ckbcomp fr > frazerty
+
+Go in grub directory:
+
+ $ cat frazerty | ./grub/grub-mklayout -o frazerty.gkb
+
+You must make sure that the files are named keymap and keymap.gkb (where
+'keymap' can be whatever you want).
+
+Then from the above example, you would put `frazerty` in
+`resources/utilities/grub-assemble/keymap/original/` and the
+`frazerty.gkb` file goes under
+`resources/utilities/grub-assemble/keymap/`
+
+The build scripts will automatically see this, and automatically build
+ROM images with your custom layout (given the name) and include them
+under bin. Example: `libreboot_frazerty.rom`.
+
+UK Dvorak keyboard layout in GRUB (for reference)
+-------------------------------------------------
+
+ukdvorak had to be created manually, based on usdvorak. diff them (under
+resources/utilities/grub-assemble/keymap/original) to see how ukdvorak
+file was created
+
+ $ cat ukdvorak | ./grub/grub-mklayout -o ukdvorak.gkb
+
+Copyright © 2014 Leah Rowe <info@minifree.org>\
+
+Permission is granted to copy, distribute and/or modify this document
+under the terms of the GNU Free Documentation License Version 1.3 or any later
+version published by the Free Software Foundation
+with no Invariant Sections, no Front Cover Texts, and no Back Cover Texts.
+A copy of this license is found in [../fdl-1.3.md](../fdl-1.3.md)