I've only recently started using Bamboo along with Bitbucket, we have a scenario (however wrong it might be) that files need to be downloaded and run by the Bamboo agent on a Linux machine, but with CRLF endings.
I can't seem to get this to happen.
I've managed to change all the line endings in the files, and also create a .gitattributes file trying various options, but the files in question always end up downloading with a the linefeed (/n) only.
Is there a setting that can be placed within the bamboo agent to say how it should handle the files? Does the gitattributes file only suggest how the file should be edited when changed, so it won't help when cloning the repo for tests?
Any ideas would be welcomed.
If you are creating these files on Windows, check that you don't have core.autocrlf set to true. This setting changes text files from Windows to Linux line-endings during push and changes them back during pull.
Thank you, though I have checked that. I realised the core.autocrlf entry wasn't actually set, so I set it to false just in case.
I then realised that the original upload of files may have previously been converted to whatever the default setting is. So as an experiment, I recreated the repository (this is in the setup stage, so no one else is working on this data yet). I created a .gitattributes file with
* text eol=crlf
in it, and made sure everything was uploaded like this.
I cleared everything where the agent runs, so it's git repository was cloned afresh, but the same occurred, the files are still downloading with /n only.
I can't help but think I am missing something obvious here.
Thanks for this, you may be right. I don't believe we are using native git, so could the built-in version not fully support this? I can't get Git onto that machine for the moment, but I will see what I can do and if it makes a difference. This at least makes more sense. Thanks.
I know it has been a long time, but I finally got Git onto the machine. I have no idea how to check if it is working though.
I added a line to the bamboo-capabilities.properties file...
I have no idea if that is correct. I see what seems like hundreds of pages saying that you need native git, but none to say what that actually entails.
Also, this is a remote agent, I have no access to setting capabilities on the Bamboo server.
Anyway, if you haven't guessed, this hasn't changed what is happening. Any more ideas?
Just to reiterate what we are doing - I upload files from a Windows machine, they are then downloaded onto the Agent which is Linux
Thanks for signing up for Jira Ops! I’m Matt Ryall, leader for the Jira Ops product team at Atlassian. Since this is a brand new product, we’ll be delivering improvements quickly and sharing updates...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs