Can I open RAR files?

Discussion in 'Ruby' started by Xarc, May 22, 2007.

  1. Xarc

    Xarc Guest

    Xarc, May 22, 2007
    #1
    1. Advertising

  2. Xarc

    akbarhome Guest

    On May 22, 1:33 pm, Xarc <> wrote:
    > Hi!
    > How can I open .rar files from ruby?
    >
    > --
    > Posted viahttp://www.ruby-forum.com/.


    Your best bet is using system call for unrar program.
     
    akbarhome, May 22, 2007
    #2
    1. Advertising

  3. Xarc

    vasudevram Guest

    On May 22, 7:05 pm, akbarhome <> wrote:
    > On May 22, 1:33 pm, Xarc <> wrote:
    >
    > > Hi!
    > > How can I open .rar files from ruby?

    >
    > > --
    > > Posted viahttp://www.ruby-forum.com/.

    >
    > Your best bet is using system call for unrar program.


    You may also be able to use popen(), assuming the command line version
    of RAR supports taking arguments to specify listing the contents of
    a .rar file. This way would be a bit more "interactive" than using
    system() to tell RAR to list the .rar files contents to a temp file,
    and then reading that file from your Ruby code.

    Vasudev Ram
    Dancing Bison Enterprises
    http://www.dancingbison.com
     
    vasudevram, May 22, 2007
    #3
  4. Xarc wrote:
    > Hi!
    > How can I open .rar files from ruby?


    There is no native way or right way to do that, the thing is that RAR is
    a propietary file compression format. As <Akbar Home> and <vasudevram>
    said that is your best shot.

    --
    Posted via http://www.ruby-forum.com/.
     
    Jorge Domenico Bucaran Romano, May 22, 2007
    #4
  5. Xarc

    akbarhome Guest

    On May 22, 1:33 pm, Xarc <> wrote:
    > Hi!
    > How can I open .rar files from ruby?
    >
    > --
    > Posted viahttp://www.ruby-forum.com/.


    Your best bet is using system call for unrar program.
     
    akbarhome, May 22, 2007
    #5
  6. Xarc Asda qwerty, May 23, 2007
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    5
    Views:
    351
  2. redglow

    Rar

    redglow, Jan 27, 2004, in forum: Java
    Replies:
    3
    Views:
    2,541
    Marco Schmidt
    Jan 28, 2004
  3. Oliver Hoehle
    Replies:
    0
    Views:
    1,782
    Oliver Hoehle
    Feb 26, 2004
  4. John Smith

    RAR Files

    John Smith, Sep 19, 2005, in forum: Java
    Replies:
    8
    Views:
    17,709
    jeev81
    Jan 6, 2010
  5. fj
    Replies:
    10
    Views:
    863
    Jonathan N. Little
    Dec 5, 2006
Loading...

Share This Page