# Crash when copying files to build.gradle directory

**URL:** <https://discuss.gradle.org/t/crash-when-copying-files-to-build-gradle-directory/1715>\
**Category:** Old Forum Archive\
**Created:** [September 17, 2013, 10:24am UTC](https://discuss.gradle.org/t/crash-when-copying-files-to-build-gradle-directory/1715 "2013-09-17T10:24:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sytse\_Reitsma](https://avatars.discourse-cdn.com/v4/letter/s/9de053/32.png) [@Sytse\_Reitsma](https://discuss.gradle.org/u/Sytse_Reitsma)\
**Post date:** [September 17, 2013, 10:24am UTC](https://discuss.gradle.org/t/crash-when-copying-files-to-build-gradle-directory/1715/1 "2013-09-17T10:24:00Z")

</div>

I’ve reproduced this with gradle 1.7 and 1.8-rc-1 on two separate 64 bit Windows 7 machines and a 32 bit Windows XP virtual machine. See [https://gist.github.com/sytsereitsma/6592444](https://gist.github.com/sytsereitsma/6592444) for the crash dump.

Use the following project structure: + Blah (directory)

SomeFile.txt build.gradle

The following code is in build.gradle:

```gradle
task CrashBoom (type : Copy) {
    from 'Blah'
    into '.'
}

```

Regards,

Sytse

---

<div class="post-metadata">

**Author:** ![Sytse\_Reitsma](https://avatars.discourse-cdn.com/v4/letter/s/9de053/32.png) [@Sytse\_Reitsma](https://discuss.gradle.org/u/Sytse_Reitsma)\
**Post date:** [September 17, 2013, 10:27am UTC](https://discuss.gradle.org/t/crash-when-copying-files-to-build-gradle-directory/1715/2 "2013-09-17T10:27:00Z")

</div>

SomeFile.txt should be in the blah directory, the indent was lost. I get the same crash when specifying the underlying directory (’…’ instead of ‘.’). It does not matter whether I specify the full path or the relative path.

---

<div class="post-metadata">

**Author:** ![Peter\_Niederwieser](https://avatars.discourse-cdn.com/v4/letter/p/9f8e36/32.png) [@Peter\_Niederwieser](https://discuss.gradle.org/u/Peter_Niederwieser)\
**Post date:** [September 19, 2013, 4:48am UTC](https://discuss.gradle.org/t/crash-when-copying-files-to-build-gradle-directory/1715/3 "2013-09-19T04:48:00Z")

</div>

Copying to the project dir is known to cause problems. Why do you want to do this? Usually, everything goes into the ‘build’ dir, or outside the project dir. Anyway, I’ve raised GRADLE-2891 to track this.

---

<div class="post-metadata">

**Author:** ![Sytse\_Reitsma](https://avatars.discourse-cdn.com/v4/letter/s/9de053/32.png) [@Sytse\_Reitsma](https://discuss.gradle.org/u/Sytse_Reitsma)\
**Post date:** [September 20, 2013, 11:31am UTC](https://discuss.gradle.org/t/crash-when-copying-files-to-build-gradle-directory/1715/4 "2013-09-20T11:31:00Z")

</div>

I added a gradle build script to an existing python project (in which all files were in the same directory). One of the builds steps copies some external build’s dependencies into the project directory.
