diff --git a/.github/scripts/install.sh b/.github/scripts/install.sh new file mode 100644 index 0000000..e41efa0 --- /dev/null +++ b/.github/scripts/install.sh @@ -0,0 +1,7 @@ +latest_release="$(curl -Ls -o /dev/null -w %{url_effective} https://github.com/jgm/pandoc/releases/latest | cut -d'/' -f8)" +download_link="https://github.com/jgm/pandoc/releases/download/$latest_release/pandoc-$latest_release-1-amd64.deb" +downloaded_filename="$(basename $download_link)" +echo "Latest Release Found: $latest_release" +echo "Downloading: $downloaded_filename" +wget $download_link +sudo dpkg -i $downloaded_filename diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..0178ae5 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,32 @@ +name: Build document + +on: + push: + branches: + - main + workflow_dispatch: + +concurrency: + group: "pages" + cancel-in-progress: false + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Install requirements + run: | + wget https://github.com/jgm/pandoc/releases/download/3.1.12.2/pandoc-3.1.12.2-1-amd64.deb + sudo dpkg -i pandoc-3.1.12.2-1-amd64.deb + mkdir ~/.fonts + cp ./typst/fonts/*.otf ~/.fonts/ + - uses: typst-community/setup-typst@v3 + - name: Build using pandoc and typst + run: | + sh ./build.sh + - name: Upload artifact + uses: actions/upload-artifact@v4 + with: + name: build-pdf + path: main.pdf diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1d978e7 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +.deb +.DS_Store +typst/README.typ +*.pdf diff --git a/build.sh b/build.sh new file mode 100644 index 0000000..f60bfd7 --- /dev/null +++ b/build.sh @@ -0,0 +1,2 @@ +pandoc --from=markdown --to=typst -o typst/README.typ README.md +typst compile typst/main.typ ./main.pdf diff --git a/typst/README.md b/typst/README.md new file mode 100644 index 0000000..2a9502f --- /dev/null +++ b/typst/README.md @@ -0,0 +1,11 @@ +# ./typst + +Typst sources are built by [`/build.sh`](../build.sh) + +## Change Name of Lead Manager + +Adjust parameter `leadManager` in showing `_layout` at [`./main.typ`](./main.typ) + +## Requirements + - typst + - pandoc diff --git a/typst/fonts/NotoSerifKR-Black.otf b/typst/fonts/NotoSerifKR-Black.otf new file mode 100644 index 0000000..6d06537 Binary files /dev/null and b/typst/fonts/NotoSerifKR-Black.otf differ diff --git a/typst/fonts/NotoSerifKR-Bold.otf b/typst/fonts/NotoSerifKR-Bold.otf new file mode 100644 index 0000000..ab370eb Binary files /dev/null and b/typst/fonts/NotoSerifKR-Bold.otf differ diff --git a/typst/fonts/NotoSerifKR-ExtraLight.otf b/typst/fonts/NotoSerifKR-ExtraLight.otf new file mode 100644 index 0000000..3e1919b Binary files /dev/null and b/typst/fonts/NotoSerifKR-ExtraLight.otf differ diff --git a/typst/fonts/NotoSerifKR-Light.otf b/typst/fonts/NotoSerifKR-Light.otf new file mode 100644 index 0000000..1f8b6ff Binary files /dev/null and b/typst/fonts/NotoSerifKR-Light.otf differ diff --git a/typst/fonts/NotoSerifKR-Medium.otf b/typst/fonts/NotoSerifKR-Medium.otf new file mode 100644 index 0000000..02afbc8 Binary files /dev/null and b/typst/fonts/NotoSerifKR-Medium.otf differ diff --git a/typst/fonts/NotoSerifKR-OFL.txt b/typst/fonts/NotoSerifKR-OFL.txt new file mode 100644 index 0000000..0cd9ea5 --- /dev/null +++ b/typst/fonts/NotoSerifKR-OFL.txt @@ -0,0 +1,93 @@ +Copyright 2012 Google Inc. All Rights Reserved. + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +https://openfontlicense.org + + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/typst/fonts/NotoSerifKR-Regular.otf b/typst/fonts/NotoSerifKR-Regular.otf new file mode 100644 index 0000000..2f9cca4 Binary files /dev/null and b/typst/fonts/NotoSerifKR-Regular.otf differ diff --git a/typst/fonts/NotoSerifKR-SemiBold.otf b/typst/fonts/NotoSerifKR-SemiBold.otf new file mode 100644 index 0000000..013d30d Binary files /dev/null and b/typst/fonts/NotoSerifKR-SemiBold.otf differ diff --git a/typst/fonts/RIDIBatang-OFL b/typst/fonts/RIDIBatang-OFL new file mode 100644 index 0000000..8bcbd83 --- /dev/null +++ b/typst/fonts/RIDIBatang-OFL @@ -0,0 +1,7 @@ +https://ridicorp.com/ridibatang/ + +라이선스 안내 +리디바탕 글꼴은 개인 및 기업 사용자를 포함한 모든 사용자에게 무료로 제공되며 자유롭게 수정하고 재배포하실 수 있습니다. 단, 글꼴 자체를 유료로 판매하는 것은 금지하며, 리디바탕 글꼴은 본 저작권 안내와 라이선스 전문을 포함해서 다른 소프트웨어와 번들하거나 재배포 또는 판매가 가능합니다. 라이선스 전문을 포함하기 어려울 경우, 리디바탕 글꼴의 출처 표기를 권장합니다. 예) 이 페이지는 리디주식회사에서 제공한 리디바탕 글꼴이 사용되어 있습니다. + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +리디바탕의 저작권은 리디주식회사가 소유하고 있습니다. diff --git a/typst/fonts/RIDIBatang.otf b/typst/fonts/RIDIBatang.otf new file mode 100644 index 0000000..a213e49 Binary files /dev/null and b/typst/fonts/RIDIBatang.otf differ diff --git a/typst/main.typ b/typst/main.typ new file mode 100644 index 0000000..7efdaad --- /dev/null +++ b/typst/main.typ @@ -0,0 +1,12 @@ +#import "template.typ": * + +#show: _layout.with( + title: "종교에 관한 서약서", + authors: ( + "전남대학교 게임개발동아리 PIMM", + ), + leadManager: "박종현" +) + +#include "README.typ" + diff --git a/typst/template.typ b/typst/template.typ new file mode 100644 index 0000000..d312e03 --- /dev/null +++ b/typst/template.typ @@ -0,0 +1,83 @@ +#let _layout(title: "", authors: (), leadManager: "", body) = { + set document(author: authors, title: title) + set page("a4", margin: (top: 3em, bottom: 2em, left: 4em, right: 4em), /*numbering: "1",*/ number-align: center) + set text(font: ( + "Noto Serif CJK KR", + "Noto Serif KR", + "RIDIBatang" + ), lang: "ko") + set heading(numbering: (..nums) => { + let level = nums.pos().len() + let pattern = if level > 1 { + "1.1.1." + } + if pattern != none { + numbering(pattern, ..(nums.pos().slice(1, level))) + } + }) + set enum(numbering: "a.1.", indent: 10pt) + set text(size: 9.7pt) + + align(center)[ + #block(text(weight: 700, 1.75em, title)) + ] + + pad( + top: 0.3em, + bottom: 0.3em, + x: 2em, + grid( + columns: (1fr,) * calc.min(3, authors.len()), + gutter: 1em, + ..authors.map(author => align(center, strong(author))), + ), + ) + + set par(justify: true) + + body + + + v(20pt) + + set align(center) + text(1em)[ + 20 + #underline[ㅤㅤ] + 년 + #underline[ㅤㅤ] + 월 + #underline[ㅤㅤ] + 일 + ] + + set align(left) + + grid( + columns: (1.5fr, 1fr, 1fr), + gutter: 1em, + align(right)[ + 서명자의 종교: #underline()[ㅤㅤㅤㅤㅤㅤㅤㅤㅤ] + ], + [], + [], + align(right)[ + 전남대학교 게임개발동아리 PIMM + ], + align(left)[ + 대표자, #leadManager + ], + align(left)[ + (인) + ], + align(right)[ + 전남대학교 게임개발동아리 PIMM + ], + align(left)[ + 서명자, #underline[ㅤㅤㅤㅤ] + ], + align(left)[ + (인) + ] + ) +}