feat: 初始化项目结构和配置- 创建 Maven 项目配置文件 pom.xml

- 添加 Spring Boot 相关依赖
- 创建项目启动类 PortalApplication
- 配置 .gitignore 文件,忽略IDE和系统产生的临时文件
This commit is contained in:
chaos
2025-07-14 16:02:50 +08:00
commit 7909cbe135
4 changed files with 120 additions and 0 deletions

33
c_portal/pom.xml Normal file
View File

@@ -0,0 +1,33 @@
<?xml version="1.0" encoding="UTF-8"?>
<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">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>cn.nopj</groupId>
<artifactId>chaos_api</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>
<artifactId>c_portal</artifactId>
<properties>
<maven.compiler.source>21</maven.compiler.source>
<maven.compiler.target>21</maven.compiler.target>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<!-- https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-web -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<!-- https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-autoconfigure -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-autoconfigure</artifactId>
</dependency>
</dependencies>
</project>

View File

@@ -0,0 +1,11 @@
package cn.nopj.chaos.portal;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication(scanBasePackages = "cn.nopj.chaos")
public class PortalApplication {
public static void main(String[] args) {
SpringApplication.run(PortalApplication.class,args);
}
}