ProjectLayoutIntegrationTest.groovy

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Moved some direct usages of `ImmutableFileCollection` to use `FileCollectionFactory` instead, so that there are fewer places that know how to create various `FileCollection` implementations.

  1. … 25 more files in changeset.
Moved some direct usages of `ImmutableFileCollection` to use `FileCollectionFactory` instead, so that there are fewer places that know how to create various `FileCollection` implementations.

  1. … 25 more files in changeset.
Deprecate `ProjectLayout.configurableFiles()` as it is replaced by `ObjectFactory.fileCollection()`. Also replace usages of internal `FileOperations.configurableFiles()` method with the public API.

    • -30
    • +41
    ./ProjectLayoutIntegrationTest.groovy
  1. … 27 more files in changeset.
Deprecate `ProjectLayout.configurableFiles()` as it is replaced by `ObjectFactory.fileCollection()`. Also replace usages of internal `FileOperations.configurableFiles()` method with the public API.

    • -30
    • +41
    ./ProjectLayoutIntegrationTest.groovy
  1. … 27 more files in changeset.
Dogfood ImmutableFileCollection on production code (#4988)

This reverts commit 13eaebc2b1244511dcbff4c59cd41253e3b69642.

  1. … 88 more files in changeset.
Revert "Dogfood ImmutableFileCollection on production code (#4988)"

This reverts commit 834632674ca29b6fd190857947338b2b54a9bb62.

The commit caused a bug in incremental compilation, causing changes

to go undetected.

  1. … 88 more files in changeset.
Dogfood ImmutableFileCollection on production code (#4988)

Use ImmutableFileCollection in production code

  1. … 88 more files in changeset.
Rename immutable file collection methods

* `ProjectLayout.filesFor()` -> `files()` (we already have `file()` and we are replacing `Project.files()`, moreover the `For` suffix doesn't seem to add anything)

* `ProjectLayout.mutableFilesFor()` -> `configurableFiles()` (the result is of type `ConfigurableFileCollection`, and we regularly use "configure" as a term in our public APIs, while we don't use "mutate")

    • -41
    • +41
    ./ProjectLayoutIntegrationTest.groovy
  1. … 4 more files in changeset.
Add ImmutableFileCollection (#4913)

Add `ProjectLayout.filesFor()` to obtain (immutable) `FileCollection`.

Add `ProjectLayout.mutableFilesFor()` to obtain (mutable) `ConfigurableFileCollection`.

    • -0
    • +178
    ./ProjectLayoutIntegrationTest.groovy
  1. … 7 more files in changeset.
Changed `Directory` and `RegularFile` so that they do not extend `Provider<File>` as these types represent some immutable location, rather than some calculated value.

Also added `FileSystemLocation` as a common supertype for these types to allow a consumer to declare that they accept a directory or a file or any file system element.

  1. … 14 more files in changeset.
Fixed `Project.file()` and `Project.files()` to properly handle `Directory` and `RegularFile`. Also fixed `Project.files()` when presented a `Path` instance. Added some test coverage and updated the Javadocs on `Project`.

    • -0
    • +47
    ./ProjectLayoutIntegrationTest.groovy
  1. … 6 more files in changeset.
Changed `Directory` so it represents a directory at a fixed location, rather than a directory whose location may or may not be known. Also added `RegularFile` to represent a file at a fixed location, added some `Provider` subtypes that represent some configurable directory or file variable and that provide conveniences for setting their value and deriving other locations relative to their value.

Changed the C++ plugins to use these types.

    • -29
    • +36
    ./ProjectLayoutIntegrationTest.groovy
  1. … 14 more files in changeset.
Added methods to `Directory` to resolve String and calculated paths to regular files and directories, relative to the directory.

    • -0
    • +39
    ./ProjectLayoutIntegrationTest.groovy
  1. … 12 more files in changeset.
Added `Directory` type to represent some calculated directory location, and `ProjectLayout` service to provide access to the project directory and build directory as `Directory` types.

    • -0
    • +75
    ./ProjectLayoutIntegrationTest.groovy
  1. … 7 more files in changeset.