GitHub Sale: sign up for any paid plan this week and pay nothing until January 1, 2009!  [ hide ]

public
Description: a ruby-to-pyc compiler
Clone URL: git://github.com/why/unholy.git
why (author)
Mon May 05 02:28:21 -0700 2008
commit  77363ecf78ed1b2eaf1d27b6cdb15503366f60f1
tree    c12444c68120a328fee93040cfee2e4df2322caf
parent  66aad35513f42db8e91f7a77ca1b5401e9a17431
unholy / README
100644 48 lines (28 sloc) 0.754 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
 
 
          $ UNHOLY $
 
  Compile Ruby to Python bytecode.
  And, in addition, translate that
  bytecode back to Python source
  code using Decompyle (included.)
 
 
         $ INSTALL $
 
  First, install decompyle:
 
  > cd decompyle
  > python setup.py build
  # python setup.py install
 
  Then, in the main directory, use
  the tools.
 
            ---
 
  To compile Ruby to a .pyc:
 
  > bin/unholy test.rb
  > python test.rb.pyc
  
            ---
 
  To translate to Python:
 
  > decompyle test.rb.pyc > test.py
 
            ---
 
  And, to view the disassembled
  bytes:
  
  > bin/py-dis test.rb.pyc
 
  Thanks to Ned Batchelder for his
  rather juicy posts on dissecting
  Python bytecode. It is only too
  bad that a Rubyist got a hold of
  them. :(