Skip to content

Commit

Permalink
change hugo theme to doks
Browse files Browse the repository at this point in the history
  • Loading branch information
l10178 committed Dec 16, 2023
1 parent 06b366b commit d43baef
Show file tree
Hide file tree
Showing 213 changed files with 8,545 additions and 59,762 deletions.
11 changes: 11 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# editorconfig.org

root = true

[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
assets/js/vendor
node_modules
31 changes: 31 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"env": {
"browser": true,
"commonjs": true,
"es6": true,
"node": true
},
"extends": "eslint:recommended",
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parserOptions": {
"ecmaVersion": 2018,
"sourceType": "module"
},
"rules": {
"no-console": 0,
"quotes": ["error", "single"],
"comma-dangle": [
"error",
{
"arrays": "always-multiline",
"objects": "always-multiline",
"imports": "always-multiline",
"exports": "always-multiline",
"functions": "ignore"
}
]
}
}
56 changes: 0 additions & 56 deletions .github/workflows/docker-nightly.yml

This file was deleted.

68 changes: 0 additions & 68 deletions .github/workflows/docker-release.yml

This file was deleted.

40 changes: 23 additions & 17 deletions .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,35 @@
name: github pages
name: deploy github pages

on:
workflow_dispatch:
push:
branches:
- main # Set a branch name to trigger deployment
- main

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true # Fetch Hugo themes (true OR recursive)
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
- name: Checkout
uses: actions/checkout@v3

- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 18

- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: '0.80.0'
- name: Install dependencies
run: npm ci

- name: Build
run: hugo --minify --baseURL https://l10178.github.io/
- name: Run linters
run: npm run lint --if-present

- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./public
- name: Build site
run: npm run build

- name: Deploy github pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./public
cname: www.nxest.com
26 changes: 11 additions & 15 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,17 +1,13 @@
######################
## Hugo
#######################
public/
.eslintcache
.stylelintcache
.netlify
.hugo_build.lock
yarn-error.log
node_modules/
public
resources
pnpm-lock.yaml

######################
## Intellij
#######################
.idea/
*.iml

#######################
## Visual Studio Code
#######################
.vscode/
.gradle/
.idea
.vscode
.impl
14 changes: 14 additions & 0 deletions .markdownlint-cli2.jsonc
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"config": {
"default": true,
"MD013": false,
"MD022": false,
"MD024": false,
"MD025": false,
"MD026": false,
"MD033": false,
"MD034": false,
"MD036": false
},
"ignores": ["node_modules", "CHANGELOG.md", "README.md"]
}
6 changes: 6 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
node_modules
public
resources
.netlify
.hugo_build.lock
yarn-error.log
4 changes: 4 additions & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
enable-pre-post-scripts = true
auto-install-peers = true
node-linker = hoisted
prefer-symlinked-executables = false
2 changes: 2 additions & 0 deletions .stylelintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
assets/scss/vendor
node_modules
37 changes: 37 additions & 0 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{
"extends": "stylelint-config-standard-scss",
"rules": {
"no-empty-source": null,
"string-quotes": "double",
"scss/comment-no-empty": null,
"max-line-length": null,
"scss/at-extend-no-missing-placeholder": null,
"at-rule-no-unknown": [
true,
{
"ignoreAtRules": [
"extend",
"at-root",
"debug",
"warn",
"error",
"if",
"else",
"for",
"each",
"while",
"mixin",
"include",
"content",
"return",
"function",
"tailwind",
"apply",
"responsive",
"variants",
"screen"
]
}
]
}
}
2 changes: 0 additions & 2 deletions Dockerfile

This file was deleted.

35 changes: 34 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,38 @@
# l10178.github.io

This is the source of nxest.com.
This is the source of [nxest.com][].

基于 Hugo 搭建的个人网站。

## 本地开发

本项目使用 [Hugo](https://gohugo.io/) 开发,使用 [Doks](https://github.com/gethyas/doks) 作为 Hugo 主题。

本地开发时先安装 Nodejs,然后使用 pnpm(或 npm) 安装 Hugo bin,本地不需要提前安装 Hugo。

```bash

# 安装 npm 依赖包,注意网络连接
pnpm install

# 启动 Web,然后浏览器访问 http://localhost:1313/即可浏览效果
pnpm run dev

# 代码提交前先检查
pnpm run lint

# 编译结果
pnpm run build

# 创建新页面
pnpm run create docs/guides/faq.md
pnpm run create blog/k8s.md

```

## License

本文档采用 [CC BY-NC 4.0][] 许可协议。

[nxest.com]: https://www.nxest.com
[CC BY-NC 4.0]: https://creativecommons.org/licenses/by-nc/4.0/
6 changes: 0 additions & 6 deletions archetypes/default.md

This file was deleted.

Binary file added assets/cover.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 assets/favicon-512x512.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 assets/favicon.ico
Binary file not shown.
Binary file added assets/favicon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions assets/favicon.svg
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 assets/logo-large.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions assets/mask-icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions assets/scss/_styles_project.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@

// disable docs links, see https://www.docsy.dev/docs/adding-content/repository-links/
// .td-page-meta--view { display: none !important; }
// .td-page-meta--edit { display: none !important; }
// .td-page-meta--child { display: none !important; }
// .td-page-meta--issue { display: none !important; }
// .td-page-meta--project-issue { display: none !important; }
Loading

0 comments on commit d43baef

Please sign in to comment.