Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: restdocs index.html 에서 안 보이는 문제 해결한다 #565

Merged
merged 3 commits into from
Aug 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/backend-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ jobs:
- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Build for asciiDoc
run: ./gradlew bootjar

- name: Build with Gradle
run: ./gradlew bootjar

Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/backend-dev-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ jobs:
- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Build for asciiDoc
run: ./gradlew bootjar
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

bootjar 두번하는 이유 있나요??

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2번 안하면 html 파일을 못 읽어가더라고요

과거 기수도 저렇게 해서 그냥 가져왔어요


- name: Build with Gradle
run: ./gradlew bootjar

Expand Down
2 changes: 2 additions & 0 deletions backend/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,5 @@ out/
src/main/resources/encryptKey.txt

mysql

/src/main/resources/static/docs/
18 changes: 13 additions & 5 deletions backend/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,22 @@ tasks.named('asciidoctor') {
}

asciidoctor {
inputs.dir snippetsDir
configurations 'asciidoctorExt'
dependsOn test
configurations 'asciidoctorExt'
baseDirFollowsSourceFile()
}

bootJar {

tasks.register('copyApiDocument', Copy) {
dependsOn asciidoctor
from("${asciidoctor.outputDir}") {
into 'static/docs'
doFirst {
delete file("src/main/resources/static/docs") // 기존 문서 삭제
}

from asciidoctor.outputDir
into file("src/main/resources/static/docs")
}

bootJar {
dependsOn copyApiDocument
}
10 changes: 8 additions & 2 deletions backend/src/docs/asciidoc/index.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ endif::[]
:source-highlighter: highlightjs
:sectlinks:

include::station.adoc[]
include::filter.adoc[]
include::admin.adoc[]
include::auth.adoc[]
include::car.adoc[]
include::filter.adoc[]
include::member.adoc[]
include::reply.adoc[]
include::report.adoc[]
include::review.adoc[]
include::station.adoc[]
12 changes: 6 additions & 6 deletions backend/src/docs/asciidoc/member.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@

=== Request

include::{snippets}/member-controller-test/find_all_filters/request-headers.adoc[]
include::{snippets}/member-controller-test/find_all_filters/path-parameters.adoc[]
include::{snippets}/member-controller-test/find_all_filters/request-body.adoc[]
include::{snippets}/member-controller-test/find_all_filters/http-request.adoc[]
include::{snippets}/member-controller-test/find_member_filters/request-headers.adoc[]
include::{snippets}/member-controller-test/find_member_filters/path-parameters.adoc[]
include::{snippets}/member-controller-test/find_member_filters/request-body.adoc[]
include::{snippets}/member-controller-test/find_member_filters/http-request.adoc[]

=== Response

include::{snippets}/member-controller-test/find_all_filters/response-fields.adoc[]
include::{snippets}/member-controller-test/find_all_filters/http-response.adoc[]
include::{snippets}/member-controller-test/find_member_filters/response-fields.adoc[]
include::{snippets}/member-controller-test/find_member_filters/http-response.adoc[]

== 회원의 선호 필터를 등록한다

Expand Down
Loading