Shell script to cd into the result of Find
I have this situation where I have a staging directory where a zip file reside. I then unzip it into this directory. I know the zip file will contain a Folder, but I will not know the name, depending on which zip file is there.
i.e., after zipping, my directory will look like this:
And under this UnknownName directory will be a build.xml file that I can run ant on.
Is there a way to cd into the UnknownName directory without knowing the actual name? I tried find . -name build.xml|cd but it didn't do anything. Not sure if i'm doing this right.