I am trying to fetch a file from a private repository, a shell script. And I'd like to run it immediately.
I tried with
curl --user username:pass https://repo_path/file.sh | sh
But I don't get anything. I even tried putting app password, again, nothing.
I tried with
curl https://user:password@bitbucket.org/repo_path/file.sh | sh
No luck.
Any ideas how should I do this?
I'm doing this so that the new users can just paste this line in their terminal, and the script will set the project up for them (clone the repo among other things).
Ok, I managed to do it, by doing a request to the Bitbucket API, with the correct endpoint and app password.
curl -u username https://api.bitbucket.org/1.0/repositories/user_repo_name/repo_name/raw/master/file.sh | sh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.