-
Notifications
You must be signed in to change notification settings - Fork 1
[FEAT] 배포 및 빌드 자동화 #134
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
Merged
Merged
[FEAT] 배포 및 빌드 자동화 #134
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
47fe09e
Develop에서 main merge (svg 오류 해결) (#123)
P1su d5af790
Merge branch 'main' into develop
P1su a796c6f
Merge branch 'develop' of https://github.com/codeit-momentum/moment-f…
P1su d929335
Merge branch 'develop' of https://github.com/codeit-momentum/moment-f…
P1su 2eff018
Merge branch 'develop' of https://github.com/codeit-momentum/moment-f…
P1su aaebec1
Merge branch 'develop' of https://github.com/codeit-momentum/moment-f…
P1su 8850d4d
style: 저장되지 않은 코드 저장
P1su 81aaaa1
feat: 빌드 자동화 구현
P1su 1ca573a
feat: 배포 자동화 및 빌드 자동화 설정
P1su File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| name: PR Build | ||
|
|
||
| on: | ||
| pull_request: | ||
| branches: ['**'] | ||
|
|
||
| jobs: | ||
| build: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Corepack | ||
| run: corepack enable | ||
|
|
||
| - name: Install Dependency | ||
| run: yarn install | ||
|
|
||
| - name: Lint test | ||
| run: yarn lint | ||
|
|
||
| - name: Build test | ||
| working-directory: ./src | ||
| run: yarn build |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,48 @@ | ||
| name: Deploy | ||
|
|
||
| on: | ||
| push: | ||
| branches: ['main'] | ||
|
|
||
| jobs: | ||
| build: | ||
| runs-on: ubuntu-latest | ||
|
|
||
| container: pandoc/latex | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v2 | ||
|
|
||
| - name: Install mustache (to update the date) | ||
|
|
||
| run: apk add ruby && gem install mustache | ||
|
|
||
| - name: creates output | ||
|
|
||
| run: sh ./build.sh | ||
|
|
||
| - name: Pushes to another repository | ||
|
|
||
| id: push_directory | ||
|
|
||
| uses: cpina/github-action-push-to-another-repository@main | ||
|
|
||
| env: | ||
| API_TOKEN_GITHUB: ${{ secrets.AUTO_ACTIONS }} | ||
|
|
||
| with: | ||
| source-directory: 'output' | ||
|
|
||
| destination-github-username: P1su | ||
|
|
||
| destination-repository-name: moment-front | ||
|
|
||
| user-email: ${{ secrets.EMAIL }} | ||
|
|
||
| commit-message: ${{ github.event.commits[0].message }} | ||
|
|
||
| target-branch: main | ||
|
|
||
| - name: Test get variable exported by push-to-another-repository | ||
|
|
||
| run: echo $DESTINATION_CLONED_DIRECTORY | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| #!/bin/sh | ||
| cd ../ | ||
| mkdir output | ||
| cp -R ./moment-front/* ./output | ||
| cp -R ./output ./moment-front/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
혹시 이 작업은 왜 필요한 건지 궁금합니다..!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
템플릿 엔진을 설치하여 빌드 시 날짜 업데이트 등의 작업에 사용될 수 있는데, 현재 build.sh 에서 단순 파일 복사만 진행하고 있어 삭제해도 되는 부분같네요
확인해주셔서 감사합니다!