[PATCH v6 4/7] env: Allow U-Boot scripts to be placed in a .env file
wd at denx.de
Tue Oct 19 12:33:11 CEST 2021
In message <20211018142404.GR7964 at bill-the-cat> you wrote:
> > > Perhaps we should just make "+" an illegal character in the variable
> > > name, for consistency?
> > And break backward compatibility? I'd rather see a better
> > definition of the syntax of the environment files, plus maybe a more
> > powerful parser.
> Are there examples today of scripts that use "+" in the variable names?
None that I know of.
> That maybe someone wrote a custom an private thing that uses + in the
> name isn't the best argument. Someone saying that did would be better.
Yes, I know. But then, changing existing APIs is not nice.
> Of course yes, if we can just make the parser handle it, without it also
> being a tricky nightmare, that's the better solution.
> > Hm... I can't find it right now but did I not also read about other
> > restrictions to variable names, like they must noch begin with '_'
> > when using this new tool?
> Any invalid characters need to be clearly documented, if they aren't,
So far, only NUL and '=' were impossible to use in a variable name.
> > I feel it is wrong to place new restrictions on something that was
> > constant for 21 years, just because our parser cannot parse it...
> Sure. But if it's also the case that for 21 years no one has been using
> foo+bar, baz+, etc, in their variable names, maybe we just document
> that's not valid and move on?
We cannot know what people have been using in their environemnts.
Even for those boards that are in mainline, the environment settings
used in real life are often totally different.
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Save yourself! Reboot in 5 seconds!
More information about the U-Boot