From fb7fc0ea95a7458da4ff18ae7560b8d97df86071 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Wed, 18 Dec 2024 17:51:16 +0900 Subject: [PATCH 01/16] =?UTF-8?q?feat/#197:=20=ED=8E=98=EC=9D=B4=EC=A7=95?= =?UTF-8?q?=20=EC=A1=B0=ED=9A=8C=20=EC=8B=9C=20=EC=82=AC=EC=9D=B4=EC=A6=88?= =?UTF-8?q?=20=EC=9E=85=EB=A0=A5=EB=B0=9B=EB=8F=84=EB=A1=9D=20=EB=B3=80?= =?UTF-8?q?=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../git/problem/api/controller/ProblemController.java | 9 +++++++-- .../inha/git/problem/api/service/ProblemService.java | 2 +- .../inha/git/problem/api/service/ProblemServiceImpl.java | 5 +++-- .../git/project/api/controller/ProjectController.java | 8 ++++++-- .../git/project/api/service/ProjectSearchService.java | 2 +- .../project/api/service/ProjectSearchServiceImpl.java | 5 +++-- 6 files changed, 21 insertions(+), 10 deletions(-) diff --git a/src/main/java/inha/git/problem/api/controller/ProblemController.java b/src/main/java/inha/git/problem/api/controller/ProblemController.java index 009d77a9..78e97297 100644 --- a/src/main/java/inha/git/problem/api/controller/ProblemController.java +++ b/src/main/java/inha/git/problem/api/controller/ProblemController.java @@ -129,17 +129,22 @@ public BaseResponse deleteProblem(@AuthenticationPrincipal User * 문제 신청 목록 조회 API * * @param page 페이지 + * @param size 사이즈 * @return 문제 신청 목록 */ @GetMapping("/requests") @Operation(summary = "문제 신청 목록 조회 API", description = "문제 신청 목록을 조회합니다.") public BaseResponse> getRequestProblems( @RequestParam("problemIdx") Integer problemIdx, - @RequestParam("page") Integer page) { + @RequestParam("page") Integer page, + @RequestParam("size") Integer size) { if (page < 1) { throw new BaseException(INVALID_PAGE); } - return BaseResponse.of(PROBLEM_REQUEST_SEARCH_OK, problemService.getRequestProblems(problemIdx, page - 1)); + if (size < 1) { + throw new BaseException(INVALID_PAGE); + } + return BaseResponse.of(PROBLEM_REQUEST_SEARCH_OK, problemService.getRequestProblems(problemIdx, page - 1, size - 1)); } /** diff --git a/src/main/java/inha/git/problem/api/service/ProblemService.java b/src/main/java/inha/git/problem/api/service/ProblemService.java index 93bcb876..2f67a1c0 100644 --- a/src/main/java/inha/git/problem/api/service/ProblemService.java +++ b/src/main/java/inha/git/problem/api/service/ProblemService.java @@ -14,7 +14,7 @@ public interface ProblemService { ProblemResponse createProblem(User user, CreateProblemRequest createProblemRequest, MultipartFile file); ProblemResponse updateProblem(User user, Integer problemIdx, UpdateProblemRequest updateProblemRequest, MultipartFile file); ProblemResponse deleteProblem(User user, Integer problemIdx); - Page getRequestProblems(Integer problemIdx, Integer page); + Page getRequestProblems(Integer problemIdx, Integer page, Integer size); RequestProblemResponse requestUser(User user, CreateRequestProblemRequest createRequestProblemRequest); RequestProblemResponse requestTeam(User user, CreateTeamRequestProblemRequest createTeamRequestProblemRequest); RequestProblemResponse approveRequest(User user, CreateProblemApproveRequest createProblemApproveRequest); diff --git a/src/main/java/inha/git/problem/api/service/ProblemServiceImpl.java b/src/main/java/inha/git/problem/api/service/ProblemServiceImpl.java index 384c7b65..9b3aaec3 100644 --- a/src/main/java/inha/git/problem/api/service/ProblemServiceImpl.java +++ b/src/main/java/inha/git/problem/api/service/ProblemServiceImpl.java @@ -156,11 +156,12 @@ public ProblemResponse deleteProblem(User user, Integer problemIdx) { * * @param problemIdx 문제 인덱스 * @param page 페이지 + * @param size 사이즈 * @return 문제 신청 목록 */ @Override - public Page getRequestProblems(Integer problemIdx, Integer page) { - Pageable pageable = PageRequest.of(page, 10, Sort.by(Sort.Direction.DESC, CREATE_AT)); + public Page getRequestProblems(Integer problemIdx, Integer page, Integer size) { + Pageable pageable = PageRequest.of(page, size, Sort.by(Sort.Direction.DESC, CREATE_AT)); return problemQueryRepository.getRequestProblems(problemIdx, pageable); } diff --git a/src/main/java/inha/git/project/api/controller/ProjectController.java b/src/main/java/inha/git/project/api/controller/ProjectController.java index 48c434bd..f78b5f2f 100644 --- a/src/main/java/inha/git/project/api/controller/ProjectController.java +++ b/src/main/java/inha/git/project/api/controller/ProjectController.java @@ -75,16 +75,20 @@ public BaseResponse> getProjects(@RequestParam("pag * * @param searchProjectCond 프로젝트 검색 조건 * @param page 페이지 번호 + * @param size size 페이지 사이즈 * @return 검색된 프로젝트 정보를 포함하는 BaseResponse> */ @GetMapping("/cond") @Operation(summary = "프로젝트 조건 조회 API", description = "프로젝트 조건에 맞게 조회합니다.") public BaseResponse> getCondProjects(@Validated @ModelAttribute SearchProjectCond searchProjectCond, - @RequestParam("page") Integer page) { + @RequestParam("page") Integer page, @RequestParam("size") Integer size) { if (page < 1) { throw new BaseException(INVALID_PAGE); } - return BaseResponse.of(PROJECT_SEARCH_CONDITION_OK, projectSearchService.getCondProjects(searchProjectCond, page - 1)); + if (size < 1) { + throw new BaseException(INVALID_PAGE); + } + return BaseResponse.of(PROJECT_SEARCH_CONDITION_OK, projectSearchService.getCondProjects(searchProjectCond, page - 1, size - 1)); } diff --git a/src/main/java/inha/git/project/api/service/ProjectSearchService.java b/src/main/java/inha/git/project/api/service/ProjectSearchService.java index 7028bdb3..70cb2c0b 100644 --- a/src/main/java/inha/git/project/api/service/ProjectSearchService.java +++ b/src/main/java/inha/git/project/api/service/ProjectSearchService.java @@ -12,7 +12,7 @@ public interface ProjectSearchService { Page getProjects(Integer page, Integer size); - Page getCondProjects(SearchProjectCond searchProjectCond, Integer page); + Page getCondProjects(SearchProjectCond searchProjectCond, Integer page, Integer size); SearchProjectResponse getProject(User user, Integer projectIdx); List getProjectFileByIdx(User user, Integer projectIdx, String path); diff --git a/src/main/java/inha/git/project/api/service/ProjectSearchServiceImpl.java b/src/main/java/inha/git/project/api/service/ProjectSearchServiceImpl.java index 8530dc35..47b952d9 100644 --- a/src/main/java/inha/git/project/api/service/ProjectSearchServiceImpl.java +++ b/src/main/java/inha/git/project/api/service/ProjectSearchServiceImpl.java @@ -82,11 +82,12 @@ public Page getProjects(Integer page, Integer size) { * * @param searchProjectCond 검색 조건 * @param page 페이지 번호 + * @param size 페이지 사이즈 * @return 검색된 프로젝트 정보 페이지 */ @Override - public Page getCondProjects(SearchProjectCond searchProjectCond, Integer page) { - Pageable pageable = PageRequest.of(page, 10, Sort.by(Sort.Direction.DESC, CREATE_AT)); + public Page getCondProjects(SearchProjectCond searchProjectCond, Integer page, Integer size) { + Pageable pageable = PageRequest.of(page, size, Sort.by(Sort.Direction.DESC, CREATE_AT)); return projectQueryRepository.getCondProjects(searchProjectCond, pageable); } From 719f2f652982fe82a21428a77ffeae16c07e2e90 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Wed, 18 Dec 2024 17:55:47 +0900 Subject: [PATCH 02/16] =?UTF-8?q?feat/#197:=20=ED=8E=98=EC=9D=B4=EC=A7=95?= =?UTF-8?q?=20=EC=A1=B0=ED=9A=8C=20=EC=8B=9C=20=EC=82=AC=EC=9D=B4=EC=A6=88?= =?UTF-8?q?=20=EC=9E=85=EB=A0=A5=EB=B0=9B=EB=8F=84=EB=A1=9D=20=EB=B3=80?= =?UTF-8?q?=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/controller/QuestionController.java | 19 +++++++++++++------ .../question/api/service/QuestionService.java | 4 ++-- .../api/service/QuestionServiceImpl.java | 10 ++++++---- 3 files changed, 21 insertions(+), 12 deletions(-) diff --git a/src/main/java/inha/git/question/api/controller/QuestionController.java b/src/main/java/inha/git/question/api/controller/QuestionController.java index 9e96d0ae..f11ad90b 100644 --- a/src/main/java/inha/git/question/api/controller/QuestionController.java +++ b/src/main/java/inha/git/question/api/controller/QuestionController.java @@ -22,8 +22,7 @@ import org.springframework.validation.annotation.Validated; import org.springframework.web.bind.annotation.*; -import static inha.git.common.code.status.ErrorStatus.COMPANY_CANNOT_CREATE_QUESTION; -import static inha.git.common.code.status.ErrorStatus.INVALID_PAGE; +import static inha.git.common.code.status.ErrorStatus.*; import static inha.git.common.code.status.SuccessStatus.*; /** @@ -45,15 +44,19 @@ public class QuestionController { *

