~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/weave.py

  • Committer: Martin Pool
  • Date: 2005-08-18 05:57:53 UTC
  • Revision ID: mbp@sourcefrog.net-20050818055753-0abfa8dd95582c1b
- use psyco for weave if possible
- weave tool takes --profile option

Show diffs side-by-side

added added

removed removed

Lines of Context:
769
769
    from weavefile import write_weave, read_weave
770
770
    from bzrlib.progress import ProgressBar
771
771
 
772
 
    #import psyco
773
 
    #psyco.full()
 
772
    try:
 
773
        import psyco
 
774
        psyco.full()
 
775
    except ImportError:
 
776
        pass
774
777
 
775
778
    cmd = argv[1]
776
779
 
893
896
 
894
897
if __name__ == '__main__':
895
898
    import sys
896
 
    sys.exit(main(sys.argv))
 
899
    if sys.argv[1] == '--profile':
 
900
        args = sys.argv[:]
 
901
        del args[1]
 
902
        sys.exit(profile_main(args))
 
903
    else:
 
904
        sys.exit(main(sys.argv))
897
905