Skip to content

Commit

Permalink
Update contributing guide: autocrlf and build dependencies (#12963)
Browse files Browse the repository at this point in the history
  • Loading branch information
sabi0 authored Dec 22, 2023
1 parent f6b2006 commit 9359a9d
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,21 @@ First of all, you need the Lucene source code.

Get the source code using: `git clone https://github.com/apache/lucene`

### Notes for required Java version
Please note that it is important to preserve the files' original line breaks - some of them have their checksums verified during build.
If you are using Windows you might want to override the default Git configuration when cloning the repository:
`git clone --config core.autocrlf=false https://github.com/apache/lucene`

### Pre-requisites

Be sure that you are using an appropriate version of the JDK. Please check [README](./README.md) for the required JDK version for current main branch.

Some build tasks (in particular `./gradlew check`) require Perl and Python 3.

### Building with Gradle

Lucene uses [Gradle](https://gradle.org/) for build control. Gradle is itself Java-based and may be incompatible with newer Java versions; you can still build and test Lucene with these Java releases, see [jvms.txt](./help/jvms.txt) for more information.

NOTE: DO NOT use the `gradle` command that is perhaps installed on your machine. This may result in using a different gradle version than the project requires and this is known to lead to very cryptic errors. The "gradle wrapper" (gradlew script) does everything required to build the project from scratch: it downloads the correct version of gradle, sets up sane local configurations and is tested on multiple environments.
NOTE: DO NOT use the `gradle` command that is perhaps installed on your machine. This may result in using a different gradle version than the project requires and this is known to lead to very cryptic errors. The "gradle wrapper" (`gradlew` script) does everything required to build the project from scratch: it downloads the correct version of gradle, sets up sane local configurations and is tested on multiple environments.

The first time you run gradlew, it will create a file "gradle.properties" that contains machine-specific settings. Normally you can use this file as-is, but it can be modified if necessary.

Expand Down

0 comments on commit 9359a9d

Please sign in to comment.