PROCYON(1)

πŸ’– PROCYON(1) β€” the girlies' guide to the Procyon Java decompiler πŸ’–

okay bestie, sit down, grab your iced coffee β˜• because this is the manual page for procyon, and honestly? it's giving main character energy in a world full of mid decompilers. no cap.


✨ SYNOPSIS ✨

procyon [options] <type names or class/jar files>

like… that's it. that's the whole vibe. options, then some type names or class/jar files, and we go πŸ¦‹


🌸 DESCRIPTION 🌸

so Procyon is a Java decompiler, right? and the thing about her is she actually handles the language glow-ups from Java 5 and beyond that most other decompilers simply cannot deal with. like, they fumble, she does not. πŸ’…

and it's not just that β€” she excels in the areas where the others fall short. lowkey embarrassing for them, honestly. here's where Procyon really pops off:

  • Enum declarations
  • Enum and String switch statements
  • Local classes (both anonymous and named, queen behavior)
  • Annotations
  • Java 8 Lambdas and method references

no notes. ate. πŸ‘‘

πŸŽ€ output modes πŸŽ€

Procyon serves three whole output modes, pick your fighter:

  • Java β€” this is the default one, the classic, the moment
  • Raw Bytecode β€” similar to javap, but prettier. run it with -r
  • Bytecode AST β€” an intermediate representation. run it with -b, and add -u if you want it unoptimized

🧚 what even is an input 🧚

you can pass one or more types as an argument and Procyon will process them. the input types can be:

  • fully-qualified names in dotted or binary form β€” like java.lang.String or java/lang/String
  • relative or absolute file paths β€” like path/to/MyClass.class
  • or literally whole jar files

and if you hand her a type name? she'll go try to load it out of the user or bootstrap classpath. she's resourceful like that 🫢


✨ OPTIONS ✨

every single one, bestie. we do not skip. that would be disrespectful.

  • -b, --bytecode-ast β€” output the Bytecode AST instead of Java. Default: false
  • -ci, --collapse-imports β€” collapse multiple imports from the same package into one single wildcard import. Default: false
  • -cp, --constant-pool β€” includes the constant pool when you're displaying raw bytecode (unnecessary with -v). Default: false
  • -dl, --debug-line-numbers β€” for debugging, show Java line numbers as inline comments (implies -ln; requires -o). Default: false
  • --disable-foreach β€” disable 'for each' loop transforms. Default: false
  • -eml, --eager-method-loading β€” enable eager loading of method bodies (may speed up decompilation of larger archives). Default: false
  • -ent, --exclude-nested β€” exclude nested types when decompiling their enclosing types. Default: false
  • -ei, --explicit-imports β€” [DEPRECATED] explicit imports are now enabled by default. this option will be removed in a future release. Default: false
  • -eta, --explicit-type-arguments β€” always print type arguments to generic methods. Default: false
  • -fsb, --flatten-switch-blocks β€” drop the braces statements around switch sections when possible. Default: false
  • -?, --help β€” display this usage information and exit. Default: false
  • -jar, --jar-file β€” [DEPRECATED] decompile all classes in the specified jar file (disables -ent and -s).
  • -lc, --light β€” use a color scheme designed for consoles with light background colors. Default: false
  • -lv, --local-variables β€” includes the local variable tables when displaying raw bytecode (unnecessary with -v). Default: false
  • -ll, --log-level β€” set the level of log verbosity (0-3). Level 0 disables logging. Default: 0
  • -mv, --merge-variables β€” attempt to merge as many variables as possible. this may lead to fewer declarations, but at the expense of inlining and useful naming. this feature is experimental and may be removed or become the standard behavior in future releases. Default: false
  • -o, --output-directory β€” write decompiled results to the specified directory instead of the console.
  • -r, --raw-bytecode β€” output Raw Bytecode instead of Java (to control the level of detail, see: -cp, -lv, -ta, -v). Default: false
  • -ec, --retain-explicit-casts β€” do not remove redundant explicit casts. Default: false
  • -ps, --retain-pointless-switches β€” do not lift the contents of switches having only a default label. Default: false
  • -ss, --show-synthetic β€” show synthetic (compiler-generated) members. Default: false
  • -sm, --simplify-member-references β€” simplify type-qualified member references in Java output [EXPERIMENTAL]. Default: false
  • -sl, --stretch-lines β€” stretch Java lines to match original line numbers (only in combination with -o) [EXPERIMENTAL]. Default: false
  • -ta, --type-attributes β€” includes type attributes when displaying raw bytecode (unnecessary with -v). Default: false
  • --unicode β€” enable Unicode output (printable non-ASCII characters will not be escaped). Default: false
  • -u, --unoptimized β€” show unoptimized code (only in combination with -b). Default: false
  • -v, --verbose β€” includes more detailed output depending on the output language (currently only supported for raw bytecode). Default: false
  • --version β€” display the decompiler version and exit. Default: false
  • -ln, --with-line-numbers β€” include line numbers in raw bytecode mode; supports Java mode with -o only. Default: false
🫢 little reminder bestie: the [DEPRECATED] ones are on their way out, and the [EXPERIMENTAL] ones might change under you. not being dramatic, just accurate. πŸ’œ

🌈 EXAMPLES 🌈

decompile a single class to the console

$ procyon java.lang.String

$ procyon java.util.Collections

two bangers, back to back. iconic.

decompile a whole jar to a directory

$ procyon myJar.jar -o out

the whole jar?? to a directory?? yes. -o out. she ate that.

decompile a single class from a jar

$ CLASSPATH=myJar.jar procyon com.example.Foo

set CLASSPATH, name your class, go. iykyk πŸ¦‹


πŸ‘‘ SEE ALSO πŸ‘‘

go read the wiki bestie, it's right there πŸ’–


and that's the whole manual, babes. this was procyon 0.5.32, dated October 2016 β€” yeah she's vintage, and vintage is a vibe. stay decompiling, stay hydrated, mwah πŸ’…βœ¨