[ipxe-devel] [ipxe/ipxe] Parse ${name:offset:length} in setting values (#95)

Joe Groocock notifications at github.com
Mon Sep 2 16:35:14 UTC 2019


This emulates the bash `${varname:offset:length}` syntax allowing substring manipulation of settings values. It operates during the `fetchf_setting` stage so should work for show, echo and any form of setting substitution.

It extends the existing syntax like name:type:offset:length, e.g.

```
show smbios/product:string:0:8
show smbios/uuid::0:24
echo ${ifname::3:4}
```
You can view, comment on, or merge this pull request online at:

  https://github.com/ipxe/ipxe/pull/95

-- Commit Summary --

  * Parse ${name:offset:length} in setting values

-- File Changes --

    M src/core/settings.c (112)
    M src/include/ipxe/settings.h (6)

-- Patch Links --

https://github.com/ipxe/ipxe/pull/95.patch
https://github.com/ipxe/ipxe/pull/95.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/ipxe/ipxe/pull/95
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ipxe.org/pipermail/ipxe-devel/attachments/20190902/8904394f/attachment.htm>


More information about the ipxe-devel mailing list