Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Posting a download to bitbucket from a shell script

I'd like to be able to fully-automate the process of packaging the release of an application (in Xcode) via shell script and I'd like the zip archive that is released to be a download on bitbucket. Is there a way to programmatically make a (zip) file available as a download on bitbucket?

like image 739
Isaac Avatar asked May 07 '10 01:05

Isaac


2 Answers

I made one which I use to post nightly builds from my buildbot.
It's available for both Bash and Batch, works fine so far.

You can find it here, it's well commented and requires cURL and grep:
https://bitbucket.org/Swyter/bitbucket-curl-upload-to-repo-downloads

Good: Barebones, just 46 LOC, with CSRF handling.
Bad: Doesn't check for captcha or success, you can easily do that yourself parsing the page if you need it.

like image 180
Swyter Avatar answered Oct 23 '22 03:10

Swyter


They have provided API for this . Find it here.

like image 40
charany1 Avatar answered Oct 23 '22 03:10

charany1