<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>12462</bug_id>
          
          <creation_ts>2018-01-02 20:42:19 +0000</creation_ts>
          <short_desc>Git configuration can break poky scripts</short_desc>
          <delta_ts>2018-02-22 15:23:53 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>OE-Core</product>
          <component>Scripts and Tools</component>
          <version>2.5</version>
          <rep_platform>All</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>NOTABUG</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.5 M3</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>kratsg</reporter>
          <assigned_to name="Richard Purdie">richard.purdie</assigned_to>
          <cc>ross.burton</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>Yes (doc changes required)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>78869</commentid>
    <comment_count>0</comment_count>
    <who name="">kratsg</who>
    <bug_when>2018-01-02 20:42:19 +0000</bug_when>
    <thetext>When cloning poky with the git config set &quot;core.autocrlf=true&quot;, sourcing the scaffolding script breaks:

$ source oe-init-build-env
: command not found
: command not found
-bash: oe-init-build-env: line 30: syntax error near unexpected token `elif&apos;
&apos;bash: oe-init-build-env: line 30: `elif [ -n &quot;$ZSH_NAME&quot; ]; then

To reproduce:

git config core.autocrlf true
git clone -b pyro git://git.yoctoproject.org/poky
cd poky
source oe-init-build-env</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>78872</commentid>
    <comment_count>1</comment_count>
    <who name="Michael Halstead">mhalstead</who>
    <bug_when>2018-01-02 22:39:12 +0000</bug_when>
    <thetext>We can&apos;t control this on the infrastructure side as far as I know. The end user can control this setting or the repository owner can add a .gitattributes file and set &quot;text eol=lf&quot;. I&apos;m moving this to where the repository owners will see it.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>78896</commentid>
    <comment_count>2</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2018-01-04 15:44:21 +0000</bug_when>
    <thetext>Context: core.autocrlf=true tells git to force every text file to use Windows line endings, but on Linux shell scripts needs Linux line endings.

Why do you have autocrlf=true set?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>79092</commentid>
    <comment_count>3</comment_count>
    <who name="">kratsg</who>
    <bug_when>2018-01-16 14:05:37 +0000</bug_when>
    <thetext>Hi, sorry for late response. This was needed between we&apos;re running Vivado/SDK on Windows machines and yocto/bitbake on Linux machines -- and having to run version control on both.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>79554</commentid>
    <comment_count>4</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2018-02-22 15:23:53 +0000</bug_when>
    <thetext>You can&apos;t clone linux based shell scripts with that setting and expect them to work and this isn&apos;t something we can fix, sorry.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>