0% found this document useful (0 votes)
34 views10 pages

Maven Introduction

Maven is an open-source build and project management tool developed by Apache, primarily used for Java-based projects. It automates tasks such as compiling, packaging, and deployment while managing project dependencies and providing a standard project structure. Key features include a Project Object Model (POM) for configuration, a build lifecycle, and support for various repository types and plugins.

Uploaded by

Sophia
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views10 pages

Maven Introduction

Maven is an open-source build and project management tool developed by Apache, primarily used for Java-based projects. It automates tasks such as compiling, packaging, and deployment while managing project dependencies and providing a standard project structure. Key features include a Project Object Model (POM) for configuration, a build lifecycle, and support for various repository types and plugins.

Uploaded by

Sophia
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 10

Introduction to

Maven
A Build and Project Management Tool
What is Maven?

 - Open-source build tool developed by Apache


 - Written in Java, supports Java, C#, Scala, Ruby
 - Used to build and manage Java-based projects
 - Automates tasks like compiling, packaging, and
deployment
Why Use Maven?

 - Handles project dependencies automatically


 - Provides a standard project structure
 - Simplifies the build process
 - Integrates with CI/CD tools like Jenkins
 - Supports version control tools like Git
Maven Build Tool Features

 - Generates source code & documentation


 - Compiles source code into JAR files
 - Manages dependencies efficiently
 - Provides project information and reports
 - Enhances software development performance
Maven Repository Types

 - Local Repository: Stored on developer’s machine


 - Central Repository: Hosted by Maven community
 - Remote Repository: Custom repository for
internal use
Maven POM (Project
Object Model)
 - XML file containing project details &
dependencies
 - Defines project structure, plugins, and build
settings
 - Located in the project home directory
Maven Build Lifecycle

 - Clean Lifecycle: Cleans project before build


 - Default Lifecycle: Compiles, tests, packages,
installs
 - Site Lifecycle: Generates documentation &
reports
Managing Dependencies
in Maven
 - Automatic dependency management
 - Resolves transitive dependencies
 - Scopes: Compile, Provided, Runtime, Test,
System, Import
Maven Plugins

 - Build Plugins: Used during build (e.g., Compiler,


Install)
 - Reporting Plugins: Used for site generation
 - Examples: Clean, Compiler, Deploy, Site, Surefire
Installing & Setting Up
Maven
 - Download Maven binary zip
 - Extract and set environment variables
(M2_HOME, MAVEN_HOME)
 - Update system PATH variable
 - Verify setup using 'mvn -version'

You might also like