GithubHelp home page GithubHelp logo

microsoft / vscode-java-dependency Goto Github PK

View Code? Open in Web Editor NEW
137.0 15.0 67.0 9.82 MB

Manage Java projects in Visual Studio Code.

Home Page: https://marketplace.visualstudio.com/items?itemName=vscjava.vscode-java-dependency

License: MIT License

Java 25.77% JavaScript 1.03% TypeScript 73.20%
java vscode-extension language-support project-management

vscode-java-dependency's Introduction

Project Manager for Java

Manage Java projects in Visual Studio Code

GitHub Actions GitHub Actions GitHub Actions

Overview

A lightweight extension to provide additional Java project explorer features. It works with Language Support for Java by Red Hat to provide the following features:

Project View

project-view

Create Java Projects

create project

Export Jar

Note: For Spring Boot projects, please use the build tool to build the executable jar, for example: mvn package.

export jar

Manage Dependencies

You can work with JAR files directly without any build tools. Go to JAVA PROJECTS view, find the Referenced Libraries node and click the + icon:

Reference JAR Files

If you want to fine-tune this, go to settings.json and look for the java.project.referencedLibraries entry.

"java.project.referencedLibraries": [
    "library/**/*.jar",
    "/home/username/lib/foo.jar"
]

You can tell that the glob pattern is supported. And here's more - you can include/exclude certain files, and attach source JARs:

"java.project.referencedLibraries": {
    "include": [
        "library/**/*.jar",
        "/home/username/lib/foo.jar"
    ],
    "exclude": [
        "library/sources/**"
    ],
    "sources": {
        "library/bar.jar": "library/sources/bar-src.jar"
    }
}

Requirements

Settings

Setting Name Description Default Value
java.dependency.showMembers Specify whether to show the members in the Java Projects explorer. false
java.dependency.syncWithFolderExplorer Specify whether to link Java Projects Explorer with the active editor. true
java.dependency.autoRefresh Specify whether to automatically sync the change from editor to the Java Projects explorer. true
java.dependency.refreshDelay The delay time (ms) the auto refresh is invoked when changes are detected. 2000ms
java.dependency.packagePresentation Specify how to display the package. Supported values are: flat, hierarchical. flat
java.project.exportJar.targetPath The output path of export jar. When this setting is empty , a file explorer will pop up to let the user select the output location. ${workspaceFolder}/${workspaceFolderBasename}.jar
java.project.explorer.showNonJavaResources When enabled, the explorer shows non-Java resources. true

Contribution

Build

  • Prerequirement

    • Node.js
    • Java SDK 11 or above
  • Go to root folder:

npm install
npm run build-server

Telemetry

VS Code collects usage data and sends it to Microsoft to help improve our products and services. Read our privacy statement to learn more. If you don't wish to send usage data to Microsoft, you can set the telemetry.enableTelemetry setting to false. Learn more in our FAQ.


This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

vscode-java-dependency's People

Contributors

0dind avatar andxu avatar cscherryy avatar dbalek avatar dependabot[bot] avatar eskibear avatar estherperelman avatar flanker32 avatar fvclaus avatar jdneo avatar jeremyfiel avatar jsoref avatar microsoft-github-policy-service[bot] avatar microsoftopensource avatar msftgits avatar mutsuntsai avatar testforstephen avatar vigilans avatar xqzlgy2 avatar yaohaizh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

vscode-java-dependency's Issues

0.2.0 Endgame

Summary

  1. the target date for this release will be 11/16
  2. Fix the following issues:
  • #79 Files in 'src/main/resources/' do not display enhancement
  • #83 The side bar keeps popping up when a new Java file opens
  • #80 No way to link a java class definition back to the project explorer?
  1. Left over issues:
  • #106 No way to link a resource files back to the project explorer
  • JDK class may not link back to the project explorer
  • No outline for .class in jar without source

Build

Test

  • 11/19 - Run test plan and verify bugs listed in 0.2.0 milestone(windows and mac) - @

Release

  • 11/19 - Add 0.2.0 tag - @andxu
  • 11/19 - Release to marketplace - @andxu

Notes

Before you check an item, please reply to this issue with the following details:

What are the steps and details of your check?
What are the configurations?
What are the issues found in the process?
What's your conclusion?

Change extension name to "Java Dependency Viewer"

Here's the scenario where "Java Dependencies" does not work.

image
When we recommend extensions, we use "Install xxx..."
And for this extension, it will be "Install Java Dependencies", which is super confusing.

And the name "Java Dependencies" itself is not accurate and does not state its actual use.

Please make the change before we proceed with microsoft/vscode-java-pack#60

A folder or workspace opens multiple Maven projects with an exception

