Skip to content

Commit

Permalink
Let's start from here
Browse files Browse the repository at this point in the history
  • Loading branch information
taiansu committed Jan 3, 2025
1 parent 0540d9f commit 6d55e86
Show file tree
Hide file tree
Showing 94 changed files with 9,759 additions and 3 deletions.
11 changes: 8 additions & 3 deletions .github/workflows/hugo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,19 @@ jobs:
- name: Install Hugo CLI
run: |
wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \
&& sudo dpkg -i ${{ runner.temp }}/hugo.deb
&& sudo dpkg -i ${{ runner.temp }}/hugo.deb
- name: Install Dart Sass
run: sudo snap install dart-sass
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Replace secrects
run: |
sed -i "s/\${GOOGLE_ANALYTICS_ID}/${{ secrets.GOOGLE_ANALYTICS_ID}}/g" hugo.toml
sed -i "s/\${GISCUS_REPO_ID}/${{ secrets.GISCUS_REPO_ID }}/g" hugo.toml
sed -i "s/\${GISCUS_CATEGORY_ID}/${{ secrets.GISCUS_CATEGORY_ID }}/g" hugo.toml
- name: Setup Pages
id: pages
uses: actions/configure-pages@v5
Expand All @@ -54,12 +59,12 @@ jobs:
env:
HUGO_CACHEDIR: ${{ runner.temp }}/hugo_cache
HUGO_ENVIRONMENT: production
TZ: America/Los_Angeles
TZ: Asia/Taipei
run: |
hugo \
--gc \
--minify \
--baseURL "${{ steps.pages.outputs.base_url }}/"
--baseURL "${{ steps.pages.outputs.base_url }}/"
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "themes/typo"]
path = themes/typo
url = https://github.com/tomfran/typo.git
Empty file added .hugo_build.lock
Empty file.
5 changes: 5 additions & 0 deletions archetypes/default.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
+++
date = '{{ .Date }}'
draft = true
title = '{{ replace .File.ContentBaseName "-" " " | title }}'
+++
82 changes: 82 additions & 0 deletions hugo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
baseURL = 'https://elixir.tw/'
languageCode = 'zh-tw'
title = 'Elixir Taiwan Blog'

[taxonomies]
tag = 'tags'

# Google analytics code
googleAnalytics = "${GOOGLE_ANALYTICS_ID}"

[params]
# Meta description
description = "A Tech Blog of Elixir Taiwan"

# Appearance settings
theme = 'typo'
colorPalette = 'default'
hideHeader = false

# Intro on main page, content is markdown
homeIntroTitle = '歡迎!'
homeIntroContent = """
這裡是 Elixir Taiwan 的部落格。我們自 2014 開始在台北舉辦每個月定期的實體聚會,目前依然持續運作中,聚會詳情請參考我們的 facebook/discord/meetup 連結。在這裡我們會分享各種程式相關的新聞、知識與新議題。
"""

# Collection to display on home
homeCollectionTitle = 'Posts'
homeCollection = 'posts'

# Lists parameters
paginationSize = 100
listSummaries = true
listDateFormat = 'Jan 2 2024'

# Breadcrumbs
breadcrumbs = true

# Social icons
[[params.social]]
name = "facebook"
url = "https://www.facebook.com/groups/elixir.tw"

[[params.social]]
name = "X"
url = "https://x.com/elixirtw"

[[params.social]]
name = "Discord"
url = "https://discord.com/invite/9zBmPfrrVP"

[[params.social]]
name = "Meetup"
url = "https://www.meetup.com/elixirtw-taipei"

# Main menu pages
[[params.menu]]
name = "home"
url = "/"

[[params.menu]]
name = "posts"
url = "/posts"

[[params.menu]]
name = "about"
url = "/about"

# Syntax highligth on code blocks
[markup]
[markup.highlight]
style = 'algol'

# Giscus comments
[params.giscus]
enable = false
repo = "elixirtw/elixirtw.github.io"
repoid = "${GISCUS_REPO_ID}"
category = "Announcements"
categoryid = "${GISCUS_CATEGORY_ID}"
mapping = "pathname"
theme = "preferred_color_scheme"
datalang = "zh-TW"
178 changes: 178 additions & 0 deletions public/404.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,178 @@
<!DOCTYPE html>
<html lang="zh-tw"
dir="ltr">

<head><script src="/livereload.js?mindelay=10&amp;v=2&amp;port=1313&amp;path=livereload" data-no-instant defer></script>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">



<link rel="icon" type="image/ico" href="http://localhost:1313//favicon.ico">
<link rel="icon" type="image/png" sizes="16x16" href="http://localhost:1313//favicon-16x16.png">
<link rel="icon" type="image/png" sizes="32x32" href="http://localhost:1313//favicon-32x32.png">
<link rel="icon" type="image/png" sizes="192x192" href="http://localhost:1313//android-chrome-192x192.png">
<link rel="apple-touch-icon" sizes="180x180" href="http://localhost:1313//apple-touch-icon.png">

<meta name="description" content=""/>

<title>

404 Page not found | Elixir Taiwan Blog

</title>

<link rel="canonical" href="http://localhost:1313/404.html"/>

<meta property="og:url" content="http://localhost:1313/404.html">
<meta property="og:site_name" content="Elixir Taiwan Blog">
<meta property="og:title" content="404 Page not found">
<meta property="og:description" content="A Tech Blog of Elixir Taiwan">
<meta property="og:locale" content="zh_tw">
<meta property="og:type" content="website">













<link rel="stylesheet" href="/assets/combined.min.186794b3399a702d3092949042cdc215dea303c17e71e7c0254768448de11db8.css" media="all">





</head>







<body class="auto">

<div class="content">
<header>


<div class="header">



<h1 class="header-title">
<a href="http://localhost:1313/">Elixir Taiwan Blog</a>
</h1>

<div class="flex">





<p class="small ">
<a href="/" >
/home
</a>
</p>


<p class="small ">
<a href="/posts" >
/posts
</a>
</p>


<p class="small ">
<a href="/about" >
/about
</a>
</p>


</div>



</div>

</header>

<main class="main">


<div class="not-found">

<div>
<h1> typo? </h1>
<p> Click <a href="/"> here </a> to return to home </p>
</div>

</div>


</main>
</div>

<footer>



<p>Powered by
<a href="https://gohugo.io/">Hugo</a>
and
<a href="https://github.com/tomfran/typo">tomfran/typo</a>
</p>





</footer>



</body>

<script>

function isAuto() {
return document.body.classList.contains("auto");
}

function setTheme() {
if (!isAuto()) {
return
}

document.body.classList.remove("auto");
let cls = "light";
if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) {
cls = "dark";
}

document.body.classList.add(cls);
}

function invertBody() {
document.body.classList.toggle("dark");
document.body.classList.toggle("light");
}

if (isAuto()) {
window.matchMedia('(prefers-color-scheme: dark)').addListener(invertBody);
}

setTheme();

</script>

</html>
Binary file added public/android-chrome-192x192.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/apple-touch-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file added public/favicon-16x16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/favicon-32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/favicon.ico
Binary file not shown.
Binary file added public/fonts/Literata/Literata-Light.woff2
Binary file not shown.
Binary file added public/fonts/Literata/Literata-LightItalic.woff2
Binary file not shown.
Binary file added public/fonts/Literata/Literata-SemiBold.woff2
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading

0 comments on commit 6d55e86

Please sign in to comment.