-
Notifications
You must be signed in to change notification settings - Fork 82
Support exporting jar #271
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Update function with no params and add plugin.xml
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Support export jar feature.
...xt/com.microsoft.jdtls.ext.core/src/org/eclipse/jdt/internal/jarpackager/JarPackageUtil.java
Show resolved
Hide resolved
...xt/com.microsoft.jdtls.ext.core/src/org/eclipse/jdt/internal/jarpackager/JarPackageUtil.java
Outdated
Show resolved
Hide resolved
...xt/com.microsoft.jdtls.ext.core/src/org/eclipse/jdt/internal/jarpackager/JarPackageUtil.java
Outdated
Show resolved
Hide resolved
...xt/com.microsoft.jdtls.ext.core/src/org/eclipse/jdt/internal/jarpackager/JarPackageUtil.java
Outdated
Show resolved
Hide resolved
...xt/com.microsoft.jdtls.ext.core/src/org/eclipse/jdt/internal/jarpackager/JarPackageUtil.java
Outdated
Show resolved
Hide resolved
jdtls.ext/com.microsoft.jdtls.ext.core/src/com/microsoft/jdtls/ext/core/ProjectCommand.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As @testforstephen has mentioned, there are several unnecessary files/code in this PR. Please remove them first. Also, remember add license header when you adding a new file.
Hi, this seams great. |
We will put an |
src/exportJarFileCommand.ts
Outdated
case ExportSteps.ResolveProject: { | ||
projectFolder = await resolveProject(pickSteps, node); | ||
projectUri = Uri.parse(projectFolder); | ||
rootNodes = await Jdtls.getProjects(projectUri.toString()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is rootNode here meaning a project node?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not exactly. For maven project as an example, rootNodes
is an Array which includes all the modules defined in pom.xml
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
submodules are still projects. rootNode
is misleading here, what is root? is it workspace root? And what is node? we don't have tree structure here
java.view.package.exportJar -> java.view.package.generateJar
}, (progress, token) => { | ||
return new Promise<IJarQuickPickItem[]>(async (resolve, reject) => { | ||
token.onCancellationRequested(() => { | ||
return reject(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return resolve([])
src/exportJarFileCommand.ts
Outdated
try { | ||
step = await stepMap.get(step).execute(stepMetadata); | ||
} catch (err) { | ||
if (err === undefined) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return err ? reject(${err}
) : reject()
} | ||
const disposables: Disposable[] = []; | ||
let pickBox: QuickPick<IJarQuickPickItem>; | ||
const result = await new Promise<boolean>(async (resolve, reject) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
try {
} finally {}
1.Fix disposables bugs 2.move stepMap to grobal
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Add 'getMainMethod' command in jdtls.ext, which will return all the existing main methods of the workspace.