bash variables not accepted by program
<p>I'm using bash to make a little program that is using <a href="https://www.theiphonewiki.com/wiki/IRecovery" rel="nofollow">irecovery</a>, a tool for iOS devices and I'm trying to automate the process of using it.</p>

<p>I have created variables that search for files in a specific folder, so other users can use the same program with different files, though the problem is that the variables aren't replaced by the names of the files and so "irecovery" can't access them.</p>

<p>My code looks like this </p>

<pre><code>#!/bin/bash

dtree=$(find Downgrade -type f -iname device*)
ramdisk=$(find Downgrade -type f -name *.dmg)
kernel=$(find Downgrade -type f -iname kernel*)

./irecovery -s &lt;&lt;EOF

/send $dtree
devicetree
/send $ramdisk
ramdisk
/send $kernel
bootx
reboot
EOF
</code></pre>

<p>Now how would I get bash to print out the variable before it is used by irecovery, or make irecovery use the variable defined in bash?</p>