You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by GitBox <gi...@apache.org> on 2022/12/29 17:57:16 UTC

[GitHub] [solr] justinrsweeney commented on a diff in pull request #1177: SOLR-16544: Adding documentation for how to contribute to Solr

justinrsweeney commented on code in PR #1177:
URL: https://github.com/apache/solr/pull/1177#discussion_r1059084031


##########
dev-docs/solr-source-code.adoc:
##########
@@ -0,0 +1,74 @@
+# Working With Solr Source Code
+
+## Building Solr from Source
+
+Download the Java 11 JDK (Java Development Kit) or later.  We recommend the OpenJDK
+distribution Eclipse Temurin available from https://adoptium.net/.
+You will need the JDK installed, and the $JAVA_HOME/bin (Windows: %JAVA_HOME%\bin)
+folder included on your command path. To test this, issue a "java -version" command
+from your shell (command prompt) and verify that the Java version is 11 or later. See the xref:jvms.adoc[JVM developer doc] for more information on Gradle and JVMs.
+
+Clone the latest Apache Solr source code directly from the Git repository: <https://solr.apache.org/community.html#version-control>.
+Alternatively, you can download the Apache Solr distribution, from https://solr.apache.org/downloads.html and unzip the distribution to a folder of your choice, e.g. C:\solr or ~/solr.
+
+Solr uses https://gradle.org/[Gradle] as the build
+system.  Navigate to the root of your source tree folder and issue the `./gradlew tasks`
+command to see the available options for building, testing, and packaging Solr.
+
+`./gradlew dev` will create a Solr executable suitable for development.
+cd to `./solr/packaging/build/dev` and run the `bin/solr` script
+to start Solr.
+
+NOTE: `gradlew` is the "Gradle Wrapper" and will automatically download and
+start using the correct version of Gradle for Solr.
+
+NOTE: `./gradlew help` will print a list of high-level tasks. There are also a
+number of plain-text files in <source folder root>/help.
+
+The first time you run Gradle, 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.
+
+Note as well that the gradle build does not create or copy binaries throughout the
+source repository so you need to switch to the packaging output folder `./solr/packaging/build`;
+the rest of the instructions below remain identical. The packaging directory
+is rewritten on each build.
+
+If you want to build the documentation, type `./gradlew -p solr documentation`.
+
+`./gradlew check` will assemble Solr and run all validation tasks unit tests.
+
+To build the final Solr artifacts run `./gradlew assemble`.
+
+Lastly, there is developer oriented documentation in `./dev-docs/README.adoc` that
+you may find useful in working with Solr.
+
+## Running Solr in Docker

Review Comment:
   Agreed, there is also a bunch of Docker information in the Solr Ref Guide, so I just split that out into its own dev doc and added a link out to the Ref Guide. Can provide a place to continue to add Docker specific development info.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org