# In \`\`': No such file or directory - getcwd (Errno::ENOENT)

**URL:** <https://www.ruby-forum.com/t/in-no-such-file-or-directory-getcwd-errno-enoent/82911>\
**Category:** Ruby\
**Created:** [January 22, 2007, 11:10am UTC](https://www.ruby-forum.com/t/in-no-such-file-or-directory-getcwd-errno-enoent/82911 "2007-01-22T11:10:52Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [January 22, 2007, 11:10am UTC](https://www.ruby-forum.com/t/in-no-such-file-or-directory-getcwd-errno-enoent/82911/1 "2007-01-22T11:10:52Z")

</div>

Hi,  
I’m getting this error message when I’m using the back tick method  
(the one that return the stdout of a subshell command):

when my ruby runs the following a=`ls -l` it returns

No such file or directory - getcwd (Errno::ENOENT)

does someone have any idea why does it happen?

thanks,  
Amos

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [January 22, 2007, 8:15pm UTC](https://www.ruby-forum.com/t/in-no-such-file-or-directory-getcwd-errno-enoent/82911/2 "2007-01-22T20:15:25Z")

</div>

On Jan 22, 2007, at 02:10, amos wrote:

> Hi,  
> I’m getting this error message when I’m using the back tick method  
> (the one that return the stdout of a subshell command):
> 
> when my ruby runs the following a=`ls -l` it returns
> 
> No such file or directory - getcwd (Errno::ENOENT)
> 
> does someone have any idea why does it happen?

You deleted .

–  
Eric H. - removed\_email\_address@domain.invalid - [http://blog.segment7.net](http://blog.segment7.net)

I LIT YOUR GEM ON FIRE!
