(self, payload, path, filename=None)
Add an attachment to the build (useful for constructing the build)
        payload should be a file-like object
        filename should be something like "Nokia/S40-generic/CommCare.jar"
Add an attachment to the build (useful for constructing the build)
        payload should be a file-like object
        filename should be something like "Nokia/S40-generic/CommCare.jar"
Add an attachment to the build ( useful for constructing the build ) payload should be a file - like object filename should be something like Nokia / S40 - generic / CommCare . jar
def put_file(self, payload, path, filename=None):
        """
        Add an attachment to the build (useful for constructing the build)
        payload should be a file-like object
        filename should be something like "Nokia/S40-generic/CommCare.jar"

        """
        if filename:
            path = '/'.join([path, filename])
        content_type = {
            'jad': 'text/vnd.sun.j2me.app-descriptor',
            'jar': 'application/java-archive',
        }.get(path.split('.')[-1])
        self.put_attachment(payload, path, content_type, domain=SHARED_DOMAIN)
def put_file ( self , payload , path , filename = None ) : if filename : path = '/' . join ( [ path , filename ] ) content_type = { 'jad' : 'text/vnd.sun.j2me.app-descriptor' , 'jar' : 'application/java-archive' , } . get ( path . split ( '.' ) [ - 1 ] ) self . put_attachment ( payload , path , content_type , domain = SHARED_DOMAIN )