Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
Ohmyzsh
Commits
424b2476
Unverified
Commit
424b2476
authored
Feb 17, 2019
by
Marc Cornellà
Committed by
GitHub
Feb 17, 2019
Browse files
Merge pull request #7599 from mcornella/plugin/mvn-refactor
mvn: unify changes, refactor and cleanup
parents
c5272bdd
0e647904
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
plugins/mvn/README.md
View file @
424b2476
#
#
Introductio
n
#
mvn plugi
n
The
[
mvn plugin
](
https://github.com/robbyrussell/oh-my-zsh/tree/master/plugins/mvn
)
provides many
The mvn plugin
provides many
[
useful aliases
](
#aliases
)
as well as completion for
[
useful aliases
](
#aliases
)
as well as completion for the
`mvn`
command
.
the
[
Apache Maven
](
https://maven.apache.org/
)
command (
`mvn`
)
.
Enable it by adding
`mvn`
to the plugins array in your zshrc file:
Enable it by adding
`mvn`
to the plugins array in your zshrc file:
```
zsh
```
zsh
...
@@ -10,25 +10,49 @@ plugins=(... mvn)
...
@@ -10,25 +10,49 @@ plugins=(... mvn)
## Aliases
## Aliases
The plugin aliases mvn to a function that calls
`mvnw`
(the
[
Maven Wrapper
](
https://github.com/takari/maven-wrapper
)
)
if it's found, or the mvn command otherwise.
| Alias | Command |
| Alias | Command |
|:---------------------|:------------------------------------------------|
|:---------------------|:------------------------------------------------|
|
`mvncie`
|
`mvn clean install eclipse:eclipse`
|
|
`mvn!`
|
`mvn -f <root>/pom.xml`
|
|
`mvnag`
|
`mvn archetype:generate`
|
|
`mvnboot`
|
`mvn spring-boot:run`
|
|
`mvnc`
|
`mvn clean`
|
|
`mvncd`
|
`mvn clean deploy`
|
|
`mvnce`
|
`mvn clean eclipse:clean eclipse:eclipse`
|
|
`mvnci`
|
`mvn clean install`
|
|
`mvnci`
|
`mvn clean install`
|
|
`mvncie`
|
`mvn clean install eclipse:eclipse`
|
|
`mvncini`
|
`mvn clean initialize`
|
|
`mvncist`
|
`mvn clean install -DskipTests`
|
|
`mvncist`
|
`mvn clean install -DskipTests`
|
|
`mvncisto`
|
`mvn clean install -DskipTests --offline`
|
|
`mvncisto`
|
`mvn clean install -DskipTests --offline`
|
|
`mvne`
|
`mvn eclipse:eclipse`
|
|
`mvncv`
|
`mvn clean verify`
|
|
`mvnd`
|
`mvn deploy`
|
|
`mvnp`
|
`mvn package`
|
|
`mvnc`
|
`mvn clean`
|
|
`mvncom`
|
`mvn compile`
|
|
`mvncom`
|
`mvn compile`
|
|
`mvncp`
|
`mvn clean package`
|
|
`mvnct`
|
`mvn clean test`
|
|
`mvnct`
|
`mvn clean test`
|
|
`mvnt`
|
`mvn test`
|
|
`mvncv`
|
`mvn clean verify`
|
|
`mvnag`
|
`mvn archetype:generate`
|
|
`mvncvst`
|
`mvn clean verify -DskipTests`
|
|
`mvn-updates`
|
`mvn versions:display-dependency-updates`
|
|
`mvnd`
|
`mvn deploy`
|
|
`mvntc7`
|
`mvn tomcat7:run`
|
|
`mvndocs`
|
`mvn dependency:resolve -Dclassifier=javadoc`
|
|
`mvnjetty`
|
`mvn jetty:run`
|
|
`mvndt`
|
`mvn dependency:tree`
|
|
`mvndt`
|
`mvn dependency:tree`
|
|
`mvne`
|
`mvn eclipse:eclipse`
|
|
`mvnjetty`
|
`mvn jetty:run`
|
|
`mvnp`
|
`mvn package`
|
|
`mvns`
|
`mvn site`
|
|
`mvns`
|
`mvn site`
|
|
`mvnsrc`
|
`mvn dependency:sources`
|
|
`mvnsrc`
|
`mvn dependency:sources`
|
|
`mvndocs`
|
`mvn dependency:resolve -Dclassifier=javadoc`
|
|
`mvnt`
|
`mvn test`
|
|
`mvntc`
|
`mvn tomcat:run`
|
|
`mvntc7`
|
`mvn tomcat7:run`
|
|
`mvn-updates`
|
`mvn versions:display-dependency-updates`
|
## mvn-color
It's a function that wraps the mvn command to colorize it's output. You can use it in place
of the
`mvn`
command. For example: instead of
`mvn test`
, use
`mvn-color test`
.
Since
[
Maven 3.5.0
](
https://maven.apache.org/docs/3.5.0/release-notes.html
)
the mvn command
has colored output, so this function will be soon removed from the plugin.
### Known bugs
It has a bug where it will swallow mvn prompts for user input, _e.g._ when using
`archetype:generate`
. See
[
#5052
](
https://github.com/robbyrussell/oh-my-zsh/issues/5052
)
.
plugins/mvn/mvn.plugin.zsh
View file @
424b2476
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment