node-bitbucket icon indicating copy to clipboard operation
node-bitbucket copied to clipboard

How to pass files as string in createFileCommit method

Open ayush04 opened this issue 4 years ago • 0 comments

I have a react client from where a user can drag and drop some files. I am sending those files to a node app from where I want to commit those files to Bitbucket repo. I am using multer to get the files in node.

My problem is, I am not sure how to pass these files to BitBucket. The documentation here says the files parameter should be a string. Can someone please provide an example as to how convert a file to a string? Is it the content that should be converted? If so, how to pass the filename?

ayush04 avatar Jan 05 '22 15:01 ayush04