티스토리 뷰

1. Help > Eclipse Marketplace... > spring 검색 > Install

Install 하기

 

 

2. New > Java Project 생성하기

 

 

3. 생성한 프로젝트 우클릭 > Configure > Convert to Maven Project 클릭 > Finish

 

 

4. mvnrepository.com 접속

a. spring-core 검색 > Spring Core > 5.2.4.RELEASE > Maven 영역 복사

https://mvnrepository.com/artifact/org.springframework/spring-core/5.2.4.RELEASE

Spring Core

 

b. spring-context 검색 > Spring Context > 5.2.4.RELEASE > Maven 영역 복사

https://mvnrepository.com/artifact/org.springframework/spring-context/5.2.4.RELEASE

Spring Context

 

 

5. pom.xml 에 <dependencies> 추가 > 4번에서 복사한 것들 붙여넣기

pom.xml

<project xmlns="http://maven.apache.org/POM/4.0.0"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

	<!-- Maven version -->
	<modelVersion>4.0.0</modelVersion>

	<!-- Project 정보 -->
	<groupId>Spring01_Hello</groupId>
	<artifactId>Spring01_Hello</artifactId>

	<!-- Project version -->
	<version>0.0.1-SNAPSHOT</version>

	<build>
		<sourceDirectory>src</sourceDirectory>
		<plugins>
			<plugin>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>3.8.0</version>
				<configuration>
					<source>1.8</source>
					<target>1.8</target>
				</configuration>
			</plugin>
		</plugins>
	</build>

	<dependencies>
		<!-- https://search.maven.org/ -->
		<!-- https://mvnrepository.com/ -->

		<!-- https://mvnrepository.com/artifact/org.springframework/spring-core -->
		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-core</artifactId>
			<version>5.2.4.RELEASE</version>
		</dependency>

		<!-- https://mvnrepository.com/artifact/org.springframework/spring-context -->
		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-context</artifactId>
			<version>5.2.4.RELEASE</version>
		</dependency>

	</dependencies>
</project>

 

 

끝!

최근에 올라온 글
«   2024/07   »
1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31
Total
Today
Yesterday