-
-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
79 additions
and
86 deletions.
There are no files selected for viewing
This file contains 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,41 @@ | ||
name: Pages | ||
|
||
on: | ||
push: | ||
branches: [master] | ||
|
||
concurrency: | ||
group: pages | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
pages: | ||
environment: | ||
name: github-pages | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
permissions: | ||
pages: write | ||
id-token: write | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Setup Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: "3.x" | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install pip --upgrade | ||
python -m pip install -r requirements.txt | ||
- name: Build | ||
run: python -m tools.build_www | ||
- name: Setup Pages | ||
uses: actions/configure-pages@v5 | ||
- name: Upload artifact | ||
uses: actions/upload-pages-artifact@v3 | ||
with: | ||
path: ./build/outputs | ||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v4 |
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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 |
---|---|---|
|
@@ -7,5 +7,4 @@ PyYAML==6.0.1 | |
pillow==10.3.0 | ||
beautifulsoup4==4.12.3 | ||
Jinja2==3.1.4 | ||
GitPython==3.1.43 | ||
httpx==0.27.0 |
This file contains 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,38 @@ | ||
from tools import configs | ||
from tools.configs import path_define | ||
from tools.configs.dump import DumpConfig | ||
from tools.configs.fallback import FallbackConfig | ||
from tools.configs.font import FontConfig | ||
from tools.services import update_service, dump_service, template_service | ||
from tools.services.font_service import DesignContext, FontContext | ||
|
||
|
||
def main(): | ||
update_service.setup_ark_pixel_glyphs() | ||
|
||
font_configs = FontConfig.load_all() | ||
dump_configs = DumpConfig.load_all() | ||
fallback_configs = FallbackConfig.load_all() | ||
|
||
for font_size, font_config in font_configs.items(): | ||
for dump_config in dump_configs[font_size]: | ||
dump_service.dump_font(dump_config) | ||
|
||
for fallback_config in fallback_configs[font_size]: | ||
dump_service.apply_fallback(fallback_config) | ||
|
||
design_context = DesignContext.load(font_config, path_define.patch_glyphs_dir) | ||
design_context.standardized() | ||
design_context.fallback(DesignContext.load(font_config, path_define.ark_pixel_glyphs_dir)) | ||
design_context.fallback(DesignContext.load(font_config, path_define.fallback_glyphs_dir)) | ||
for width_mode in configs.width_modes: | ||
font_context = FontContext(design_context, width_mode) | ||
font_context.make_fonts('woff2') | ||
template_service.make_alphabet_html(design_context, width_mode) | ||
template_service.make_demo_html(design_context) | ||
template_service.make_index_html(font_configs) | ||
template_service.make_playground_html(font_configs) | ||
|
||
|
||
if __name__ == '__main__': | ||
main() |
This file contains 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 |
---|---|---|
@@ -1,4 +1,3 @@ | ||
from tools.configs.deploy import GitDeployConfig | ||
from tools.configs.source import GithubSourceConfig, GitSourceType | ||
|
||
font_version = '2024.05.12' | ||
|
@@ -64,9 +63,3 @@ | |
source_type=GitSourceType.TAG, | ||
source_name=None, | ||
) | ||
|
||
git_deploy_configs = [GitDeployConfig( | ||
url='[email protected]:TakWolf/fusion-pixel-font.git', | ||
remote_name='github', | ||
branch_name='gh-pages', | ||
)] |
This file was deleted.
Oops, something went wrong.
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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