On Thu, 18 Nov 2021 at 21:37, Artem Lapkin <[email protected]> wrote: > > Add possibility setup env variable with additional resolving vars inside > value. > > Usage examples: > > => setenv a hello; setenv b world; setenv c '${a} ${b}' > => setenv -r d '${c}! ${a}...' > => printenv d > d=hello world! hello... > > /* internal usage example */ > env_resolve("d", "${c}! ${a}..."); > /* d="hello world! hello..." */ > > Signed-off-by: Artem Lapkin <[email protected]> > --- > V2 changes: > _ fix comments style > _ add comment include/exports.h > _ remake strcpy to strdup > _ env_resolve minimize > --- > cmd/nvedit.c | 43 ++++++++++++++++++++++++++++++++++++++++++- > include/_exports.h | 1 + > include/env.h | 11 +++++++++++ > include/exports.h | 2 ++ > 4 files changed, 56 insertions(+), 1 deletion(-)
Reviewed-by: Simon Glass <[email protected]>

