redhat-developer / redhat-developer/vscode-java

Build path error

Ouverte
#3,866 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Personne n'a encore pris cette issue.

Langage dominant
TypeScript
Étoiles
2.3k
Forks
546
Merge moyen
20 h 1 min
PR mergées (30 j)
11

Description

Hi, I have a problem about build directory.

cd /home/ray/dev/JavaProject ; /usr/bin/env /usr/lib/jvm/java-11-openjdk-amd64/bin/java -cp /home/ray/.vscode-server/data/User/workspaceStorage/154ea3c966ddc0a55d55766b94e4cd89/redhat.java/jdt_ws/jdt.ls-java-project/bin App

This command run when I open the java project in workspace and click Run.

usr/bin/env /usr/lib/jvm/java-11-openjdk-amd64/bin/java -cp /home/ray/dev/JavaProject/originaldemo/bin App

This command run when I open the project individually rather than in a workspace and click Run.

Image
The directory structure when opened from the workspace, springdemo is another java project

Image
Directory structure when opened separately

I can use "java.project.outputPath" option to set build directory in file JavaProject.code-workspace and it works. However, I want to set the build directory of each project in the workspace to the root directory of the project instead of the only directory of the workspace and I set this option in file settings.json under folder .vscode in this project, but this setting doesn't seem to work.

So, I want to build and run the java project using the build directory I set up for each project in my workspace instead of using the default directory under .vscode-server or the only directory of the workspace. How should I set it up to serve my purpose or is this a bug?

Guide de contribution

Ouvrir le guide de contribution

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Piste de recherche

Commencez par le fichier d’espace de travail JavaProject.code-workspace et le fichier .vscode/settings.json de chaque projet, en comparant la manière dont java.project.outputPath est appliqué lorsque les projets sont ouverts ensemble ou séparément. Reproduisez l’action Run avec la disposition de projet indiquée ; c’est terminé lorsque chaque projet de l’espace de travail utilise son propre répertoire de sortie configuré au lieu du chemin .vscode-server partagé.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
java, vscode
Domaine
build-system, developer-experience
Type d'issue
Bug
Difficulté
3/5
Temps estimé
1-2 jours
Activité
À l'abandon
Clarté
À clarifier
Accessibilité débutants
35/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.