Skip to content

Commit

Permalink
Fixed scala dev doc (feathr-ai#599)
Browse files Browse the repository at this point in the history
Fixed scala dev doc

Match latest IntelliJ UI for Windows and Mac (Feedback from blair)
Fixed sbt commands for compiling
  • Loading branch information
ahlag committed Aug 26, 2022
1 parent 0bf2af4 commit 3a33d6f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
3 changes: 2 additions & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,8 @@ lazy val root = (project in file("."))
// )
// )

// To assembly with certain java version: sbt assembly -java-home "/Library/Java/JavaVirtualMachines/jdk1.8.0_282-msft.jdk/Contents/Home"
// To assembly with certain java version: sbt assembly -java-home "/Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home"
// Please specify the feathr version feathr-assembly-X.X.X-SNAPSHOT.jar
// To execute the jar: java -jar target/scala-2.12/feathr-assembly-0.5.0-SNAPSHOT.jar

assembly / assemblyMergeStrategy := {
Expand Down
15 changes: 11 additions & 4 deletions docs/dev_guide/scala_dev_guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ parent: Developer Guides

## IntelliJ Setup

IntelliJ is the recommended IDE to use when developing Feathr. Please visit IntelliJ's
IntelliJ is the recommended IDE to use when developing Feathr. Please visit IntelliJ's
[installation guide](https://www.jetbrains.com/help/idea/installation-guide.html) to install it
in your local machine. To import Feathr as a new project:
1. Git clone Feathr into your local machine. i.e. via https `git clone https://github.com/linkedin/feathr.git` or ssh `git clone git@github.com:linkedin/feathr.git`
2. In IntelliJ, select `File` > `Project from Existing Sources...` and select `feathr` from the directory you cloned.
2. In IntelliJ, select `File` > `New` > `Project from Existing Sources...` and select `feathr` from the directory you cloned.
3. Under `Import project from external model` select `sbt`. Click `Next`.
4. Under `Project JDK` specify a valid Java `1.8` JDK and select SBT shell for `project reload` and `builds`.
5. Click `Finish`.
Expand All @@ -38,9 +38,16 @@ Feathr is compiled using [SBT](https://www.scala-sbt.org/1.x/docs/Command-Line-R

To compile, run
```
sbt compile
sbt assembly
```

To compile with certain java version, run
```
sbt assembly -java-home "/Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home"
```

The jar files are compiled and placed in `feathr/target/scala-2.12/feathr-assembly-X.X.X.jar `.

To execute tests, run
```
sbt test
Expand All @@ -51,4 +58,4 @@ To execute a single test suite, run
sbt 'testOnly com.linkedin.feathr.offline.AnchoredFeaturesIntegTest'
```

Refer to [SBT docs](https://www.scala-sbt.org/1.x/docs/Command-Line-Reference.html) for more commands.
Refer to [SBT docs](https://www.scala-sbt.org/1.x/docs/Command-Line-Reference.html) for more commands.

0 comments on commit 3a33d6f

Please sign in to comment.