I'm using BitBucket Pipelines for the first time to SSH into a development server and perform a git pull origin branch
whenever a push is made to the said branch. It's quite simple and everything is going as expected.
Problem arises when a merge comes along the pull and a user input is required to commit the merge. I get the following message in the failed build's logs:
* branch feature/development -> FETCH_HEAD
d2c27a5f..63d74c8f feature/development -> origin/feature/development
error: Terminal is dumb, but EDITOR unset
Not committing merge; use 'git commit' to complete the merge.
I would simply like to bypass this user input requirement, commit if necessary and move on.
Here's my build configuration:
image: php:7.1.29
pipelines:
default:
- step:
name: Deploy to dev
deployment: dev
# trigger: manual # Uncomment to make this a manual deployment.
script:
- echo "Deploying to dev..."
- pipe: atlassian/ssh-run:0.2.5
variables:
SSH_USER: 'root'
SERVER: '82.xxx.xx.xx5'
MODE: 'command'
COMMAND: 'cd /home/ubuntu/public_html/dev/ && \
git pull origin feature/development'
- echo "Deployed!"
I haven't the faintest how to achieve this. Any hints would be great. TIA!
git pull
is trying to open an editor to ask for a merge commit's message and failed. Trygit pull --rebase
to avoid merge (but get ready for conflicts). Or rungit pull --no-commit && git commit -m "Merge"
– Nominee--no-commit && git commit -m "Merge"
and it worked like a charm. I also went ahead and added-X theirs
to ensure incoming changes are accepted automatically. Please turn your comment into an answer so I can accept it. @Nominee :) – Portia