질문 전체를 조회합니다.

* * @param page Integer + * @param size Integer * @return 검색된 질문 정보를 포함하는 BaseResponse> */ @GetMapping @Operation(summary = "질문 전체 조회 API", description = "질문 전체를 조회합니다.") - public BaseResponse> getQuestions(@RequestParam("page") Integer page) { + public BaseResponse> getQuestions(@RequestParam("page") Integer page, @RequestParam("size") Integer size) { if (page < 1) { throw new BaseException(INVALID_PAGE); } - return BaseResponse.of(QUESTION_SEARCH_OK, questionService.getQuestions(page - 1)); + if (size < 1) { + throw new BaseException(INVALID_SIZE); + } + return BaseResponse.of(QUESTION_SEARCH_OK, questionService.getQuestions(page - 1, size - 1)); } /** @@ -62,16 +65,20 @@ public BaseResponse> getQuestions(@RequestParam("p *

질문 조건에 맞게 조회합니다.

* * @param page Integer + * @param size Integer * @param searchQuestionCond SearchQuestionCond * @return 검색된 질문 정보를 포함하는 BaseResponse> */ @GetMapping("/cond") @Operation(summary = "질문 조건 조회 API", description = "질문 조건에 맞게 조회합니다.") - public BaseResponse> getCondQuestions(@RequestParam("page") Integer page, SearchQuestionCond searchQuestionCond) { + public BaseResponse> getCondQuestions(@RequestParam("page") Integer page, @RequestParam("size") Integer size , SearchQuestionCond searchQuestionCond) { if (page < 1) { throw new BaseException(INVALID_PAGE); } - return BaseResponse.of(QUESTION_SEARCH_OK, questionService.getCondQuestions(searchQuestionCond, page - 1)); + if (size < 1) { + throw new BaseException(INVALID_SIZE); + } + return BaseResponse.of(QUESTION_SEARCH_OK, questionService.getCondQuestions(searchQuestionCond, page - 1, size - 1)); } /** diff --git a/src/main/java/inha/git/question/api/service/QuestionService.java b/src/main/java/inha/git/question/api/service/QuestionService.java index 52a8c939..8f6fa1ff 100644 --- a/src/main/java/inha/git/question/api/service/QuestionService.java +++ b/src/main/java/inha/git/question/api/service/QuestionService.java @@ -11,8 +11,8 @@ import org.springframework.data.domain.Page; public interface QuestionService { - Page getQuestions(Integer page); - Page getCondQuestions(SearchQuestionCond searchQuestionCond, Integer page); + Page getQuestions(Integer page, Integer size); + Page getCondQuestions(SearchQuestionCond searchQuestionCond, Integer page, Integer size); SearchQuestionResponse getQuestion(User user, Integer questionIdx); QuestionResponse createQuestion(User user, CreateQuestionRequest createQuestionRequest); QuestionResponse updateQuestion(User user, Integer questionIdx, UpdateQuestionRequest updateQuestionRequest); diff --git a/src/main/java/inha/git/question/api/service/QuestionServiceImpl.java b/src/main/java/inha/git/question/api/service/QuestionServiceImpl.java index 298e6fd0..79cf538c 100644 --- a/src/main/java/inha/git/question/api/service/QuestionServiceImpl.java +++ b/src/main/java/inha/git/question/api/service/QuestionServiceImpl.java @@ -76,11 +76,12 @@ public class QuestionServiceImpl implements QuestionService { * 질문 전체 조회 * * @param page Integer + * @param size Integer * @return Page */ @Override - public Page getQuestions(Integer page) { - Pageable pageable = PageRequest.of(page, 10, Sort.by(Sort.Direction.DESC, CREATE_AT)); + public Page getQuestions(Integer page, Integer size) { + Pageable pageable = PageRequest.of(page, size, Sort.by(Sort.Direction.DESC, CREATE_AT)); return questionQueryRepository.getQuestions(pageable); } @@ -89,11 +90,12 @@ public Page getQuestions(Integer page) { * * @param searchQuestionCond SearchQuestionCond * @param page Integer + * @param size Integer * @return Page */ @Override - public Page getCondQuestions(SearchQuestionCond searchQuestionCond, Integer page) { - Pageable pageable = PageRequest.of(page, 10, Sort.by(Sort.Direction.DESC, CREATE_AT)); + public Page getCondQuestions(SearchQuestionCond searchQuestionCond, Integer page, Integer size) { + Pageable pageable = PageRequest.of(page, size, Sort.by(Sort.Direction.DESC, CREATE_AT)); return questionQueryRepository.getCondQuestions(searchQuestionCond, pageable); } From 9624b749dfdc627c1530ef8915b7c917412ef65e Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:00:29 +0900 Subject: [PATCH 03/16] =?UTF-8?q?docs/#202:=20=EB=AC=B8=EC=84=9C=20?= =?UTF-8?q?=EC=9E=90=EB=8F=99=ED=99=94=20workflows=20=EA=B8=B0=EB=8A=A5=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/docs.yml | 64 ++++++++++++++++++++++++++++++++++++++ .gitignore | 5 ++- build.gradle | 21 +++++++++++++ 3 files changed, 89 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/docs.yml diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml new file mode 100644 index 00000000..1e585dcf --- /dev/null +++ b/.github/workflows/docs.yml @@ -0,0 +1,64 @@ +# .github/workflows/docs.yml +name: Deploy Documentation + +on: + pull_request: + branches: + - develop + types: [closed] + paths: + - 'src/**' + - 'build.gradle' + - '**/*.java' + +jobs: + deploy-docs: + # PR이 머지됐을 때만 실행 + if: github.event.pull_request.merged == true + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + with: + fetch-depth: 0 + + - name: Set up JDK 17 + uses: actions/setup-java@v3 + with: + java-version: '17' + distribution: 'temurin' + cache: gradle + + - name: Grant execute permission for gradlew + run: chmod +x gradlew + + - name: Generate Documentation + run: | + ./gradlew clean javadoc + + - name: Deploy to Docs Repo + uses: peaceiris/actions-gh-pages@v3 + with: + personal_token: ${{ secrets.DOCS_DEPLOY_TOKEN }} + external_repository: inha-iesw/inhagit-server-docs + publish_branch: main + publish_dir: ./build/docs/javadoc + commit_message: | + docs: update documentation from PR #${{ github.event.pull_request.number }} + + PR Title: ${{ github.event.pull_request.title }} + Merged by: ${{ github.event.pull_request.merged_by.login }} + user_name: 'github-actions[bot]' + user_email: 'github-actions[bot]@users.noreply.github.com' + + - name: Comment on PR + uses: actions/github-script@v6 + with: + script: | + github.rest.issues.createComment({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.issue.number, + body: '📚 Documentation has been updated and deployed to https://inha-iesw.github.io/inhagit-server-docs' + }) \ No newline at end of file diff --git a/.gitignore b/.gitignore index 0eaea8c0..5c9d8483 100644 --- a/.gitignore +++ b/.gitignore @@ -49,4 +49,7 @@ src/main/java/inha/git/InitData.java logs logback-spring.xml -src/main/java/inha/git/common/config/SwaggerConfig.java \ No newline at end of file +src/main/java/inha/git/common/config/SwaggerConfig.java + + +docs/** \ No newline at end of file diff --git a/build.gradle b/build.gradle index 238e759e..b3bacb59 100644 --- a/build.gradle +++ b/build.gradle @@ -107,4 +107,25 @@ tasks.named('test') { jar { enabled = false +} + +javadoc { + options { + encoding = 'UTF-8' + charSet = 'UTF-8' + author = true + version = true + links = ['https://docs.oracle.com/en/java/javase/17/docs/api/'] + title = "I-OSS Server API Documentation" + addStringOption('Xdoclint:none', '-quiet') + addBooleanOption('html5', true) + } + // 소스 파일 인코딩 설정 + options.encoding = 'UTF-8' +} + +tasks.register('copyDoc', Copy) { + dependsOn 'javadoc' + from "$buildDir/docs/javadoc" + into "$projectDir/docs" } \ No newline at end of file From bb39db2900b5921aa49744436f5f4de203b58770 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:06:32 +0900 Subject: [PATCH 04/16] =?UTF-8?q?docs/#202:=20=EB=AC=B8=EC=84=9C=20?= =?UTF-8?q?=EC=9E=90=EB=8F=99=ED=99=94=20workflows=20=EA=B8=B0=EB=8A=A5=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/docs.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 1e585dcf..55d9ee83 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -11,6 +11,12 @@ on: - 'build.gradle' - '**/*.java' +permissions: + contents: write + pull-requests: write + issues: write + + jobs: deploy-docs: # PR이 머지됐을 때만 실행 From 10bcc4486ba749a5bff663bcf9f52246e5ce8b13 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:11:55 +0900 Subject: [PATCH 05/16] =?UTF-8?q?docs/#202:=20=EB=AC=B8=EC=84=9C=20?= =?UTF-8?q?=EC=9E=90=EB=8F=99=ED=99=94=20workflows=20=EA=B8=B0=EB=8A=A5?= =?UTF-8?q?=EC=97=90=EC=84=9C=20=EC=BD=94=EB=A9=98=ED=8A=B8=20=EA=B8=B0?= =?UTF-8?q?=EB=8A=A5=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/docs.yml | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 55d9ee83..e01c0334 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,4 +1,3 @@ -# .github/workflows/docs.yml name: Deploy Documentation on: @@ -13,16 +12,12 @@ on: permissions: contents: write - pull-requests: write - issues: write - jobs: deploy-docs: - # PR이 머지됐을 때만 실행 if: github.event.pull_request.merged == true runs-on: ubuntu-latest - + steps: - name: Checkout repository uses: actions/checkout@v3 @@ -56,15 +51,4 @@ jobs: PR Title: ${{ github.event.pull_request.title }} Merged by: ${{ github.event.pull_request.merged_by.login }} user_name: 'github-actions[bot]' - user_email: 'github-actions[bot]@users.noreply.github.com' - - - name: Comment on PR - uses: actions/github-script@v6 - with: - script: | - github.rest.issues.createComment({ - owner: context.repo.owner, - repo: context.repo.repo, - issue_number: context.issue.number, - body: '📚 Documentation has been updated and deployed to https://inha-iesw.github.io/inhagit-server-docs' - }) \ No newline at end of file + user_email: 'github-actions[bot]@users.noreply.github.com' \ No newline at end of file From c246ee944a77f6fc047807ded7bc61d7a0e898c8 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:16:36 +0900 Subject: [PATCH 06/16] =?UTF-8?q?docs/#202:=20=EB=AC=B8=EC=84=9C=20?= =?UTF-8?q?=EC=9E=90=EB=8F=99=ED=99=94=20workflows=20=EA=B8=B0=EB=8A=A5?= =?UTF-8?q?=EC=97=90=EC=84=9C=20=EC=BD=94=EB=A9=98=ED=8A=B8=20=EA=B8=B0?= =?UTF-8?q?=EB=8A=A5=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/docs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index e01c0334..e1462ef4 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -51,4 +51,4 @@ jobs: PR Title: ${{ github.event.pull_request.title }} Merged by: ${{ github.event.pull_request.merged_by.login }} user_name: 'github-actions[bot]' - user_email: 'github-actions[bot]@users.noreply.github.com' \ No newline at end of file + user_email: 'github-actions[bot]@users.noreply.github.com' From be063cc1366824c527f446914f8d66b680cbc7b6 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:20:50 +0900 Subject: [PATCH 07/16] =?UTF-8?q?docs/#202:=20=EB=AC=B8=EC=84=9C=20?= =?UTF-8?q?=EC=9E=90=EB=8F=99=ED=99=94=20workflows=20=EA=B8=B0=EB=8A=A5?= =?UTF-8?q?=EC=97=90=EC=84=9C=20=EC=BD=94=EB=A9=98=ED=8A=B8=20=EA=B8=B0?= =?UTF-8?q?=EB=8A=A5=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/docs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index e1462ef4..e01c0334 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -51,4 +51,4 @@ jobs: PR Title: ${{ github.event.pull_request.title }} Merged by: ${{ github.event.pull_request.merged_by.login }} user_name: 'github-actions[bot]' - user_email: 'github-actions[bot]@users.noreply.github.com' + user_email: 'github-actions[bot]@users.noreply.github.com' \ No newline at end of file From 2993b01b4de7815a6c8d387a6ed7e04641c8e1ea Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:22:32 +0900 Subject: [PATCH 08/16] =?UTF-8?q?docs/#202:=20=EB=AC=B8=EC=84=9C=20?= =?UTF-8?q?=EC=9E=90=EB=8F=99=ED=99=94=20workflows=20=EA=B8=B0=EB=8A=A5?= =?UTF-8?q?=EC=97=90=EC=84=9C=20=EC=BD=94=EB=A9=98=ED=8A=B8=20=EA=B8=B0?= =?UTF-8?q?=EB=8A=A5=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/docs.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index e01c0334..55fc96e6 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,23 +1,25 @@ name: Deploy Documentation on: - pull_request: + pull_request_target: branches: - develop - types: [closed] + types: + - closed # 닫힐 때만 실행 paths: - 'src/**' - 'build.gradle' - '**/*.java' + workflow_dispatch: # 수동 실행 옵션은 유지 permissions: contents: write jobs: deploy-docs: - if: github.event.pull_request.merged == true + if: github.event.pull_request.merged == true || github.event_name == 'workflow_dispatch' runs-on: ubuntu-latest - + steps: - name: Checkout repository uses: actions/checkout@v3 From 24dbb84fac0e47cf83d5b7100edc697a8ccdb844 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:27:04 +0900 Subject: [PATCH 09/16] =?UTF-8?q?docs/#202:=20=EB=AC=B8=EC=84=9C=20?= =?UTF-8?q?=EC=9E=90=EB=8F=99=ED=99=94=20workflows=20=EA=B8=B0=EB=8A=A5?= =?UTF-8?q?=EC=97=90=EC=84=9C=20=EC=BD=94=EB=A9=98=ED=8A=B8=20=EA=B8=B0?= =?UTF-8?q?=EB=8A=A5=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/docs.yml | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 55fc96e6..90313e0c 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,23 +1,20 @@ +# .github/workflows/docs.yml name: Deploy Documentation on: - pull_request_target: + pull_request: branches: - develop - types: - - closed # 닫힐 때만 실행 + types: [closed] paths: - 'src/**' - 'build.gradle' - '**/*.java' - workflow_dispatch: # 수동 실행 옵션은 유지 - -permissions: - contents: write jobs: deploy-docs: - if: github.event.pull_request.merged == true || github.event_name == 'workflow_dispatch' + # PR이 머지됐을 때만 실행 + if: github.event.pull_request.merged == true runs-on: ubuntu-latest steps: From 73e33efa1f12fbe12a1e3355e662eba065f8404c Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:30:05 +0900 Subject: [PATCH 10/16] =?UTF-8?q?docs/#202:=20=ED=85=8C=EC=8A=A4=ED=8A=B8?= =?UTF-8?q?=EC=9A=A9=20yml=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/test.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 .github/workflows/test.yml diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 00000000..03460933 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,16 @@ +name: Test Workflow + +on: + pull_request: + types: [closed] + +jobs: + test-job: + runs-on: ubuntu-latest + steps: + - name: Log PR Event + run: | + echo "Event type: ${{ github.event_name }}" + echo "PR number: ${{ github.event.pull_request.number }}" + echo "PR merged: ${{ github.event.pull_request.merged }}" + echo "Current branch: ${{ github.ref }}" \ No newline at end of file From a8eee89d1c2dfd7c5140ff651fda3d5744fd8430 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:32:06 +0900 Subject: [PATCH 11/16] =?UTF-8?q?docs/#202:=20=ED=85=8C=EC=8A=A4=ED=8A=B8?= =?UTF-8?q?=EC=9A=A9=20yml=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/test.yml | 16 ---------------- .../user/api/controller/ProfessorController.java | 1 + 2 files changed, 1 insertion(+), 16 deletions(-) delete mode 100644 .github/workflows/test.yml diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml deleted file mode 100644 index 03460933..00000000 --- a/.github/workflows/test.yml +++ /dev/null @@ -1,16 +0,0 @@ -name: Test Workflow - -on: - pull_request: - types: [closed] - -jobs: - test-job: - runs-on: ubuntu-latest - steps: - - name: Log PR Event - run: | - echo "Event type: ${{ github.event_name }}" - echo "PR number: ${{ github.event.pull_request.number }}" - echo "PR merged: ${{ github.event.pull_request.merged }}" - echo "Current branch: ${{ github.ref }}" \ No newline at end of file diff --git a/src/main/java/inha/git/user/api/controller/ProfessorController.java b/src/main/java/inha/git/user/api/controller/ProfessorController.java index 80570c01..dd518839 100644 --- a/src/main/java/inha/git/user/api/controller/ProfessorController.java +++ b/src/main/java/inha/git/user/api/controller/ProfessorController.java @@ -27,6 +27,7 @@ public class ProfessorController { private final ProfessorService professorService; + /** * 교수 전용 학생 검색 API * From dd7049d8e9986190d74d3daca0d228ee67fdb0f0 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:39:30 +0900 Subject: [PATCH 12/16] =?UTF-8?q?docs/#202:=20=ED=85=8C=EC=8A=A4=ED=8A=B8?= =?UTF-8?q?=EC=9A=A9=20yml=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/docs.yml | 8 -------- 1 file changed, 8 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 90313e0c..2af67e8d 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,4 +1,3 @@ -# .github/workflows/docs.yml name: Deploy Documentation on: @@ -6,17 +5,11 @@ on: branches: - develop types: [closed] - paths: - - 'src/**' - - 'build.gradle' - - '**/*.java' jobs: deploy-docs: - # PR이 머지됐을 때만 실행 if: github.event.pull_request.merged == true runs-on: ubuntu-latest - steps: - name: Checkout repository uses: actions/checkout@v3 @@ -46,7 +39,6 @@ jobs: publish_dir: ./build/docs/javadoc commit_message: | docs: update documentation from PR #${{ github.event.pull_request.number }} - PR Title: ${{ github.event.pull_request.title }} Merged by: ${{ github.event.pull_request.merged_by.login }} user_name: 'github-actions[bot]' From 59c8b3fc019ea1dc7c3216545d96f7091b36bef3 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 11:41:06 +0900 Subject: [PATCH 13/16] =?UTF-8?q?docs/#202:=20=ED=85=8C=EC=8A=A4=ED=8A=B8?= =?UTF-8?q?=EC=9A=A9=20yml=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/inha/git/user/api/service/StudentServiceImpl.java | 1 - 1 file changed, 1 deletion(-) diff --git a/src/main/java/inha/git/user/api/service/StudentServiceImpl.java b/src/main/java/inha/git/user/api/service/StudentServiceImpl.java index efdc13ff..34dd04bb 100644 --- a/src/main/java/inha/git/user/api/service/StudentServiceImpl.java +++ b/src/main/java/inha/git/user/api/service/StudentServiceImpl.java @@ -33,7 +33,6 @@ public class StudentServiceImpl implements StudentService{ private final MailService mailService; private final EmailDomainService emailDomainService; - /** * 학생 회원가입 * From 0fe36f9af89b45c588cafcd2272f69253f2af880 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 13:38:10 +0900 Subject: [PATCH 14/16] =?UTF-8?q?feat:=20=EC=84=9C=EB=B8=8C=EB=AA=A8?= =?UTF-8?q?=EB=93=88=20=EB=8F=84=EC=9E=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 6 +++++- .gitmodules | 3 +++ src/main/resources/application.yml | 18 ++++++++++++++++++ 3 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 .gitmodules create mode 100644 src/main/resources/application.yml diff --git a/.gitignore b/.gitignore index 5c9d8483..80266c70 100644 --- a/.gitignore +++ b/.gitignore @@ -52,4 +52,8 @@ logback-spring.xml src/main/java/inha/git/common/config/SwaggerConfig.java -docs/** \ No newline at end of file +docs/** + +.gitmodules + +inhagit-server-secret/** \ No newline at end of file diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 00000000..e3940e3e --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "inhagit-server-secret"] + path = inhagit-server-secret + url = https://github.com/inha-iesw/inhagit-server-secret.git diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml new file mode 100644 index 00000000..5380e5f1 --- /dev/null +++ b/src/main/resources/application.yml @@ -0,0 +1,18 @@ +spring: + config: + activate: + on-profile: local + import: optional:file:./inhagit-server-secret/application-local.yml +--- +spring: + config: + activate: + on-profile: dev + import: optional:file:./inhagit-server-secret/application-dev.yml +--- +spring: + config: + activate: + on-profile: prod + import: optional:file:./inhagit-server-secret/application-prod.yml +--- \ No newline at end of file From 02041f5135f1f29eab8b38217385294adea863bf Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 14:03:35 +0900 Subject: [PATCH 15/16] =?UTF-8?q?feat:=20=EA=B2=BD=EB=A1=9C=20=ED=99=98?= =?UTF-8?q?=EA=B2=BD=EB=B3=80=EC=88=98=20=EC=A3=BC=EC=9E=85=EC=9C=BC?= =?UTF-8?q?=EB=A1=9C=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/resources/application.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml index 5380e5f1..d668ec6a 100644 --- a/src/main/resources/application.yml +++ b/src/main/resources/application.yml @@ -2,17 +2,16 @@ spring: config: activate: on-profile: local - import: optional:file:./inhagit-server-secret/application-local.yml + import: optional:file:${SPRING_CONFIG_LOCATION}application-local.yml --- spring: config: activate: on-profile: dev - import: optional:file:./inhagit-server-secret/application-dev.yml + import: optional:file:${SPRING_CONFIG_LOCATION}application-dev.yml --- spring: config: activate: on-profile: prod - import: optional:file:./inhagit-server-secret/application-prod.yml ---- \ No newline at end of file + import: optional:file:${SPRING_CONFIG_LOCATION}application-prod.yml From 39731dc2c5e202fcfbd54af32af06aa4a634ef75 Mon Sep 17 00:00:00 2001 From: Gyuhyeok99 <126947828+Gyuhyeok99@users.noreply.github.com> Date: Thu, 19 Dec 2024 17:20:48 +0900 Subject: [PATCH 16/16] Version 1.0.8 Release --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index b3bacb59..047a0f0c 100644 --- a/build.gradle +++ b/build.gradle @@ -5,7 +5,7 @@ plugins { } group = 'inha' -version = '1.0.7' +version = '1.0.8' java { toolchain {