# Running system() without output

**URL:** <https://rubytalk.org/t/running-system-without-output/47301>\
**Category:** ruby-talk\
**Created:** [24 June 2008 01:21 UTC](https://rubytalk.org/t/running-system-without-output/47301 "2008-06-24T01:21:09Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yanik\_Magnan](https://avatars.discourse-cdn.com/v4/letter/y/4bbf92/32.png) [@Yanik\_Magnan](https://rubytalk.org/u/Yanik_Magnan)\
**Post date:** [24 June 2008 01:21 UTC](https://rubytalk.org/t/running-system-without-output/47301/1 "2008-06-24T01:21:09Z")

</div>

Heya,

I'm relatively new to Ruby, but I haven't found any way of doing this  
by looking through the documentation. I want to call  
system("/usr/bin/sometask #{somefile}"), except the task in question  
doesn't have a --quiet modifier. Is there anyway to keep the output  
from showing up whenever I run my ruby script?

> **···**
>
> --  
> Yanik Magnan • [http://r-ch.net](http://r-ch.net)

---

<div class="post-metadata">

**Author:** ![a11](https://yyz1.discourse-cdn.com/flex029/user_avatar/rubytalk.org/a11/32/8169_2.png) [@a11](https://rubytalk.org/u/a11)\
**Post date:** [24 June 2008 01:42 UTC](https://rubytalk.org/t/running-system-without-output/47301/2 "2008-06-24T01:42:17Z")

</div>

`#{ command }`

a @ [http://codeforpeople.com/](http://codeforpeople.com/)

> **···**
>
> On Jun 23, 2008, at 7:21 PM, Yanik Magnan wrote:
> 
> > Heya,
> > 
> > I'm relatively new to Ruby, but I haven't found any way of doing this  
> > by looking through the documentation. I want to call  
> > system("/usr/bin/sometask #{somefile}"), except the task in question  
> > doesn't have a --quiet modifier. Is there anyway to keep the output  
> > from showing up whenever I run my ruby script?
> 
> --  
> we can deny everything, except that we have the possibility of being better. simply reflect on that.  
> h.h. the 14th dalai lama

---

<div class="post-metadata">

**Author:** ![Yanik\_Magnan](https://avatars.discourse-cdn.com/v4/letter/y/4bbf92/32.png) [@Yanik\_Magnan](https://rubytalk.org/u/Yanik_Magnan)\
**Post date:** [24 June 2008 01:51 UTC](https://rubytalk.org/t/running-system-without-output/47301/3 "2008-06-24T01:51:17Z")

</div>

That works! Thanks.

> **···**
>
> On 6/23/08, ara.t.howard \<ara.t.howard@gmail.com\> wrote:
> 
> > On Jun 23, 2008, at 7:21 PM, Yanik Magnan wrote:
> > 
> > \> Heya,  
> > \>  
> > \> I'm relatively new to Ruby, but I haven't found any way of doing this  
> > \> by looking through the documentation. I want to call  
> > \> system("/usr/bin/sometask #{somefile}"), except the task in question  
> > \> doesn't have a --quiet modifier. Is there anyway to keep the output  
> > \> from showing up whenever I run my ruby script?  
> > \>
> > 
> > `#{ command }`
> > 
> > a @ [http://codeforpeople.com/](http://codeforpeople.com/)  
> > --  
> > we can deny everything, except that we have the possibility of being  
> > better. simply reflect on that.  
> > h.h. the 14th dalai lama
> 
> --  
> Yanik Magnan • [http://r-ch.net](http://r-ch.net)