A folder or workspace opens multiple Maven projects. (A be dependent on B):
1.A project mavenDependencies can not found B,[go to definition] is also directly to the source code of B,but maven package B and sourcecode are different.
2.This will cause debugging abnormaland,breakpoints may never hit.
The A project alone will not have such a problem.

[Public]0.1.0 Endgame

Summary

  1. the target date for this release will be 10/19
  2. the version will revert back to 0.1.0 (public)
  3. fix the compatible issue with newest vscode
  • The outline doesn't show any children under a .java/.class file(set true to the java.dependency.showOutline setting)

Build

Test

  • 10/19 - Run test plan and verify bugs listed in 0.1.0 milestone(windows and mac) - @bsaby

Release

  • 10/19 - Add 0.1.0 tag - @andxu
  • 10/19 - Release to marketplace - @andxu

Notes

Before you check an item, please reply to this issue with the following details:

What are the steps and details of your check?
What are the configurations?
What are the issues found in the process?
What's your conclusion?

Chinese Language Support

We have lots of Chinese developers. It would be great if we can provide a localized interface. This issue is to track the effort of building the localization story.
Supporting Chinese is a start. Once the solution is working, we can expand the support to other languages.

Test Plan

Test platform

Windows 10/Mac/Ubuntu 16.04 or 18.04

Features

Basic

  • Can create java project from navigation command bar following the instructions
  • Can not create java projects with conflicts name in same location
  • Can press F5 to run the java project
  • Can set breakpoints to debug the java project
  • Can view all dependencies of the opened java project

Simple project

  • Open the project under $repo/test/simple
  • Can create java project from navigation command bar following the instructions
  • Can show the package of the source code
  • Can open source file
  • Can show the external "JRE System Library"
  • Can show the jar under the libarary
  • Can show the package under the jar
  • Can show the classfile under the package and open the classfile
  • Can show the symbols in the explorers

Maven project

  • Open the project under $repo/test/maven
  • Can create java project from navigation command bar following the instructions
  • Can show the package of the source code
  • Can open source file
  • Can show the external "Maven dependencies"
  • Can show the jar under the libarary
  • Can show the package under the jar
  • Can show the classfile under the package and open the classfile
  • Can show the symbols in the explorers

Gradle project

  • Open the project under $repo/test/gradle
  • Can create java project from navigation command bar following the instructions
  • Can show the package of the source code
  • Can open source file
  • Can show the external "Project and External Dependencies"
  • Can show the jar under the libarary
  • Can show the package under the jar
  • Can show the classfile under the package and open the classfile
  • Can show the symbols in the explorers

Multiple project

  • Open the project under $repo/test/multiple
  • Should have correct behavior for both projects in the following scenarios:
  • Can create java project from navigation command bar following the instructions
  • Can show the package of the source code
  • Can open source file
  • Can show the external "JRE System Library"
  • Can show the jar under the libarary
  • Can show the package under the jar
  • Can show the classfile under the package and open the classfile
  • Can show the symbols in the explorers

"JAVA DEPENDENCIES" View should always show

Current Behavior

Currently, the view only shows up when the Java LS finishes loading the project.

Expected Behavior

  • The view needs to be statically showing in the file explorer view. Its visibility should be controlled by users.
  • When the view is loading and has nothing to show, show icon or text to indicate the loading status just like other views.

The side bar keeps popping up when a new Java file opens

  • Open a java file in a java project
  • close the side bar (cmd+b on mac)
  • navigate to a new file from the same project
  • side bar pops up
  • repeat ...

This is extremely irritating when trying to step debugging into another file, the debug view is replaced by the explorer. Also looks bad when performing a live demo with limited screen real estate.

Dependency view sync with opened files should only work when the side bar is visible.

0.3.0 Endgame

Pre-release

  • Fix critical issues
  • Update system icons
  • Add change log and update readme
  • Bump version

Test

  • Build test bits
  • Test the bits following the test plan

Publish

  • Add publish CI
  • Unpublish the private extension
  • Publish the extension under Microsoft

Open Source

  • Check internal open source status
  • Make the repo public

No JAVA PACKAGES explorer sidebar on symlink folders

I can't see the JAVA PACKAGES explorer sidebar showed in doc. I can see a JAVA DEPENDENCIES sidebar that is always empty (except for multi-project workspace where I can see folder with project names but empty inside those folders).
screenshot from 2018-10-24 15-28-27

The attached image is for a just created java project using command Java:Create Java Project.

OS: Linux 4.15.0-38-generic Ubuntu SMP Wed Oct 10 10:59:38 UTC 2018 x86_64 x86_64 x86_64
GNU/Linux

Extension Version
vscjava.vscode-java-dependency 0.1.0
redhat.java 0.33.0

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.