redhat-developer / redhat-developer/vscode-java

Code running in WSL:Ubuntu will not load the codestyle.xml located in the Windows filesystem

Aperta
#1,783 7 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

documentation enhancement
Lingua principale
TypeScript
Stelle
2.3k
Fork
546
Merge medio
20h 1m
PR unite (30g)
11

Descrizione

I found that vscode cannot load an eclipse profile if vscode is using WSL as the terminal and the codestyle file is in the Windows filesystem. This I found is true regardless of the url syntax for local files, i.e., D:\path\to\file or /d/path/to/file. I had to copy the file into my WSL filesystem and reference is relative to the WSL root, i.e., /home/path/to/file.

Environment
  • Operating System: Windows_NT x64 10.0.19042 + WSLv2 + Ubuntu 20.10
  • JDK version: OpenJDK Runtime Environment (build 11.0.9.1+1-Ubuntu-0ubuntu1.20.10)
  • Visual Studio Code version: 1.52.1, Electron 9.3.5
  • Java extension version:
Steps To Reproduce
  1. configure Java › Format › Settings: Url to be drive_letter:\path\to\eclipse_codestyle.xml
  2. confirm the settings aren't used when formatting file
  3. configure Java › Format › Settings: Url to be file:///wsl_drive_mnt/path/to/eclipse_codestyle.xml
  4. confirm the settings aren't used when formatting file
  5. configure Java › Format › Settings: Url to be file:///path/to/eclipse_codestyle.xml
  6. confirm file is used when formatting file

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Direzione di ricerca

Inizia tracciando come viene risolto il valore Java › Format › Settings: Url quando VS Code usa WSL, riproducendo il problema con le forme dei percorsi Windows e WSL elencate nei passaggi. Il lavoro è completato quando un Eclipse codestyle.xml nel file system Windows viene caricato e applicato durante la formattazione in WSL.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
java, typescript, ubuntu, vscode
Ambito
operating-systems, tooling
Tipo di issue
Bug
Difficoltà
3/5
Tempo stimato
1-2 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
42/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.