sbt / sbt/sbt-eclipse

Project's flavour should automatically detected, instead of being hardcoded in the settings

Open
#277 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Scala
Stars
712
Forks
163
PR merge metrics
No merged PRs in 30d

Description

Currently, the default sbteclipse flavour for a project is ScalaIDE (see here), and I don't see why that should be the case.

Ideally, the project's flavour should be automatically detected based on the fact that the scala-library JAR is in the classpath. This is useful if you are trying to import a pure Java project, with no dependency on the Scala library. This doesn't currently work because the generated .project include the Scala builder and Scala nature (this is because ScalaIDE flavour is selected), but since there is no Scala library in the .classpath, you will get an error once the project is opened in Eclipse.

The actual reason why I would like to have it working this way is because I want sbteclipse to generate the Eclipse files for importing the playframework codebase.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in src/main/scala/com/typesafe/sbteclipse/core/EclipsePlugin.scala at the default flavour setting referenced in the issue, then inspect how the generated .project and .classpath are assembled. Determine how the scala-library JAR is represented in the classpath and verify that a pure Java project no longer receives the Scala builder or Scala nature, while Scala projects retain them.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala
Domain
build-system, tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.