def _generate_java_binary(target_name, onejar_path, jvm_flags, run_args):
 onejar_name = os.path.basename(onejar_path)
 full_path = os.path.abspath(onejar_path)
 target_file = open(target_name, 'w')
 target_file.write(('#!/bin/sh\n# Auto generated wrapper shell script by blade\n\njar=`dirname "$0"`/"%s"\nif [ ! -f "$jar" ]; then\n  jar="%s"\nfi\n\nexec java %s -jar "$jar" %s $@\n' % (onejar_name, full_path, jvm_flags, run_args)))
 os.chmod(target_name, 493)
 target_file.close()
 return None

def _generate_java_binary ( target_name , onejar_path , jvm_flags , run_args ) : onejar_name = os . path . basename ( onejar_path ) full_path = os . path . abspath ( onejar_path ) target_file = open ( target_name , 'w' ) target_file . write ( ( '#!/bin/sh\n# Auto generated wrapper shell script by blade\n\njar=`dirname "$0"`/"%s"\nif [ ! -f "$jar" ]; then\n  jar="%s"\nfi\n\nexec java %s -jar "$jar" %s $@\n' % ( onejar_name , full_path , jvm_flags , run_args ) ) ) os . chmod ( target_name , 493 ) target_file . close ( ) return None
generate a wrapper shell script to run jar .