Shopping Cart My Cart Account Log In Walkthrough IDE Integrations Contact Partner  
Polystyle
The Elegant, Intelligent Source Code Formatter

Click Here To Download A Free Trial!
C/C++   PerlPascal/Delphi
C#   CSSCMAC
Java Javascript   PHP 
JSP HTMLPython
ASP Visual BasicActionscript
Home Features Documentation Buy Polystyle Download  
Step 3: Formatted Python Source

  • Overall Python Features
  • Step 1: Unformatted Source
  • Step 2: Example Source
  • Step 3: Formatted Source

    Here are the final results which you can see are much easier to read!

    Now that you've seen what Polystyle can do for you, why not download a copy and try it out yourself?


    class bdist_rpm (Command):
        user_options = [('bdist-base=',
            None, "base directory for creating built distributions"),
            ('rpm-base=',
                None, "base directory for creating RPMs (defaults to \"rpm\" under "
                "--bdist-base; must be specified for RPM 2)"),
            ('dist-dir=', 'd', "directory to put final RPM files in "
                "(and .spec files if --spec-only)"),
            ('source-only', None, "only generate source RPM"),
            ('binary-only', None, "only generate binary RPM")]
    
        def _format_changelog (self, changelog):
            if not changelog:
                return changelog
    
            new_changelog = []
    
            for line in string.split (string.strip(changelog), '\n'):
                line = string.strip(line)
    
                if line[0] == '*':
                    new_changelog.extend([''])
    
                elif line[0] == '-':
                    new_changelog.append(line)
    
                else:
                    new_changelog.append('  ' + line)

    Take Polystyle for a spin: Download a copy here!

  • Home Features Documentation Buy Polystyle Download  

    Click Here To Download A Free Trial!

    Copyright © Flashbulb Studios. All rights reserved.