Skip to content
This repository has been archived by the owner on Jun 10, 2018. It is now read-only.

Not working when running in Gitlab CI #24

Open
ljesus opened this issue Nov 27, 2017 · 1 comment
Open

Not working when running in Gitlab CI #24

ljesus opened this issue Nov 27, 2017 · 1 comment

Comments

@ljesus
Copy link

ljesus commented Nov 27, 2017

Hello, I'm getting this issue when running the task with Gitlab CI:

00:00 git_copy:clone
01 mkdir -p /tmp/_edd1c32f_edd1c32f
✔ 01 localhost 0.002s
02 git clone /builds/web/
/tmp/_edd1c32f_edd1c32f/repo
02 Cloning into '/tmp/
_edd1c32f_edd1c32f/repo'...
02 done.
02 Note: checking out '5edd47195a0364803466c2ac1a4533d9a5e031e6'.
02
02 You are in 'detached HEAD' state. You can look around, make experimental
02 changes and commit them, and you can discard any commits you make in this
02 state without impacting any branches by performing another checkout.
02
02 If you want to create a new branch to retain commits you create, you may
02 do so (now or later) by using -b with the checkout command again. Example:
02
02 git checkout -b new_branch_name
02
✔ 02 localhost 0.061s
** Execute git_copy:update
00:00 git_copy:update
01 git remote update
01 Fetching origin
✔ 01 localhost 0.020s
cap aborted!
SSHKit::Command::Failed: git exit status: 32768
git stdout: develop
git stderr: fatal: ambiguous argument 'develop': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git [...] -- [...]'
/usr/local/bundle/gems/sshkit-1.14.0/lib/sshkit/command.rb:99:in `exit_status='

It's crashing in this line of scm.rb:

/usr/local/bundle/gems/capistrano-git-copy-1.4.0/lib/capistrano/git_copy/scm.rb:171:in commit_hash
/usr/local/bundle/gems/capistrano-git-copy-1.4.0/lib/capistrano/git_copy/scm.rb:68:in update

I think this may have to do with the repo not having remotes, may that be the issue? Is it possible to skip the git update? Thank you.

@ydkn
Copy link
Owner

ydkn commented Dec 2, 2017

Hello @ljesus,

can you please provide your git version and your SCM settings from the the capistrano configuration?
I'm guessing there is something wrong with the branch you configured to use and the available branches in your repository.

git --version

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants