diff options
author | ramon <ramongomez@us.es> | 2018-04-23 11:47:50 +0000 |
---|---|---|
committer | ramon <ramongomez@us.es> | 2018-04-23 11:47:50 +0000 |
commit | c198e60385a75c764285f5d78bc4ac9da5520708 (patch) | |
tree | 1267f4593ce975d0b8f7f2aebbcdf91213cb1182 | |
parent | 2c5a875a5ffd6c3fec3441a6e865e5df02f769c2 (diff) |
#802 #812: Nueva función {{{ogGetEsp}}} para localizar la partición EFI; integrar últimos cambios de librería {{{Boot}}} en el ticket:812.
git-svn-id: https://opengnsys.es/svn/branches/version1.1@5748 a21b9725-9963-47de-94b9-378ad31fedc9
-rwxr-xr-x | client/engine/Boot.lib | 2 | ||||
-rwxr-xr-x | client/engine/Disk.lib | 17 |
2 files changed, 18 insertions, 1 deletions
diff --git a/client/engine/Boot.lib b/client/engine/Boot.lib index 695feba7..f39180bc 100755 --- a/client/engine/Boot.lib +++ b/client/engine/Boot.lib @@ -139,7 +139,7 @@ esac function ogGetWindowsName () { # Variables locales. -local PART MNTDIR +local MNTDIR # Si se solicita, mostrar ayuda. if [ "$*" == "help" ]; then diff --git a/client/engine/Disk.lib b/client/engine/Disk.lib index 972da3da..c4d0d4d4 100755 --- a/client/engine/Disk.lib +++ b/client/engine/Disk.lib @@ -673,6 +673,23 @@ echo $TYPE #/** +# ogGetEsp +#@brief Devuelve números de disco y partición para la partición EFI (ESP). +#*/ ## +function ogGetEsp () +{ +loacl PART d +for d in $(blkid -t TYPE=vfat -o device); do + PART="$(ogDevToDisk $d)" + if [ "$(ogGetPartitionId $PART)" == "$(ogTypeToId EFI GPT)" ]; then + echo $PART + break + fi +done +} + + +#/** # ogGetLastSector int_ndisk [int_npart] #@brief Devuelve el último sector usable del disco o de una partición. #@param int_ndisk nº de orden del disco |