EasyMaven
Maven made easy for VS Code. It shows up as an EasyMaven section inside the Explorer (next to Maven, Servers or Java Projects). With the easyMaven.location setting, or the ⋯ menu › Change view location, you can move it to its own icon in the activity bar.
The interface (panel, messages, commands and the settings descriptions) is in English by default and is translated automatically when VS Code uses Spanish, Portuguese (Brazil), French, German or Italian. What is stored in settings.json (keys and properties) is always in English; the default options are stored in English and shown translated.
Panel
The header has ▶ Run (it turns into ■ to stop while running), Repeat last command, ☆ Save current command as favorite, refresh, settings and collapse/expand all. Sections can be reordered with the ↑↓ arrows shown when hovering their title, and shown or hidden by right-clicking the panel: a menu lists every section with a ✓ on the visible ones (also from the ⋯ menu › Show/hide sections, or easyMaven.hiddenSections).
- Projects: checkboxes with the
pom.xml names. Projects with modules collapse with ▸ (collapsed by default; 2/3 shows checked modules inside). When several are checked they run one after another and, if one fails, the rest is skipped (easyMaven.stopOnFailure).
- Favorites: they store the goals, options, profiles and properties. ▶ runs them as saved (without the options currently checked) on the checked projects and with the current Advanced settings (Maven, JDK,
-T, -s). They can be reordered, edited (✎) or deleted.
- Phases: lifecycle phases (
compile, test, package, install, deploy…) are single-choice, because each one already includes the previous ones; clean can be combined with any of them and always goes first.
- Options: toggle buttons; hovering shows the real argument and a ✕ to remove it. The + in the title (shown while the section is open) adds a new one (it asks for the argument and then the name; leave the name empty to use the argument). They are all stored in
easyMaven.options in settings.json: on install it is filled with the usual ones (skip tests, skip test compilation, force updates, debug output, error stack traces, skip Javadoc) and every one can be removed or changed like the ones you add.
- Profiles (-P): buttons with the profiles of the checked projects and the ones added manually.
- Properties (-D).
- Advanced: the generated command (editable: when you press Enter or leave the box, matching options, profiles and properties get checked), the Maven installation, the JDK, threads (
-T) and settings.xml.
Everything is stored in the user settings.json under easyMaven.*, for example:
"easyMaven.options": [
{ "label": "Skip tests", "argument": "-DskipTests", "description": "Compiles the tests but does not run them", "enabled": true }
],
"easyMaven.favorites": [
{ "label": "Quick install", "command": "clean install -DskipTests" }
]
Settings from previous versions (with Spanish keys such as listaOpciones or favoritos) are moved automatically on startup.
Where it runs
In a regular terminal named EasyMaven, using Windows PowerShell (easyMaven.terminal lets you pick pwsh or the default terminal). Stop closes that terminal.
Which Maven and Java are used
Maven, in this order:
- The installation set in Advanced (
easyMaven.mavenHome, e.g. C:\apache-maven-3.9.10) or a full path in easyMaven.executable.
- The project's Maven Wrapper (
mvnw/mvnw.cmd).
MAVEN_HOME of the system.
mvn from PATH.
Java: the JDK set in Advanced (easyMaven.javaHome), otherwise the system JAVA_HOME, otherwise java from PATH.
They can be set in the panel (Advanced) or in the VS Code Settings screen (⚙ in the panel header), where Maven Home, Java Home and Settings Xml are shown first, each with a Browse… link that opens the file explorer, the same as the … buttons in Advanced. Under each field the panel shows which one will be used, and warns in red if the configured folder is wrong or nothing is found. When mavenHome or javaHome are set, MAVEN_HOME, JAVA_HOME and the terminal PATH are adjusted too, so the computer does not need those environment variables.
Development
npm install
npm run compile # type-check and build dist/extension.js
npm test # logic tests
npm run package # build the .vsix
python3 l10n/traducciones.py # regenerate the translation files