public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] using ${var} with env import
@ 2011-03-30  8:20 Holger Brunck
  2011-03-30 12:57 ` Wolfgang Denk
  0 siblings, 1 reply; 3+ messages in thread
From: Holger Brunck @ 2011-03-30  8:20 UTC (permalink / raw)
  To: u-boot

Hi all,
I am using env import -t to import environment variables from a textfile.

My simple textfile is:
fdt_file=${hostname}/${hostname}.dtb

I import the file with:
=> tftp 200000 scripts/my_environ.txt
=> env import -t 200000 ${filesize}

Now when I print the variable I get:
=> print fdt_file
fdt_file=${hostname}/${hostname}.dtb

hostname is defined as:
=> print hostname
hostname=mgcoge

I see that the ${hostname} for my fdt_file variable is not replaced. If I do
this with setenv:
=> setenv fdt_file_2 ${hostname}/${hostname}.dtb
=> print fdt_file_2
fdt_file_2=mgcoge/mgcoge.dtb

My variable is replaced.

Is the usage of ${var} in the textfiles not possible? Or is there a way to solve
this problem?

I try to use this textfile for different boards and can therfore not specify
hostname in advance in the textfile.

Best regards
Holger Brunck

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-03-30 15:41 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-30  8:20 [U-Boot] using ${var} with env import Holger Brunck
2011-03-30 12:57 ` Wolfgang Denk
2011-03-30 15:41   ` Holger Brunck

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox