mirror of
https://github.com/cotes2020/jekyll-theme-chirpy.git
synced 2025-06-08 08:37:53 +00:00
Compare commits
7 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
3c186dc32e | ||
![]() |
0126ab6d0b | ||
![]() |
ca8e85a7ec | ||
![]() |
a9b159299b | ||
![]() |
29ba2666ce | ||
![]() |
5ef1478148 | ||
![]() |
8877393fba |
4
.github/CONTRIBUTING.md
vendored
4
.github/CONTRIBUTING.md
vendored
@ -1,6 +1,6 @@
|
|||||||
# How to Contribute
|
# How to Contribute
|
||||||
|
|
||||||
I want to thank you for sparing a time to improve this project! Here are some guidelines for contributing:
|
I want to thank you for sparing time to improve this project! Here are some guidelines for contributing:
|
||||||
|
|
||||||
To ensure that the blog design is not confused, this project does not accept suggestions for design changes, such as color scheme, fonts, typography, etc. If your request is about an enhancement, it is recommended to first submit a [`Feature Request`](https://github.com/cotes2020/jekyll-theme-chirpy/issues/new?labels=enhancement&template=feature_request.md) issue to discuss whether your idea fits the project.
|
To ensure that the blog design is not confused, this project does not accept suggestions for design changes, such as color scheme, fonts, typography, etc. If your request is about an enhancement, it is recommended to first submit a [`Feature Request`](https://github.com/cotes2020/jekyll-theme-chirpy/issues/new?labels=enhancement&template=feature_request.md) issue to discuss whether your idea fits the project.
|
||||||
|
|
||||||
@ -13,4 +13,4 @@ Generally, contribute to the project by:
|
|||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
:tada: Your volunteering will make the open source world more beautiful, thanks again! :tada:
|
:tada: Your volunteering will make the open-source world more beautiful, thanks again! :tada:
|
||||||
|
4
.github/ISSUE_TEMPLATE/bug_report.md
vendored
4
.github/ISSUE_TEMPLATE/bug_report.md
vendored
@ -6,10 +6,10 @@ about: Create a report to help us improve
|
|||||||
<!-- NOTE: Please maintain all sections, otherwise the issue will be automatically closed :) -->
|
<!-- NOTE: Please maintain all sections, otherwise the issue will be automatically closed :) -->
|
||||||
|
|
||||||
## Checklist
|
## Checklist
|
||||||
<!-- Please complete the following list of tasks, and then check it by change the "[ ]" to "[x]" -->
|
<!-- Please complete the following list of tasks, and then check it by changing the "[ ]" to "[x]" -->
|
||||||
- [ ] I have read the [tutorials](https://chirpy.cotes.info/categories/tutorial/) and know the correct effect of the functional design.
|
- [ ] I have read the [tutorials](https://chirpy.cotes.info/categories/tutorial/) and know the correct effect of the functional design.
|
||||||
- [ ] There are no similar reports on existing issues (including closed ones).
|
- [ ] There are no similar reports on existing issues (including closed ones).
|
||||||
- [ ] I found the bug on the latest code of `master` branch.
|
- [ ] I found the bug on the latest code of the `master` branch.
|
||||||
|
|
||||||
## Describe the bug
|
## Describe the bug
|
||||||
<!-- A clear and concise description of what the bug is. -->
|
<!-- A clear and concise description of what the bug is. -->
|
||||||
|
4
.github/ISSUE_TEMPLATE/feature_request.md
vendored
4
.github/ISSUE_TEMPLATE/feature_request.md
vendored
@ -7,9 +7,9 @@ labels: enhancement
|
|||||||
<!-- NOTE: Please maintain all sections, otherwise the issue will be automatically closed :) -->
|
<!-- NOTE: Please maintain all sections, otherwise the issue will be automatically closed :) -->
|
||||||
|
|
||||||
## Checklist
|
## Checklist
|
||||||
<!-- Please complete the following list of tasks, and then check it by change the "[ ]" to "[x]" -->
|
<!-- Please complete the following list of tasks, and then check it by changing the "[ ]" to "[x]" -->
|
||||||
- [ ] I have read the [contributing guidelines](https://github.com/cotes2020/jekyll-theme-chirpy/blob/master/.github/CONTRIBUTING.md).
|
- [ ] I have read the [contributing guidelines](https://github.com/cotes2020/jekyll-theme-chirpy/blob/master/.github/CONTRIBUTING.md).
|
||||||
- [ ] There are no similar request on existing issues (including closed ones).
|
- [ ] There is no similar request on existing issues (including closed ones).
|
||||||
- [ ] I have read the [project progress](https://github.com/cotes2020/jekyll-theme-chirpy/projects) and know the current progress of the project.
|
- [ ] I have read the [project progress](https://github.com/cotes2020/jekyll-theme-chirpy/projects) and know the current progress of the project.
|
||||||
- [ ] I was in the `master` branch of the latest code.
|
- [ ] I was in the `master` branch of the latest code.
|
||||||
|
|
||||||
|
8
.github/ISSUE_TEMPLATE/question.md
vendored
8
.github/ISSUE_TEMPLATE/question.md
vendored
@ -8,12 +8,12 @@ labels: question
|
|||||||
|
|
||||||
## Checklist
|
## Checklist
|
||||||
|
|
||||||
<!-- Please complete the following list of tasks, and then check it by change the "[ ]" to "[x]" -->
|
<!-- Please complete the following list of tasks, and then check it by changing the "[ ]" to "[x]" -->
|
||||||
|
|
||||||
- [ ] I have read the [tutorials](https://chirpy.cotes.info/categories/tutorial/) and know the correct effect of the functional design.
|
- [ ] I have read the [tutorials](https://chirpy.cotes.info/categories/tutorial/) and know the correct effect of the functional design.
|
||||||
- [ ] There are no similar question on existing issues (including closed ones).
|
- [ ] There is no similar question on existing issues (including closed ones).
|
||||||
- [ ] I searched the Internet for related problems, but still couldn't solve it.
|
- [ ] I searched the Internet for related problems, but still couldn't solve them.
|
||||||
- [ ] My question is based on the latest code of `master` branch.
|
- [ ] My question is based on the latest code of the `master` branch.
|
||||||
|
|
||||||
## Description
|
## Description
|
||||||
<!-- Please describe your question in detail. -->
|
<!-- Please describe your question in detail. -->
|
||||||
|
2
.github/PULL_REQUEST_TEMPLATE.md
vendored
2
.github/PULL_REQUEST_TEMPLATE.md
vendored
@ -37,7 +37,7 @@ Please describe the tests that you ran to verify your changes. Provide instructi
|
|||||||
<!-- Select checkboxes by change the "[ ]" to "[x]" -->
|
<!-- Select checkboxes by change the "[ ]" to "[x]" -->
|
||||||
- [ ] My code follows the [Google style guidelines](https://google.github.io/styleguide/)
|
- [ ] My code follows the [Google style guidelines](https://google.github.io/styleguide/)
|
||||||
- [ ] I have performed a self-review of my own code
|
- [ ] I have performed a self-review of my own code
|
||||||
- [ ] I have commented my code, particularly in hard-to-understand areas
|
- [ ] I have commented on my code, particularly in hard-to-understand areas
|
||||||
- [ ] I have made corresponding changes to the documentation
|
- [ ] I have made corresponding changes to the documentation
|
||||||
- [ ] My changes generate no new warnings
|
- [ ] My changes generate no new warnings
|
||||||
- [ ] I have added tests that prove my fix is effective or that my feature works
|
- [ ] I have added tests that prove my fix is effective or that my feature works
|
||||||
|
@ -3,7 +3,9 @@ dist: bionic
|
|||||||
|
|
||||||
language: minimal
|
language: minimal
|
||||||
|
|
||||||
if: tag =~ /^v(\d)+(\.(\d)+){2}$/
|
branches:
|
||||||
|
only:
|
||||||
|
- /^release\/(\d)+(\.(\d)+){1}$/
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
include:
|
include:
|
||||||
|
40
README.md
40
README.md
@ -1,7 +1,6 @@
|
|||||||
<div align="right">
|
<div align="right">
|
||||||
|
|
||||||
EN /
|
EN / [中文](https://github.com/cotes2020/jekyll-theme-chirpy/blob/master/docs/README.zh-CN.md)
|
||||||
[中文(简体)](https://github.com/cotes2020/jekyll-theme-chirpy/blob/master/docs/README.zh-CN.md)
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -9,15 +8,15 @@
|
|||||||
|
|
||||||
# Chirpy Jekyll Theme
|
# Chirpy Jekyll Theme
|
||||||
|
|
||||||
|
A minimal, responsive, and powerful Jekyll theme for presenting professional writing.
|
||||||
|
|
||||||
[](https://rubygems.org/gems/jekyll-theme-chirpy)
|
[](https://rubygems.org/gems/jekyll-theme-chirpy)
|
||||||
[](https://github.com/cotes2020/jekyll-theme-chirpy/actions?query=branch%3Amaster+event%3Apush)
|
[](https://github.com/cotes2020/jekyll-theme-chirpy/actions?query=branch%3Amaster+event%3Apush)
|
||||||
[](https://app.codacy.com/manual/cotes2020/jekyll-theme-chirpy?utm_source=github.com&utm_medium=referral&utm_content=cotes2020/jekyll-theme-chirpy&utm_campaign=Badge_Grade_Dashboard)
|
[](https://www.codacy.com/gh/cotes2020/jekyll-theme-chirpy/dashboard?utm_source=github.com&utm_medium=referral&utm_content=cotes2020/jekyll-theme-chirpy&utm_campaign=Badge_Grade)
|
||||||
[](https://github.com/cotes2020/jekyll-theme-chirpy/blob/master/LICENSE)
|
[](https://github.com/cotes2020/jekyll-theme-chirpy/blob/master/LICENSE)
|
||||||
[](https://996.icu)
|
[](https://996.icu)
|
||||||
|
|
||||||
A minimal, responsive, and powerful Jekyll theme for presenting professional writing.
|
[**Live Demo →**](https://chirpy.cotes.info)
|
||||||
|
|
||||||
**[Live Demo →](https://chirpy.cotes.info)**
|
|
||||||
|
|
||||||
[](https://chirpy.cotes.info)
|
[](https://chirpy.cotes.info)
|
||||||
|
|
||||||
@ -44,7 +43,7 @@
|
|||||||
|
|
||||||
## Prerequisites
|
## Prerequisites
|
||||||
|
|
||||||
Follow the instructions in the [Jekyll Docs](https://jekyllrb.com/docs/installation/) to complete the installation of `Ruby`, `RubyGems`, `Jekyll` and `Bundler`.
|
Follow the instructions in the [Jekyll Docs](https://jekyllrb.com/docs/installation/) to complete the installation of `Ruby`, `RubyGems`, `Jekyll`, and `Bundler`.
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
@ -52,9 +51,8 @@ Follow the instructions in the [Jekyll Docs](https://jekyllrb.com/docs/installat
|
|||||||
|
|
||||||
There are two ways to create a new repository for this theme:
|
There are two ways to create a new repository for this theme:
|
||||||
|
|
||||||
- **[Using the Chirpy Starter](#option-1-using-the-chirpy-starter)** - Easy to upgrade, isolates irrelevant project files so you can focus on writing.
|
- [**Using the Chirpy Starter**](#option-1-using-the-chirpy-starter) - Easy to upgrade, isolates irrelevant project files so you can focus on writing.
|
||||||
|
- [**Forking on GitHub**](#option-2-forking-on-github) - Convenient for custom development, but difficult to upgrade. Unless you are familiar with Jekyll and are determined to tweak or contribute to this project, this approach is not recommended.
|
||||||
- **[Forking on GitHub](#option-2-forking-on-github)** - Convenient for custom development, but difficult to upgrade. Unless you are familiar with Jekyll and are determined to tweak or contribute to this project, this approach is not recommended.
|
|
||||||
|
|
||||||
#### Option 1. Using the Chirpy Starter
|
#### Option 1. Using the Chirpy Starter
|
||||||
|
|
||||||
@ -62,7 +60,7 @@ Create a new repository from the [**Chirpy Starter**][use-starter] and name it `
|
|||||||
|
|
||||||
#### Option 2. Forking on GitHub
|
#### Option 2. Forking on GitHub
|
||||||
|
|
||||||
[Fork **Chirpy**](https://github.com/cotes2020/jekyll-theme-chirpy/fork) on GitHub and rename it to `<GH_USERNAME>.github.io`. Please note that the default branch code is in development. If you want the site to be stable, please switch to the [latest tag](https://github.com/cotes2020/jekyll-theme-chirpy/tags) and start writing.
|
[Fork **Chirpy**](https://github.com/cotes2020/jekyll-theme-chirpy/fork) on GitHub and rename it to `<GH_USERNAME>.github.io`. Please note that the default branch code is in development. If you want the site to be stable, please switch to the [latest tag][latest-tag] and start writing.
|
||||||
|
|
||||||
And then execute:
|
And then execute:
|
||||||
|
|
||||||
@ -75,11 +73,12 @@ $ bash tools/init.sh
|
|||||||
The above command will:
|
The above command will:
|
||||||
|
|
||||||
1. Removes some files or directories from your repository:
|
1. Removes some files or directories from your repository:
|
||||||
|
|
||||||
- `.travis.yml`
|
- `.travis.yml`
|
||||||
- files under `_posts`
|
- files under `_posts`
|
||||||
- folder `docs`
|
- folder `docs`
|
||||||
|
|
||||||
2. If the option `--no-gh` is provided, the directory `.github` will be deleted. Otherwise, setup the GitHub Action workflow by removing the extension `.hook` of `.github/workflows/pages-deploy.yml.hook`, and then remove the other files and directories in the folder `.github`.
|
2. If the option `--no-gh` is provided, the directory `.github` will be deleted. Otherwise, set up the GitHub Action workflow by removing the extension `.hook` of `.github/workflows/pages-deploy.yml.hook`, and then remove the other files and directories in the folder `.github`.
|
||||||
|
|
||||||
3. Removes item `Gemfile.lock` from `.gitignore`.
|
3. Removes item `Gemfile.lock` from `.gitignore`.
|
||||||
|
|
||||||
@ -87,7 +86,7 @@ The above command will:
|
|||||||
|
|
||||||
### Installing Dependencies
|
### Installing Dependencies
|
||||||
|
|
||||||
Before running for the first time, go the root directory of your site, and install dependencies as follows:
|
Before running for the first time, go to the root directory of your site, and install dependencies as follows:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ bundle
|
$ bundle
|
||||||
@ -106,7 +105,7 @@ Update the variables of `_config.yml` as needed. Some of them are typical option
|
|||||||
|
|
||||||
### Customing Stylesheet
|
### Customing Stylesheet
|
||||||
|
|
||||||
If you need to customize stylesheet, copy the theme's `assets/css/style.scss` to the same path on your Jekyll site, and then add the custom style at the end of the style file.
|
If you need to customize the stylesheet, copy the theme's `assets/css/style.scss` to the same path on your Jekyll site, and then add the custom style at the end of the style file.
|
||||||
|
|
||||||
Starting from [`v4.1.0`][chirpy-4.1.0], if you want to overwrite the SASS variables defined in `_sass/addon/variables.scss`, create a new file `_sass/variables-hook.scss` and assign new values to the target variable in it.
|
Starting from [`v4.1.0`][chirpy-4.1.0], if you want to overwrite the SASS variables defined in `_sass/addon/variables.scss`, create a new file `_sass/variables-hook.scss` and assign new values to the target variable in it.
|
||||||
|
|
||||||
@ -131,7 +130,7 @@ After a while, the local service will be published at _<http://127.0.0.1:4000>_.
|
|||||||
|
|
||||||
### Deployment
|
### Deployment
|
||||||
|
|
||||||
Before the deployment begins, checkout the file `_config.yml` and make sure the `url` is configured correctly. Furthermore, if you prefer the [**project site**](https://help.github.com/en/github/working-with-github-pages/about-github-pages#types-of-github-pages-sites) and don't use a custom domain, or you want to visit your website with a base URL on a web server other than **GitHub Pages**, remember to change the `baseurl` to your project name that starting with a slash, e.g, `/project-name`.
|
Before the deployment begins, check out the file `_config.yml` and make sure the `url` is configured correctly. Furthermore, if you prefer the [**project site**](https://help.github.com/en/github/working-with-github-pages/about-github-pages#types-of-github-pages-sites) and don't use a custom domain, or you want to visit your website with a base URL on a web server other than **GitHub Pages**, remember to change the `baseurl` to your project name that starts with a slash, e.g, `/project-name`.
|
||||||
|
|
||||||
Now you can choose ONE of the following methods to deploy your Jekyll site.
|
Now you can choose ONE of the following methods to deploy your Jekyll site.
|
||||||
|
|
||||||
@ -145,7 +144,7 @@ Quickly check the files needed for GitHub Actions build:
|
|||||||
|
|
||||||
- Ensure your Jekyll site has file `tools/deploy.sh`. Otherwise, copy it from here to your Jekyll site.
|
- Ensure your Jekyll site has file `tools/deploy.sh`. Otherwise, copy it from here to your Jekyll site.
|
||||||
|
|
||||||
- Furthermore, if you have committed `Gemfile.lock` to the repo, and your runtime system is not Linux, don't forget to update the platform list in the lockfile:
|
- Furthermore, if you have committed `Gemfile.lock` to the repo, and your runtime system is not Linux, don't forget to update the platform list in the lock file:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ bundle lock --add-platform x86_64-linux
|
$ bundle lock --add-platform x86_64-linux
|
||||||
@ -189,7 +188,8 @@ Unless you specified the output path, the generated site files will be placed in
|
|||||||
|
|
||||||
It depends on how you use the theme:
|
It depends on how you use the theme:
|
||||||
|
|
||||||
- If you are using the theme gem (there will be `gem "jekyll-theme-chirpy"` in the `Gemfile`), editing the `Gemfile` and update the version number of the them gem, for example:
|
- If you are using the theme gem (there will be `gem "jekyll-theme-chirpy"` in the `Gemfile`), editing the `Gemfile` and update the version number of the theme gem, for example:
|
||||||
|
|
||||||
```diff
|
```diff
|
||||||
- gem "jekyll-theme-chirpy", "~> 3.2", ">= 3.2.1"
|
- gem "jekyll-theme-chirpy", "~> 3.2", ">= 3.2.1"
|
||||||
+ gem "jekyll-theme-chirpy", "~> 3.3", ">= 3.3.0"
|
+ gem "jekyll-theme-chirpy", "~> 3.3", ">= 3.3.0"
|
||||||
@ -208,7 +208,7 @@ The merge is likely to conflict with your local modifications. Please be patient
|
|||||||
|
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
For more details and a better reading experience, please check out the [tutorials on the demo site](https://chirpy.cotes.info/categories/tutorial/). In the meanwhile, a copy of the tutorial is also available on the [Wiki](https://github.com/cotes2020/jekyll-theme-chirpy/wiki). Please note that the tutorials on the demo website or Wiki are based on the latest release, and the features of `master` branch usually ahead of the documentation.
|
For more details and a better reading experience, please check out the [tutorials on the demo site](https://chirpy.cotes.info/categories/tutorial/). In the meanwhile, a copy of the tutorial is also available on the [Wiki](https://github.com/cotes2020/jekyll-theme-chirpy/wiki). Please note that the tutorials on the demo website or Wiki are based on the latest release, and the features of `master` branch are usually ahead of the documentation.
|
||||||
|
|
||||||
## Contributing
|
## Contributing
|
||||||
|
|
||||||
@ -216,9 +216,9 @@ The old saying, "Two heads are better than one." Consequently, welcome to report
|
|||||||
|
|
||||||
## Credits
|
## Credits
|
||||||
|
|
||||||
This theme is mainly built with [Jekyll](https://jekyllrb.com/) ecosystem, [Bootstrap](https://getbootstrap.com/), [Font Awesome](https://fontawesome.com/) and some other wonderful tools (their copyright information can be found in the relevant files). The avatar and favicon design comes from [Clipart Max](https://www.clipartmax.com/middle/m2i8b1m2K9Z5m2K9_ant-clipart-childrens-ant-cute/).
|
This theme is mainly built with [Jekyll](https://jekyllrb.com/) ecosystem, [Bootstrap](https://getbootstrap.com/), [Font Awesome](https://fontawesome.com/) and some other wonderful tools (their copyright information can be found in the relevant files). The avatar and favicon design come from [Clipart Max](https://www.clipartmax.com/middle/m2i8b1m2K9Z5m2K9_ant-clipart-childrens-ant-cute/).
|
||||||
|
|
||||||
:tada: Thanks to all the volunteers who contributed to this project, their GitHub IDs are on [this list](https://github.com/cotes2020/jekyll-theme-chirpy/graphs/contributors). Also, I won't forget those guys who submitted the issues or unmerged PR because they reported bugs, shared ideas, or inspired me to write more readable documentation.
|
:tada: Thanks to all the volunteers who contributed to this project, their GitHub IDs are on [this list](https://github.com/cotes2020/jekyll-theme-chirpy/graphs/contributors). Also, I won't forget those guys who submitted the issues or unmerged PR because they reported bugs, shared ideas or inspired me to write more readable documentation.
|
||||||
|
|
||||||
Last but not least, thank [JetBrains][jb] for providing the open source license.
|
Last but not least, thank [JetBrains][jb] for providing the open source license.
|
||||||
|
|
||||||
|
@ -159,7 +159,7 @@ exclude:
|
|||||||
- LICENSE
|
- LICENSE
|
||||||
- gulpfile.js
|
- gulpfile.js
|
||||||
- node_modules
|
- node_modules
|
||||||
- '*.json'
|
- package*.json
|
||||||
|
|
||||||
jekyll-archives:
|
jekyll-archives:
|
||||||
enabled: [categories, tags]
|
enabled: [categories, tags]
|
||||||
|
@ -41,8 +41,6 @@
|
|||||||
{{ 'Perl' }}
|
{{ 'Perl' }}
|
||||||
{% when 'php','php3','php4','php5' %}
|
{% when 'php','php3','php4','php5' %}
|
||||||
{{ 'PHP' }}
|
{{ 'PHP' }}
|
||||||
{% when 'plaintext', 'text' %}
|
|
||||||
{{ 'Text' }}
|
|
||||||
{% when 'py' %}
|
{% when 'py' %}
|
||||||
{{ 'Python' }}
|
{{ 'Python' }}
|
||||||
{% when 'rb' %}
|
{% when 'rb' %}
|
||||||
@ -65,7 +63,7 @@
|
|||||||
{{ 'Vue.js' }}
|
{{ 'Vue.js' }}
|
||||||
{% when 'yml' %}
|
{% when 'yml' %}
|
||||||
{{ 'YAML' }}
|
{{ 'YAML' }}
|
||||||
{% when 'css', 'html', 'scss', 'ssh', 'toml', 'xml', 'yaml' %}
|
{% when 'css', 'html', 'scss', 'ssh', 'toml', 'xml', 'yaml', 'json' %}
|
||||||
{{ _lang | upcase }}
|
{{ _lang | upcase }}
|
||||||
{% else %}
|
{% else %}
|
||||||
{{ _lang | capitalize }}
|
{{ _lang | capitalize }}
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
{% capture result_elem %}
|
{% capture result_elem %}
|
||||||
<div class="pl-1 pr-1 pl-sm-2 pr-sm-2 pl-lg-4 pr-lg-4 pl-xl-0 pr-xl-0">
|
<div class="pl-1 pr-1 pl-sm-2 pr-sm-2 pl-lg-4 pr-lg-4 pl-xl-0 pr-xl-0">
|
||||||
<a href="{{ site.url }}{url}">{title}</a>
|
<a href="{url}">{title}</a>
|
||||||
<div class="post-meta d-flex flex-column flex-sm-row text-muted mt-1 mb-1">
|
<div class="post-meta d-flex flex-column flex-sm-row text-muted mt-1 mb-1">
|
||||||
{categories}
|
{categories}
|
||||||
{tags}
|
{tags}
|
||||||
|
@ -6,6 +6,7 @@
|
|||||||
<div class="profile-wrapper text-center">
|
<div class="profile-wrapper text-center">
|
||||||
<div id="avatar">
|
<div id="avatar">
|
||||||
<a href="{{ '/' | relative_url }}" alt="avatar" class="mx-auto">
|
<a href="{{ '/' | relative_url }}" alt="avatar" class="mx-auto">
|
||||||
|
{% if site.avatar != '' and site.avatar %}
|
||||||
{% capture avatar_url %}
|
{% capture avatar_url %}
|
||||||
{%- if site.avatar contains '://' -%}
|
{%- if site.avatar contains '://' -%}
|
||||||
{{ site.avatar }}
|
{{ site.avatar }}
|
||||||
@ -16,6 +17,7 @@
|
|||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
{% endcapture %}
|
{% endcapture %}
|
||||||
<img src="{{ avatar_url }}" alt="avatar" onerror="this.style.display='none'">
|
<img src="{{ avatar_url }}" alt="avatar" onerror="this.style.display='none'">
|
||||||
|
{% endif %}
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*!
|
/*!
|
||||||
* Chirpy v4.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
* Chirpy v4.3.4 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
||||||
* © 2019 Cotes Chung
|
* © 2019 Cotes Chung
|
||||||
* MIT Licensed
|
* MIT Licensed
|
||||||
*/
|
*/
|
||||||
|
@ -20,8 +20,8 @@ $(function() {
|
|||||||
|
|
||||||
const hash = decodeURI(this.hash);
|
const hash = decodeURI(this.hash);
|
||||||
let isFnRef = RegExp(/^#fnref:/).test(hash);
|
let isFnRef = RegExp(/^#fnref:/).test(hash);
|
||||||
let isFn = RegExp(/^#fn:/).test(hash);
|
let isFn = isFnRef? false : RegExp(/^#fn:/).test(hash);
|
||||||
let selector = hash.includes(":") ? hash.replace(/\:/, "\\:") : hash;
|
let selector = hash.includes(":") ? hash.replace(/\:/g, "\\:") : hash;
|
||||||
let target = $(selector);
|
let target = $(selector);
|
||||||
|
|
||||||
if (target.length) {
|
if (target.length) {
|
||||||
|
@ -8,8 +8,8 @@ math: true
|
|||||||
mermaid: true
|
mermaid: true
|
||||||
image:
|
image:
|
||||||
src: /commons/devices-mockup.png
|
src: /commons/devices-mockup.png
|
||||||
width: 850
|
width: 800
|
||||||
height: 585
|
height: 500
|
||||||
---
|
---
|
||||||
|
|
||||||
This post is to show Markdown syntax rendering on [**Chirpy**](https://github.com/cotes2020/jekyll-theme-chirpy/fork), you can also use it as an example of writing. Now, let's start looking at text and typography.
|
This post is to show Markdown syntax rendering on [**Chirpy**](https://github.com/cotes2020/jekyll-theme-chirpy/fork), you can also use it as an example of writing. Now, let's start looking at text and typography.
|
||||||
@ -72,7 +72,6 @@ Sun
|
|||||||
Moon
|
Moon
|
||||||
: the natural satellite of the earth, visible by reflected light from the sun
|
: the natural satellite of the earth, visible by reflected light from the sun
|
||||||
|
|
||||||
|
|
||||||
## Block Quote
|
## Block Quote
|
||||||
|
|
||||||
> This line to shows the Block Quote.
|
> This line to shows the Block Quote.
|
||||||
@ -89,12 +88,10 @@ Moon
|
|||||||
|
|
||||||
<http://127.0.0.1:4000>
|
<http://127.0.0.1:4000>
|
||||||
|
|
||||||
|
|
||||||
## Footnote
|
## Footnote
|
||||||
|
|
||||||
Click the hook will locate the footnote[^footnote], and here is another footnote[^fn-nth-2].
|
Click the hook will locate the footnote[^footnote], and here is another footnote[^fn-nth-2].
|
||||||
|
|
||||||
|
|
||||||
## Images
|
## Images
|
||||||
|
|
||||||
- Default (with caption)
|
- Default (with caption)
|
||||||
@ -141,7 +138,6 @@ _shadow effect (visible in light mode)_
|
|||||||
cherry :active, c, after b a, 1d
|
cherry :active, c, after b a, 1d
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
## Mathematics
|
## Mathematics
|
||||||
|
|
||||||
The mathematics powered by [**MathJax**](https://www.mathjax.org/):
|
The mathematics powered by [**MathJax**](https://www.mathjax.org/):
|
||||||
@ -152,12 +148,10 @@ When $a \ne 0$, there are two solutions to $ax^2 + bx + c = 0$ and they are
|
|||||||
|
|
||||||
$$ x = {-b \pm \sqrt{b^2-4ac} \over 2a} $$
|
$$ x = {-b \pm \sqrt{b^2-4ac} \over 2a} $$
|
||||||
|
|
||||||
|
|
||||||
## Inline code
|
## Inline code
|
||||||
|
|
||||||
This is an example of `Inline Code`.
|
This is an example of `Inline Code`.
|
||||||
|
|
||||||
|
|
||||||
## Code block
|
## Code block
|
||||||
|
|
||||||
### Common
|
### Common
|
||||||
|
@ -24,15 +24,15 @@ tags: [TAG] # TAG names should always be lowercase
|
|||||||
---
|
---
|
||||||
```
|
```
|
||||||
|
|
||||||
> **Note**: The posts' ***layout*** has been set to `post` by default, so there is no need to add the variable ***layout*** in Front Matter block.
|
> **Note**: The posts' ***layout*** has been set to `post` by default, so there is no need to add the variable ***layout*** in the Front Matter block.
|
||||||
|
|
||||||
### Timezone of date
|
### Timezone of date
|
||||||
|
|
||||||
In order to accurately record the release date of a post, you should not only setup the `timezone` of `_config.yml` but also provide the the post's timezone in field `date` of its Front Matter block. Format: `+/-TTTT`, e.g. `+0800`.
|
In order to accurately record the release date of a post, you should not only set up the `timezone` of `_config.yml` but also provide the post's timezone in variable `date` of its Front Matter block. Format: `+/-TTTT`, e.g. `+0800`.
|
||||||
|
|
||||||
### Categories and Tags
|
### Categories and Tags
|
||||||
|
|
||||||
The `categories` of each post is designed to contain up to two elements, and the number of elements in `tags` can be zero to infinity. For instance:
|
The `categories` of each post are designed to contain up to two elements, and the number of elements in `tags` can be zero to infinity. For instance:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
categories: [Animal, Insect]
|
categories: [Animal, Insect]
|
||||||
@ -41,7 +41,7 @@ tags: [bee]
|
|||||||
|
|
||||||
## Table of Contents
|
## Table of Contents
|
||||||
|
|
||||||
By default, the **T**able **o**f **C**ontents (TOC) is displayed on the right panel of the post. If you want to turn it off globally, go to `_config.yml` and set the value of variable `toc` to `false`. If you want to turn off TOC for specific post, add the following to post's [Front Matter](https://jekyllrb.com/docs/front-matter/):
|
By default, the **T**able **o**f **C**ontents (TOC) is displayed on the right panel of the post. If you want to turn it off globally, go to `_config.yml` and set the value of variable `toc` to `false`. If you want to turn off TOC for a specific post, add the following to the post's [Front Matter](https://jekyllrb.com/docs/front-matter/):
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
---
|
---
|
||||||
@ -51,7 +51,7 @@ toc: false
|
|||||||
|
|
||||||
## Comments
|
## Comments
|
||||||
|
|
||||||
Similar to TOC, the [Disqus](https://disqus.com/) comments is loaded by default in each post, and the global switch is defined by variable `comments` in file `_config.yml` . If you want to close the comment for specific post, add the following to the **Front Matter** of the post:
|
Similar to TOC, the [Disqus](https://disqus.com/) comments are loaded by default in each post, and the global switch is defined by variable `comments` in file `_config.yml` . If you want to close the comment for a specific post, add the following to the **Front Matter** of the post:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
---
|
---
|
||||||
@ -79,13 +79,13 @@ mermaid: true
|
|||||||
---
|
---
|
||||||
```
|
```
|
||||||
|
|
||||||
Then you can use it like other markdown language: surround the graph code with ```` ```mermaid ```` and ```` ``` ````.
|
Then you can use it like other markdown languages: surround the graph code with ```` ```mermaid ```` and ```` ``` ````.
|
||||||
|
|
||||||
## Images
|
## Images
|
||||||
|
|
||||||
### Preview image
|
### Preview image
|
||||||
|
|
||||||
If you want to add an image to the top of the post contents, specify the attribute `src`, `width`, `height` and `alt` for the image:
|
If you want to add an image to the top of the post contents, specify the attribute `src`, `width`, `height`, and `alt` for the image:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
---
|
---
|
||||||
@ -121,7 +121,7 @@ In order to prevent the page content layout from shifting when the image is load
|
|||||||
|
|
||||||
### Image position
|
### Image position
|
||||||
|
|
||||||
By default, the image is centered, but you can specify the position by using one of class `normal` , `left` and `right`. For example:
|
By default, the image is centered, but you can specify the position by using one of the classes `normal`, `left`, and `right`. For example:
|
||||||
|
|
||||||
- **Normal position**
|
- **Normal position**
|
||||||
|
|
||||||
@ -159,14 +159,14 @@ The screenshots of the program window can be considered to show the shadow effec
|
|||||||
|
|
||||||
### CDN URL
|
### CDN URL
|
||||||
|
|
||||||
If you host the images on the CDN, you can save the time of repeatedly writing the CDN url by assigning the variable `img_cdn` of `_config.yml` file:
|
If you host the images on the CDN, you can save the time of repeatedly writing the CDN URL by assigning the variable `img_cdn` of `_config.yml` file:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
img_cdn: https://cdn.com
|
img_cdn: https://cdn.com
|
||||||
```
|
```
|
||||||
{: file='_config.yml' .nolineno}
|
{: file='_config.yml' .nolineno}
|
||||||
|
|
||||||
Once `img_cdn` is assigned, the CDN url will be added to the path of all images (images of site avatar and posts) starting with `/`.
|
Once `img_cdn` is assigned, the CDN URL will be added to the path of all images (images of site avatar and posts) starting with `/`.
|
||||||
|
|
||||||
For instance, when using images:
|
For instance, when using images:
|
||||||
|
|
||||||
@ -210,11 +210,11 @@ key: value
|
|||||||
```
|
```
|
||||||
````
|
````
|
||||||
|
|
||||||
> **Limination**: The Jekyll style `highlight` tag ais not compatible with this theme.
|
> **Limitation**: The Jekyll style `highlight` tag is not compatible with this theme.
|
||||||
|
|
||||||
### Line Number
|
### Line Number
|
||||||
|
|
||||||
By default, all languages except `plaintext`, `console` and `terminal` will display line numbers. When you want to hide the line number of the code block, you can append `{: .nolineno}` at the next line:
|
By default, all languages except `plaintext`, `console`, and `terminal` will display line numbers. When you want to hide the line number of the code block, you can append `{: .nolineno}` at the next line:
|
||||||
|
|
||||||
````markdown
|
````markdown
|
||||||
```shell
|
```shell
|
||||||
@ -253,4 +253,3 @@ Or adding `render_with_liquid: false` (Requires Jekyll 4.0 or higher) to the pos
|
|||||||
## Learn More
|
## Learn More
|
||||||
|
|
||||||
For more knowledge about Jekyll posts, visit the [Jekyll Docs: Posts](https://jekyllrb.com/docs/posts/).
|
For more knowledge about Jekyll posts, visit the [Jekyll Docs: Posts](https://jekyllrb.com/docs/posts/).
|
||||||
|
|
||||||
|
@ -9,7 +9,7 @@ pin: true
|
|||||||
|
|
||||||
## Prerequisites
|
## Prerequisites
|
||||||
|
|
||||||
Follow the instructions in the [Jekyll Docs](https://jekyllrb.com/docs/installation/) to complete the installation of `Ruby`, `RubyGems`, `Jekyll` and `Bundler`.
|
Follow the instructions in the [Jekyll Docs](https://jekyllrb.com/docs/installation/) to complete the installation of `Ruby`, `RubyGems`, `Jekyll`, and `Bundler`.
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
@ -17,9 +17,8 @@ Follow the instructions in the [Jekyll Docs](https://jekyllrb.com/docs/installat
|
|||||||
|
|
||||||
There are two ways to create a new repository for this theme:
|
There are two ways to create a new repository for this theme:
|
||||||
|
|
||||||
- **[Using the Chirpy Starter](#option-1-using-the-chirpy-starter)** - Easy to upgrade, isolates irrelevant project files so you can focus on writing.
|
- [**Using the Chirpy Starter**](#option-1-using-the-chirpy-starter) - Easy to upgrade, isolates irrelevant project files so you can focus on writing.
|
||||||
|
- [**Forking on GitHub**](#option-2-forking-on-github) - Convenient for custom development, but difficult to upgrade. Unless you are familiar with Jekyll and are determined to tweak or contribute to this project, this approach is not recommended.
|
||||||
- **[Forking on GitHub](#option-2-forking-on-github)** - Convenient for custom development, but difficult to upgrade. Unless you are familiar with Jekyll and are determined to tweak or contribute to this project, this approach is not recommended.
|
|
||||||
|
|
||||||
#### Option 1. Using the Chirpy Starter
|
#### Option 1. Using the Chirpy Starter
|
||||||
|
|
||||||
@ -44,7 +43,7 @@ The above command will:
|
|||||||
- files under `_posts`
|
- files under `_posts`
|
||||||
- folder `docs`
|
- folder `docs`
|
||||||
|
|
||||||
2. If the option `--no-gh` is provided, the directory `.github` will be deleted. Otherwise, setup the GitHub Action workflow by removing the extension `.hook` of `.github/workflows/pages-deploy.yml.hook`, and then remove the other files and directories in the folder `.github`.
|
2. If the option `--no-gh` is provided, the directory `.github` will be deleted. Otherwise, set up the GitHub Action workflow by removing the extension `.hook` of `.github/workflows/pages-deploy.yml.hook`, and then remove the other files and directories in the folder `.github`.
|
||||||
|
|
||||||
3. Removes item `Gemfile.lock` from `.gitignore`.
|
3. Removes item `Gemfile.lock` from `.gitignore`.
|
||||||
|
|
||||||
@ -52,7 +51,7 @@ The above command will:
|
|||||||
|
|
||||||
### Installing Dependencies
|
### Installing Dependencies
|
||||||
|
|
||||||
Before running for the first time, go the root directory of your site, and install dependencies as follows:
|
Before running for the first time, go to the root directory of your site, and install dependencies as follows:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ bundle
|
$ bundle
|
||||||
@ -71,7 +70,7 @@ Update the variables of `_config.yml` as needed. Some of them are typical option
|
|||||||
|
|
||||||
### Customing Stylesheet
|
### Customing Stylesheet
|
||||||
|
|
||||||
If you need to customize stylesheet, copy the theme's `assets/css/style.scss` to the same path on your Jekyll site, and then add the custom style at the end of the style file.
|
If you need to customize the stylesheet, copy the theme's `assets/css/style.scss` to the same path on your Jekyll site, and then add the custom style at the end of the style file.
|
||||||
|
|
||||||
Starting from [`v4.1.0`][chirpy-4.1.0], if you want to overwrite the SASS variables defined in `_sass/addon/variables.scss`, create a new file `_sass/variables-hook.scss` and assign new values to the target variable in it.
|
Starting from [`v4.1.0`][chirpy-4.1.0], if you want to overwrite the SASS variables defined in `_sass/addon/variables.scss`, create a new file `_sass/variables-hook.scss` and assign new values to the target variable in it.
|
||||||
|
|
||||||
@ -96,7 +95,7 @@ After a while, the local service will be published at _<http://127.0.0.1:4000>_.
|
|||||||
|
|
||||||
### Deployment
|
### Deployment
|
||||||
|
|
||||||
Before the deployment begins, checkout the file `_config.yml` and make sure the `url` is configured correctly. Furthermore, if you prefer the [**project site**](https://help.github.com/en/github/working-with-github-pages/about-github-pages#types-of-github-pages-sites) and don't use a custom domain, or you want to visit your website with a base URL on a web server other than **GitHub Pages**, remember to change the `baseurl` to your project name that starting with a slash, e.g, `/project-name`.
|
Before the deployment begins, check out the file `_config.yml` and make sure the `url` is configured correctly. Furthermore, if you prefer the [**project site**](https://help.github.com/en/github/working-with-github-pages/about-github-pages#types-of-github-pages-sites) and don't use a custom domain, or you want to visit your website with a base URL on a web server other than **GitHub Pages**, remember to change the `baseurl` to your project name that starts with a slash, e.g, `/project-name`.
|
||||||
|
|
||||||
Now you can choose ONE of the following methods to deploy your Jekyll site.
|
Now you can choose ONE of the following methods to deploy your Jekyll site.
|
||||||
|
|
||||||
@ -110,7 +109,7 @@ Quickly check the files needed for GitHub Actions build:
|
|||||||
|
|
||||||
- Ensure your Jekyll site has file `tools/deploy.sh`. Otherwise, copy it from here to your Jekyll site.
|
- Ensure your Jekyll site has file `tools/deploy.sh`. Otherwise, copy it from here to your Jekyll site.
|
||||||
|
|
||||||
- Furthermore, if you have committed `Gemfile.lock` to the repo, and your runtime system is not Linux, don't forget to update the platform list in the lockfile:
|
- Furthermore, if you have committed `Gemfile.lock` to the repo, and your runtime system is not Linux, don't forget to update the platform list in the lock file:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ bundle lock --add-platform x86_64-linux
|
$ bundle lock --add-platform x86_64-linux
|
||||||
@ -154,7 +153,7 @@ Unless you specified the output path, the generated site files will be placed in
|
|||||||
|
|
||||||
It depends on how you use the theme:
|
It depends on how you use the theme:
|
||||||
|
|
||||||
- If you are using the theme gem (there will be `gem "jekyll-theme-chirpy"` in the `Gemfile`), editing the `Gemfile` and update the version number of the them gem, for example:
|
- If you are using the theme gem (there will be `gem "jekyll-theme-chirpy"` in the `Gemfile`), editing the `Gemfile` and update the version number of the theme gem, for example:
|
||||||
|
|
||||||
```diff
|
```diff
|
||||||
- gem "jekyll-theme-chirpy", "~> 3.2", ">= 3.2.1"
|
- gem "jekyll-theme-chirpy", "~> 3.2", ">= 3.2.1"
|
||||||
|
@ -6,11 +6,11 @@ categories: [Blogging, Tutorial]
|
|||||||
tags: [favicon]
|
tags: [favicon]
|
||||||
---
|
---
|
||||||
|
|
||||||
The [favicons](https://www.favicon-generator.org/about/) of [**Chirpy**](https://github.com/cotes2020/jekyll-theme-chirpy/) are placed in the directory `assets/img/favicons/`. You may want to replace them with your own. The following sections will guide you how to create and replace the default favicons.
|
The [favicons](https://www.favicon-generator.org/about/) of [**Chirpy**](https://github.com/cotes2020/jekyll-theme-chirpy/) are placed in the directory `assets/img/favicons/`. You may want to replace them with your own. The following sections will guide you to create and replace the default favicons.
|
||||||
|
|
||||||
## Generate the favicon
|
## Generate the favicon
|
||||||
|
|
||||||
Prepare a square image (PNG, JPG, or SVG) with a size of 512x512 or more, and then go to the online tool [**Real Favicon Generator**](https://realfavicongenerator.net/) and click button <kbd>Select your Favicon image</kbd> to upload your image file.
|
Prepare a square image (PNG, JPG, or SVG) with a size of 512x512 or more, and then go to the online tool [**Real Favicon Generator**](https://realfavicongenerator.net/) and click the button <kbd>Select your Favicon image</kbd> to upload your image file.
|
||||||
|
|
||||||
In the next step, the webpage will show all usage scenarios. You can keep the default options, scroll to the bottom of the page, and click the button <kbd>Generate your Favicons and HTML code</kbd> to generate the favicon.
|
In the next step, the webpage will show all usage scenarios. You can keep the default options, scroll to the bottom of the page, and click the button <kbd>Generate your Favicons and HTML code</kbd> to generate the favicon.
|
||||||
|
|
||||||
@ -23,7 +23,7 @@ Download the generated package, unzip and delete the following two from the extr
|
|||||||
|
|
||||||
Now, copy the remaining image files (`PNG` and `ICO`) to cover the original files in the folder `assets/img/favicons/` of your Jekyll site. If your Jekyll site doesn't have this directory yet, just create one.
|
Now, copy the remaining image files (`PNG` and `ICO`) to cover the original files in the folder `assets/img/favicons/` of your Jekyll site. If your Jekyll site doesn't have this directory yet, just create one.
|
||||||
|
|
||||||
The following table will helps you understand the changes to the favicon files:
|
The following table will help you understand the changes to the favicon files:
|
||||||
|
|
||||||
| File(s) | From Online Tool | From Chirpy |
|
| File(s) | From Online Tool | From Chirpy |
|
||||||
|---------------------|:---------------------------------:|:-----------:|
|
|---------------------|:---------------------------------:|:-----------:|
|
||||||
|
@ -13,20 +13,20 @@ This post is to enable Page Views on the [**Chirpy**][chirpy-homepage] theme bas
|
|||||||
|
|
||||||
### Create GA account and property
|
### Create GA account and property
|
||||||
|
|
||||||
First, you need to setup your account on Google analytics. While your create your account, you must create your first **Property** as well.
|
First, you need to set up your account on Google analytics. While you create your account, you must create your first **Property** as well.
|
||||||
|
|
||||||
1. Head to <https://analytics.google.com/> and click on **Start Measuring**
|
1. Head to <https://analytics.google.com/> and click on **Start Measuring**
|
||||||
2. Enter your desired _Account Name_ and choose the desired checkboxes
|
2. Enter your desired _Account Name_ and choose the desired checkboxes
|
||||||
3. Enter your desired _Property Name_. This is the name of the tracker project that appears on your Google Analytics dashboard
|
3. Enter your desired _Property Name_. This is the name of the tracker project that appears on your Google Analytics dashboard
|
||||||
4. Enter the required information _About your business_
|
4. Enter the required information _About your business_
|
||||||
5. Hit _Create_ and accept any license popup to setup your Google Analytics account and create your property
|
5. Hit _Create_ and accept any license popup to set up your Google Analytics account and create your property
|
||||||
|
|
||||||
### Create Data Stream
|
### Create Data Stream
|
||||||
|
|
||||||
With your property created, you now need to set up Data Stream to track your blog traffic. After you signup, the prompt should automatically take you to creating your first **Data Stream**. If not, follow these steps:
|
With your property created, you now need to set up Data Stream to track your blog traffic. After you signup, the prompt should automatically take you to create your first **Data Stream**. If not, follow these steps:
|
||||||
|
|
||||||
1. Go to **Admin** on the left column
|
1. Go to **Admin** on the left column
|
||||||
2. Select the desired property from the drop down on the second column
|
2. Select the desired property from the drop-down on the second column
|
||||||
3. Click on **Data Streams**
|
3. Click on **Data Streams**
|
||||||
4. Add a stream and click on **Web**
|
4. Add a stream and click on **Web**
|
||||||
5. Enter your blog's URL
|
5. Enter your blog's URL
|
||||||
@ -47,13 +47,13 @@ google_analytics:
|
|||||||
```
|
```
|
||||||
{: file="_config.yml"}
|
{: file="_config.yml"}
|
||||||
|
|
||||||
When you push these changes to your blog, you should start seeing the traffic on your Google Analytics. Play around with Google Analytics dashboard to get familiar with the options available as it takes like 5 mins to pickup your changes. You should now be able to monitor your traffic in realtime.
|
When you push these changes to your blog, you should start seeing the traffic on your Google Analytics. Play around with the Google Analytics dashboard to get familiar with the options available as it takes like 5 mins to pick up your changes. You should now be able to monitor your traffic in real time.
|
||||||
|
|
||||||
{: width="616" height="557"}
|
{: width="616" height="557"}
|
||||||
|
|
||||||
## Setup Page Views
|
## Setup Page Views
|
||||||
|
|
||||||
There is a detailed [tutorial](https://developers.google.com/analytics/solutions/google-analytics-super-proxy) available to set up Google Analytics superProxy. But, if you are interested to just quickly get your Chirpy-based blog display page views, follow along. These steps were tested on a Linux machine. If you are running Windows, you can use Git bash terminal to run Unix-like commands.
|
There is a detailed [tutorial](https://developers.google.com/analytics/solutions/google-analytics-super-proxy) available to set up Google Analytics superProxy. But, if you are interested to just quickly get your Chirpy-based blog display page views, follow along. These steps were tested on a Linux machine. If you are running Windows, you can use the Git bash terminal to run Unix-like commands.
|
||||||
|
|
||||||
### Setup Google App Engine
|
### Setup Google App Engine
|
||||||
|
|
||||||
@ -67,7 +67,7 @@ There is a detailed [tutorial](https://developers.google.com/analytics/solutions
|
|||||||
|
|
||||||
5. Select **Python** language and **Standard** environment
|
5. Select **Python** language and **Standard** environment
|
||||||
|
|
||||||
6. Enable billing account. Yeah, you have to link your credit card. But, you won't be billed unless you exceed your free quota. For a simple blog, free quota is more than sufficient.
|
6. Enable billing account. Yeah, you have to link your credit card. But, you won't be billed unless you exceed your free quota. For a simple blog, the free quota is more than sufficient.
|
||||||
|
|
||||||
7. Go to your App Engine dashboard on your browser and select **API & Services** from the left navigation menu
|
7. Go to your App Engine dashboard on your browser and select **API & Services** from the left navigation menu
|
||||||
|
|
||||||
@ -77,7 +77,7 @@ There is a detailed [tutorial](https://developers.google.com/analytics/solutions
|
|||||||
|
|
||||||
10. On the left, Click on _OAuth Consent Screen_ and accept **Configure Consent Screen**. Select **External** since your blog is probably hosted for the public. Click on **Publish** under _Publishing Status_
|
10. On the left, Click on _OAuth Consent Screen_ and accept **Configure Consent Screen**. Select **External** since your blog is probably hosted for the public. Click on **Publish** under _Publishing Status_
|
||||||
|
|
||||||
11. Click on **Credentials** on the left and create a new **OAuth Client IDs** credential. Make sure to add a entry under `Authorized redirect URIs` that matches: `https://<project-id>.<region>.r.appspot.com/admin/auth`
|
11. Click on **Credentials** on the left and create a new **OAuth Client IDs** credential. Make sure to add an entry under `Authorized redirect URIs` that matches: `https://<project-id>.<region>.r.appspot.com/admin/auth`
|
||||||
|
|
||||||
12. Note down the **Your Client ID** and **Your Client Secret**. You'll need this in the next section.
|
12. Note down the **Your Client ID** and **Your Client Secret**. You'll need this in the next section.
|
||||||
|
|
||||||
@ -114,12 +114,13 @@ There is a detailed [tutorial](https://developers.google.com/analytics/solutions
|
|||||||
1. Clone the **Google Analytics superProxy** project on Github: <https://github.com/googleanalytics/google-analytics-super-proxy> to your local.
|
1. Clone the **Google Analytics superProxy** project on Github: <https://github.com/googleanalytics/google-analytics-super-proxy> to your local.
|
||||||
|
|
||||||
2. Remove the first 2 lines in the [`src/app.yaml`](https://github.com/googleanalytics/google-analytics-super-proxy/blob/master/src/app.yaml#L1-L2) file:
|
2. Remove the first 2 lines in the [`src/app.yaml`](https://github.com/googleanalytics/google-analytics-super-proxy/blob/master/src/app.yaml#L1-L2) file:
|
||||||
|
|
||||||
```diff
|
```diff
|
||||||
- application: your-project-id
|
- application: your-project-id
|
||||||
- version: 1
|
- version: 1
|
||||||
```
|
```
|
||||||
|
|
||||||
3. In `src/config.py`, add the `OAUTH_CLIENT_ID` and `OAUTH_CLIENT_SECRET` that you gathered from you App Engine Dashboard.
|
3. In `src/config.py`, add the `OAUTH_CLIENT_ID` and `OAUTH_CLIENT_SECRET` that you gathered from your App Engine Dashboard.
|
||||||
|
|
||||||
4. Enter any random key for `XSRF_KEY`, your `config.py` should look similar to this
|
4. Enter any random key for `XSRF_KEY`, your `config.py` should look similar to this
|
||||||
|
|
||||||
@ -206,13 +207,12 @@ In order to reduce the returned results and reduce the network bandwidth, we add
|
|||||||
|
|
||||||
If the `site.baseurl` is specified, change the first filtering rule to `ga:pagePath=~^/BASE_URL/posts/.*/$`, where `BASE_URL` is the value of `site.baseurl`.
|
If the `site.baseurl` is specified, change the first filtering rule to `ga:pagePath=~^/BASE_URL/posts/.*/$`, where `BASE_URL` is the value of `site.baseurl`.
|
||||||
|
|
||||||
After <kbd>Run Query</kbd>, copy the generated contents of **API Query URI** at the bottom of the page, and fill in the **Encoded URI for the query** of SuperProxy on GAE.
|
After <kbd>Run Query</kbd>, copy the generated contents of **API Query URI** at the bottom of the page and fill in the **Encoded URI for the query** of SuperProxy on GAE.
|
||||||
|
|
||||||
After the query is saved on GAE, a **Public Endpoint** (public access address) will be generated, and we will get the query result in JSON format when accessing it. Finally, click <kbd>Enable Endpoint</kbd> in **Public Request Endpoint** to make the query effective, and click <kbd>Start Scheduling</kbd> in **Scheduling** to start the scheduled task.
|
After the query is saved on GAE, a **Public Endpoint** (public access address) will be generated, and we will get the query result in JSON format when accessing it. Finally, click <kbd>Enable Endpoint</kbd> in **Public Request Endpoint** to make the query effective, and click <kbd>Start Scheduling</kbd> in **Scheduling** to start the scheduled task.
|
||||||
|
|
||||||
{: width="1100" height="126"}
|
{: width="1100" height="126"}
|
||||||
|
|
||||||
|
|
||||||
## Configure Chirpy to Display Page View
|
## Configure Chirpy to Display Page View
|
||||||
|
|
||||||
Once all the hard part is done, it is very easy to enable the Page View on Chirpy theme. Your superProxy dashboard should look something like below and you can grab the required values.
|
Once all the hard part is done, it is very easy to enable the Page View on Chirpy theme. Your superProxy dashboard should look something like below and you can grab the required values.
|
||||||
|
@ -6,12 +6,9 @@
|
|||||||
@mixin mode-toggle($dark-mode: false) {
|
@mixin mode-toggle($dark-mode: false) {
|
||||||
@if $dark-mode {
|
@if $dark-mode {
|
||||||
@include dark-scheme;
|
@include dark-scheme;
|
||||||
|
|
||||||
} @else {
|
} @else {
|
||||||
@include light-scheme;
|
@include light-scheme;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
html:not([mode]),
|
html:not([mode]),
|
||||||
@ -175,15 +172,18 @@ footer {
|
|||||||
|
|
||||||
a {
|
a {
|
||||||
color: var(--footer-link);
|
color: var(--footer-link);
|
||||||
|
|
||||||
&:link {
|
&:link {
|
||||||
@include no-text-decoration;
|
@include no-text-decoration;
|
||||||
}
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
@extend %link-hover;
|
@extend %link-hover;
|
||||||
|
|
||||||
@include no-text-decoration;
|
@include no-text-decoration;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.footer-right {
|
.footer-right {
|
||||||
text-align: right;
|
text-align: right;
|
||||||
}
|
}
|
||||||
@ -202,22 +202,28 @@ footer {
|
|||||||
position: -webkit-sticky; /* Safari */
|
position: -webkit-sticky; /* Safari */
|
||||||
position: sticky;
|
position: sticky;
|
||||||
}
|
}
|
||||||
|
|
||||||
&.topbar-down {
|
&.topbar-down {
|
||||||
top: 6rem;
|
top: 6rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
> div {
|
> div {
|
||||||
padding-left: 1rem;
|
padding-left: 1rem;
|
||||||
border-left: 1px solid var(--main-border-color);
|
border-left: 1px solid var(--main-border-color);
|
||||||
|
|
||||||
&:not(:last-child) {
|
&:not(:last-child) {
|
||||||
margin-bottom: 4rem;
|
margin-bottom: 4rem;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
span {
|
span {
|
||||||
@include panel-label;
|
@include panel-label;
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-content {
|
.post-content {
|
||||||
font-size: 0.9rem;
|
font-size: 0.9rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#access-tags {
|
#access-tags {
|
||||||
@ -234,6 +240,7 @@ footer {
|
|||||||
border-radius: 0.8rem;
|
border-radius: 0.8rem;
|
||||||
padding: 0.3rem 0.5rem;
|
padding: 0.3rem 0.5rem;
|
||||||
margin: 0 0.35rem 0.5rem 0;
|
margin: 0 0.35rem 0.5rem 0;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
background-color: #2a408e;
|
background-color: #2a408e;
|
||||||
border-color: #2a408e;
|
border-color: #2a408e;
|
||||||
@ -244,7 +251,6 @@ footer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#access-lastmod {
|
#access-lastmod {
|
||||||
|
|
||||||
li {
|
li {
|
||||||
height: 1.8rem;
|
height: 1.8rem;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@ -270,15 +276,18 @@ footer {
|
|||||||
.footnotes > ol {
|
.footnotes > ol {
|
||||||
padding-left: 2rem;
|
padding-left: 2rem;
|
||||||
margin-top: 0.5rem;
|
margin-top: 0.5rem;
|
||||||
|
|
||||||
> li {
|
> li {
|
||||||
&:not(:last-child) {
|
&:not(:last-child) {
|
||||||
margin-bottom: 0.3rem;
|
margin-bottom: 0.3rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
> p {
|
> p {
|
||||||
margin-left: 0.25em;
|
margin-left: 0.25em;
|
||||||
margin-top: 0;
|
margin-top: 0;
|
||||||
margin-bottom: 0;
|
margin-bottom: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
// [scroll-focus] added by `smooth-scroll.js`
|
// [scroll-focus] added by `smooth-scroll.js`
|
||||||
&:target:not([scroll-focus]),
|
&:target:not([scroll-focus]),
|
||||||
&[scroll-focus=true] > p {
|
&[scroll-focus=true] > p {
|
||||||
@ -310,10 +319,10 @@ footer {
|
|||||||
.reversefootnote {
|
.reversefootnote {
|
||||||
@at-root a#{&} {
|
@at-root a#{&} {
|
||||||
font-size: 0.6rem;
|
font-size: 0.6rem;
|
||||||
position: absolute;
|
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
padding-top: 0.5em;
|
position: relative;
|
||||||
margin-left: 0.5em;
|
bottom: 0.25em;
|
||||||
|
margin-left: 0.25em;
|
||||||
border-bottom-style: none !important;
|
border-bottom-style: none !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -323,9 +332,11 @@ footer {
|
|||||||
margin-top: 3rem;
|
margin-top: 3rem;
|
||||||
margin-bottom: 1rem;
|
margin-bottom: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
em { /* MarkDown italic */
|
em { /* MarkDown italic */
|
||||||
padding-right: 0.2rem;
|
padding-right: 0.2rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
a:hover {
|
a:hover {
|
||||||
code {
|
code {
|
||||||
@extend %link-hover;
|
@extend %link-hover;
|
||||||
@ -346,6 +357,7 @@ footer {
|
|||||||
|
|
||||||
thead {
|
thead {
|
||||||
border-bottom: solid 2px rgba(210, 215, 217, 0.75);
|
border-bottom: solid 2px rgba(210, 215, 217, 0.75);
|
||||||
|
|
||||||
th {
|
th {
|
||||||
@extend %table-cell;
|
@extend %table-cell;
|
||||||
}
|
}
|
||||||
@ -354,18 +366,21 @@ footer {
|
|||||||
tbody {
|
tbody {
|
||||||
tr {
|
tr {
|
||||||
border-bottom: 1px solid var(--tb-border-color);
|
border-bottom: 1px solid var(--tb-border-color);
|
||||||
|
|
||||||
&:nth-child(2n) {
|
&:nth-child(2n) {
|
||||||
background-color: var(--tb-even-bg);
|
background-color: var(--tb-even-bg);
|
||||||
}
|
}
|
||||||
|
|
||||||
&:nth-child(2n + 1) {
|
&:nth-child(2n + 1) {
|
||||||
background-color: var(--tb-odd-bg);
|
background-color: var(--tb-odd-bg);
|
||||||
}
|
}
|
||||||
|
|
||||||
td {
|
td {
|
||||||
@extend %table-cell;
|
@extend %table-cell;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
} // tbody
|
||||||
}
|
}// table
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- post --- */
|
/* --- post --- */
|
||||||
@ -377,12 +392,15 @@ footer {
|
|||||||
.post-meta {
|
.post-meta {
|
||||||
font-size: 0.85rem;
|
font-size: 0.85rem;
|
||||||
word-spacing: 1px;
|
word-spacing: 1px;
|
||||||
|
|
||||||
a {
|
a {
|
||||||
@extend %link-color;
|
@extend %link-color;
|
||||||
@extend %link-underline;
|
@extend %link-underline;
|
||||||
|
|
||||||
&:not(:last-child) {
|
&:not(:last-child) {
|
||||||
margin-right: 2px;
|
margin-right: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
@extend %link-hover;
|
@extend %link-hover;
|
||||||
}
|
}
|
||||||
@ -416,7 +434,7 @@ footer {
|
|||||||
margin: 0.5rem 0;
|
margin: 0.5rem 0;
|
||||||
|
|
||||||
&[data-loaded=true] {
|
&[data-loaded=true] {
|
||||||
animation: fade-in linear .5s;
|
animation: fade-in linear 0.5s;
|
||||||
}
|
}
|
||||||
|
|
||||||
&.left {
|
&.left {
|
||||||
@ -445,6 +463,7 @@ footer {
|
|||||||
&:not(.img-link) {
|
&:not(.img-link) {
|
||||||
@extend %link-color;
|
@extend %link-color;
|
||||||
@extend %link-underline;
|
@extend %link-underline;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
@extend %link-hover;
|
@extend %link-hover;
|
||||||
}
|
}
|
||||||
@ -473,6 +492,7 @@ footer {
|
|||||||
margin: 0 0.4rem 0.2rem -1.4rem;
|
margin: 0 0.4rem 0.2rem -1.4rem;
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
color: var(--checkbox-color);
|
color: var(--checkbox-color);
|
||||||
|
|
||||||
&.checked {
|
&.checked {
|
||||||
color: var(--checkbox-checked-color);
|
color: var(--checkbox-checked-color);
|
||||||
}
|
}
|
||||||
@ -546,6 +566,7 @@ footer {
|
|||||||
padding: 1px 3px;
|
padding: 1px 3px;
|
||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
color: var(--link-color);
|
color: var(--link-color);
|
||||||
|
|
||||||
&:focus {
|
&:focus {
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
}
|
}
|
||||||
@ -755,7 +776,6 @@ $sidebar-display: "sidebar-display";
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
|
|
||||||
&:last-child {
|
&:last-child {
|
||||||
|
|
||||||
a {
|
a {
|
||||||
position: relative;
|
position: relative;
|
||||||
left: $cursor-width / 2;
|
left: $cursor-width / 2;
|
||||||
@ -871,6 +891,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
display: none;
|
display: none;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
|
|
||||||
.post-content {
|
.post-content {
|
||||||
margin-top: 2rem;
|
margin-top: 2rem;
|
||||||
}
|
}
|
||||||
@ -959,6 +980,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
&:focus {
|
&:focus {
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
background: center;
|
background: center;
|
||||||
|
|
||||||
&.form-control {
|
&.form-control {
|
||||||
&::-webkit-input-placeholder { @include input-placeholder; }
|
&::-webkit-input-placeholder { @include input-placeholder; }
|
||||||
&::-moz-placeholder { @include input-placeholder; }
|
&::-moz-placeholder { @include input-placeholder; }
|
||||||
@ -979,6 +1001,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
border: none;
|
border: none;
|
||||||
padding: 0.5rem;
|
padding: 0.5rem;
|
||||||
margin: 0 1rem 1rem 0;
|
margin: 0 1rem 1rem 0;
|
||||||
|
|
||||||
&::before {
|
&::before {
|
||||||
content: "#";
|
content: "#";
|
||||||
color: var(--text-muted-color);
|
color: var(--text-muted-color);
|
||||||
@ -989,6 +1012,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
|
|
||||||
#search-results {
|
#search-results {
|
||||||
padding-bottom: 6rem;
|
padding-bottom: 6rem;
|
||||||
|
|
||||||
a {
|
a {
|
||||||
&:hover {
|
&:hover {
|
||||||
@extend %link-hover;
|
@extend %link-hover;
|
||||||
@ -1081,6 +1105,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
&:nth-child(2) {
|
&:nth-child(2) {
|
||||||
margin-top: $topbar-height; /* same as the height of topbar */
|
margin-top: $topbar-height; /* same as the height of topbar */
|
||||||
}
|
}
|
||||||
|
|
||||||
&:first-child {
|
&:first-child {
|
||||||
/* 3rem for topbar, 6rem for footer */
|
/* 3rem for topbar, 6rem for footer */
|
||||||
min-height: calc(100vh - #{$topbar-height} - #{$footer-height} - #{$post-extend-min-height});
|
min-height: calc(100vh - #{$topbar-height} - #{$footer-height} - #{$post-extend-min-height});
|
||||||
@ -1088,8 +1113,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
}
|
}
|
||||||
|
|
||||||
#post-wrapper {
|
#post-wrapper {
|
||||||
min-height: calc(
|
min-height: calc(100vh - #{$topbar-height} - #{$footer-height} - #{$post-extend-min-height}) !important;
|
||||||
100vh - #{$topbar-height} - #{$footer-height} - #{$post-extend-min-height}) !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#topbar-wrapper.row,
|
#topbar-wrapper.row,
|
||||||
@ -1147,8 +1171,8 @@ $sidebar-display: "sidebar-display";
|
|||||||
}
|
}
|
||||||
|
|
||||||
#post-wrapper {
|
#post-wrapper {
|
||||||
min-height: calc(
|
min-height: calc(100vh - #{$topbar-height} - #{$footer-height} - #{$post-extend-min-height}) !important;
|
||||||
100vh - #{$topbar-height} - #{$footer-height} - #{$post-extend-min-height}) !important;
|
|
||||||
h1 {
|
h1 {
|
||||||
margin-top: 2.2rem;
|
margin-top: 2.2rem;
|
||||||
font-size: 1.55rem;
|
font-size: 1.55rem;
|
||||||
@ -1170,6 +1194,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
|
|
||||||
footer {
|
footer {
|
||||||
height: $footer-height;
|
height: $footer-height;
|
||||||
|
|
||||||
> div.d-flex {
|
> div.d-flex {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
padding: 1.5rem 0;
|
padding: 1.5rem 0;
|
||||||
@ -1178,6 +1203,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
-ms-flex-pack: distribute !important;
|
-ms-flex-pack: distribute !important;
|
||||||
justify-content: space-around !important;
|
justify-content: space-around !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.footer-left,
|
.footer-left,
|
||||||
.footer-right {
|
.footer-right {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
@ -1201,13 +1227,13 @@ $sidebar-display: "sidebar-display";
|
|||||||
.footnotes ol > li {
|
.footnotes ol > li {
|
||||||
padding-top: 3.5rem;
|
padding-top: 3.5rem;
|
||||||
margin-top: -3.2rem;
|
margin-top: -3.2rem;
|
||||||
|
|
||||||
&:first-child {
|
&:first-child {
|
||||||
margin-top: -3.5rem;
|
margin-top: -3.5rem;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
[#{$sidebar-display}] {
|
[#{$sidebar-display}] {
|
||||||
|
|
||||||
#sidebar {
|
#sidebar {
|
||||||
transform: translateX(0);
|
transform: translateX(0);
|
||||||
}
|
}
|
||||||
@ -1272,6 +1298,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
&.loaded ~ a {
|
&.loaded ~ a {
|
||||||
margin-right: 1rem;
|
margin-right: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.fa-times-circle {
|
.fa-times-circle {
|
||||||
right: 5.2rem;
|
right: 5.2rem;
|
||||||
}
|
}
|
||||||
@ -1299,6 +1326,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
|
|
||||||
#page h1.dynamic-title {
|
#page h1.dynamic-title {
|
||||||
display: none;
|
display: none;
|
||||||
|
|
||||||
~ .post-content {
|
~ .post-content {
|
||||||
margin-top: 3rem;
|
margin-top: 3rem;
|
||||||
}
|
}
|
||||||
@ -1373,7 +1401,6 @@ $sidebar-display: "sidebar-display";
|
|||||||
|
|
||||||
/* Compact icons in sidebar & panel hidden */
|
/* Compact icons in sidebar & panel hidden */
|
||||||
@media all and (min-width: 850px) and (max-width: 1199px) {
|
@media all and (min-width: 850px) and (max-width: 1199px) {
|
||||||
|
|
||||||
#sidebar {
|
#sidebar {
|
||||||
width: $sidebar-width-small;
|
width: $sidebar-width-small;
|
||||||
|
|
||||||
@ -1387,6 +1414,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
span {
|
span {
|
||||||
width: 2rem;
|
width: 2rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.icon-border {
|
.icon-border {
|
||||||
left: -3px;
|
left: -3px;
|
||||||
}
|
}
|
||||||
@ -1446,7 +1474,6 @@ $sidebar-display: "sidebar-display";
|
|||||||
/* --- desktop mode, both sidebar and panel are visible --- */
|
/* --- desktop mode, both sidebar and panel are visible --- */
|
||||||
|
|
||||||
@media all and (min-width: 1200px) {
|
@media all and (min-width: 1200px) {
|
||||||
|
|
||||||
#main > div.row > div.col-xl-8 {
|
#main > div.row > div.col-xl-8 {
|
||||||
-webkit-box-flex: 0;
|
-webkit-box-flex: 0;
|
||||||
-ms-flex: 0 0 75%;
|
-ms-flex: 0 0 75%;
|
||||||
@ -1476,12 +1503,15 @@ $sidebar-display: "sidebar-display";
|
|||||||
|
|
||||||
#search-results > div {
|
#search-results > div {
|
||||||
width: 46%;
|
width: 46%;
|
||||||
|
|
||||||
&:nth-child(odd) {
|
&:nth-child(odd) {
|
||||||
margin-right: 1.5rem;
|
margin-right: 1.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
&:nth-child(even) {
|
&:nth-child(even) {
|
||||||
margin-left: 1.5rem;
|
margin-left: 1.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
&:last-child:nth-child(odd) {
|
&:last-child:nth-child(odd) {
|
||||||
position: relative;
|
position: relative;
|
||||||
right: 24.3%;
|
right: 24.3%;
|
||||||
@ -1499,9 +1529,9 @@ $sidebar-display: "sidebar-display";
|
|||||||
}
|
}
|
||||||
|
|
||||||
@media all and (min-width: 1400px) {
|
@media all and (min-width: 1400px) {
|
||||||
|
|
||||||
#main > div.row {
|
#main > div.row {
|
||||||
padding-left: calc((100% - #{$main-content-max-width}) / 2);
|
padding-left: calc((100% - #{$main-content-max-width}) / 2);
|
||||||
|
|
||||||
> div.col-xl-8 {
|
> div.col-xl-8 {
|
||||||
max-width: 850px;
|
max-width: 850px;
|
||||||
}
|
}
|
||||||
@ -1509,6 +1539,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
|
|
||||||
#search-result-wrapper {
|
#search-result-wrapper {
|
||||||
padding-right: 2rem;
|
padding-right: 2rem;
|
||||||
|
|
||||||
> div {
|
> div {
|
||||||
max-width: 1110px;
|
max-width: 1110px;
|
||||||
}
|
}
|
||||||
@ -1527,13 +1558,13 @@ $sidebar-display: "sidebar-display";
|
|||||||
}
|
}
|
||||||
|
|
||||||
@media all and (min-width: 1650px) {
|
@media all and (min-width: 1650px) {
|
||||||
|
|
||||||
#breadcrumb {
|
#breadcrumb {
|
||||||
padding-left: 0;
|
padding-left: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#main > div.row > div.col-xl-8 {
|
#main > div.row > div.col-xl-8 {
|
||||||
padding-left: 0;
|
padding-left: 0;
|
||||||
|
|
||||||
> div:first-child {
|
> div:first-child {
|
||||||
padding-left: 0.55rem !important;
|
padding-left: 0.55rem !important;
|
||||||
padding-right: 1.9rem !important;
|
padding-right: 1.9rem !important;
|
||||||
@ -1581,6 +1612,7 @@ $sidebar-display: "sidebar-display";
|
|||||||
> a {
|
> a {
|
||||||
width: 6.2rem;
|
width: 6.2rem;
|
||||||
height: 6.2rem;
|
height: 6.2rem;
|
||||||
|
|
||||||
&.mx-auto {
|
&.mx-auto {
|
||||||
margin-left: 0 !important;
|
margin-left: 0 !important;
|
||||||
}
|
}
|
||||||
|
@ -76,6 +76,7 @@ div > pre {
|
|||||||
table {
|
table {
|
||||||
padding: 0;
|
padding: 0;
|
||||||
border: 0;
|
border: 0;
|
||||||
|
|
||||||
td pre {
|
td pre {
|
||||||
overflow: visible; /* Fixed iOS safari overflow-x */
|
overflow: visible; /* Fixed iOS safari overflow-x */
|
||||||
word-break: normal; /* Fixed iOS safari linenos code break */
|
word-break: normal; /* Fixed iOS safari linenos code break */
|
||||||
@ -157,6 +158,7 @@ div {
|
|||||||
pre.lineno {
|
pre.lineno {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
td.rouge-code {
|
td.rouge-code {
|
||||||
@extend %code-snippet-padding;
|
@extend %code-snippet-padding;
|
||||||
}
|
}
|
||||||
|
@ -116,11 +116,13 @@
|
|||||||
.card-header {
|
.card-header {
|
||||||
background-color: var(--card-header-bg);
|
background-color: var(--card-header-bg);
|
||||||
}
|
}
|
||||||
|
|
||||||
.list-group-item {
|
.list-group-item {
|
||||||
border-left: none;
|
border-left: none;
|
||||||
border-right: none;
|
border-right: none;
|
||||||
padding-left: 2rem;
|
padding-left: 2rem;
|
||||||
border-color: var(--categories-border);
|
border-color: var(--categories-border);
|
||||||
|
|
||||||
&:last-child {
|
&:last-child {
|
||||||
border-bottom-color: var(--card-bg);
|
border-bottom-color: var(--card-bg);
|
||||||
}
|
}
|
||||||
@ -128,13 +130,16 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
#archives li:nth-child(odd) {
|
#archives li:nth-child(odd) {
|
||||||
background-image: linear-gradient(
|
background-image:
|
||||||
|
linear-gradient(
|
||||||
to left,
|
to left,
|
||||||
rgb(26, 26, 30),
|
rgb(26, 26, 30),
|
||||||
rgb(39, 39, 45),
|
rgb(39, 39, 45),
|
||||||
rgb(39, 39, 45),
|
rgb(39, 39, 45),
|
||||||
rgb(39, 39, 45),
|
rgb(39, 39, 45),
|
||||||
rgb(26, 26, 30));
|
rgb(26, 26, 30)
|
||||||
|
);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
} // dark-scheme
|
} // dark-scheme
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/*!
|
/*!
|
||||||
* The styles for Jekyll theme Chirpy
|
* The styles for Jekyll theme Chirpy
|
||||||
*
|
*
|
||||||
* Chirpy v4.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy)
|
* Chirpy v4.3.4 (https://github.com/cotes2020/jekyll-theme-chirpy)
|
||||||
* © 2019 Cotes Chung
|
* © 2019 Cotes Chung
|
||||||
* MIT Licensed
|
* MIT Licensed
|
||||||
*/
|
*/
|
||||||
|
@ -41,6 +41,7 @@
|
|||||||
&:not(:first-child) {
|
&:not(:first-child) {
|
||||||
position: relative;
|
position: relative;
|
||||||
left: 4px;
|
left: 4px;
|
||||||
|
|
||||||
&::after {
|
&::after {
|
||||||
left: 67px;
|
left: 67px;
|
||||||
}
|
}
|
||||||
@ -98,6 +99,7 @@
|
|||||||
.date {
|
.date {
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
|
|
||||||
&.month {
|
&.month {
|
||||||
width: 1.4rem;
|
width: 1.4rem;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
@ -120,6 +122,7 @@
|
|||||||
z-index: 1;
|
z-index: 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&.day {
|
&.day {
|
||||||
font-size: 85%;
|
font-size: 85%;
|
||||||
font-family: 'Lato', sans-serif;
|
font-family: 'Lato', sans-serif;
|
||||||
@ -127,7 +130,7 @@
|
|||||||
margin-right: -2px;
|
margin-right: -2px;
|
||||||
width: 1.2rem;
|
width: 1.2rem;
|
||||||
position: relative;
|
position: relative;
|
||||||
left: -.15rem;
|
left: -0.15rem;
|
||||||
}
|
}
|
||||||
} // #archives .date
|
} // #archives .date
|
||||||
|
|
||||||
@ -136,6 +139,7 @@
|
|||||||
@media all and (max-width: 576px) {
|
@media all and (max-width: 576px) {
|
||||||
#archives {
|
#archives {
|
||||||
margin-top: -1rem;
|
margin-top: -1rem;
|
||||||
|
|
||||||
ul {
|
ul {
|
||||||
letter-spacing: 0;
|
letter-spacing: 0;
|
||||||
}
|
}
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
.dash {
|
.dash {
|
||||||
margin: 0 .5rem .6rem .5rem;
|
margin: 0 0.5rem 0.6rem 0.5rem;
|
||||||
border-bottom: 2px dotted var(--dash-color);
|
border-bottom: 2px dotted var(--dash-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -60,8 +60,9 @@
|
|||||||
#page-tag {
|
#page-tag {
|
||||||
ul > li {
|
ul > li {
|
||||||
&::before {
|
&::before {
|
||||||
margin: 0 .5rem;
|
margin: 0 0.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
> a {
|
> a {
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
@ -22,24 +22,29 @@
|
|||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
border: 1px solid var(--btn-paginator-border-color);
|
border: 1px solid var(--btn-paginator-border-color);
|
||||||
background-color: var(--button-bg);
|
background-color: var(--button-bg);
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
background-color: var(--btn-paginator-hover-color);
|
background-color: var(--btn-paginator-hover-color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&.active {
|
&.active {
|
||||||
.page-link {
|
.page-link {
|
||||||
background-color: var(--btn-paginator-hover-color);
|
background-color: var(--btn-paginator-hover-color);
|
||||||
color: var(--btn-text-color);
|
color: var(--btn-text-color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&.disabled {
|
&.disabled {
|
||||||
cursor: not-allowed;
|
cursor: not-allowed;
|
||||||
|
|
||||||
.page-link {
|
.page-link {
|
||||||
color: rgba(108, 117, 125, 0.57);
|
color: rgba(108, 117, 125, 0.57);
|
||||||
border-color: var(--btn-paginator-border-color);
|
border-color: var(--btn-paginator-border-color);
|
||||||
background-color: var(--button-bg);
|
background-color: var(--button-bg);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&:first-child .page-link,
|
&:first-child .page-link,
|
||||||
&:last-child .page-link {
|
&:last-child .page-link {
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
@ -70,6 +75,7 @@
|
|||||||
i {
|
i {
|
||||||
font-size: 0.73rem;
|
font-size: 0.73rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
span:not(:last-child) {
|
span:not(:last-child) {
|
||||||
margin-right: 1.2rem;
|
margin-right: 1.2rem;
|
||||||
}
|
}
|
||||||
@ -79,6 +85,7 @@
|
|||||||
margin-top: 0.6rem;
|
margin-top: 0.6rem;
|
||||||
margin-bottom: 0.6rem;
|
margin-bottom: 0.6rem;
|
||||||
color: var(--post-list-text-color);
|
color: var(--post-list-text-color);
|
||||||
|
|
||||||
> p {
|
> p {
|
||||||
/* Make preview shorter on the homepage */
|
/* Make preview shorter on the homepage */
|
||||||
margin: 0;
|
margin: 0;
|
||||||
@ -96,13 +103,13 @@
|
|||||||
padding-left: 3px;
|
padding-left: 3px;
|
||||||
color: var(--pin-color);
|
color: var(--pin-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
> span {
|
> span {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
} // .post-preview
|
} // .post-preview
|
||||||
|
|
||||||
} // #post-list
|
} // #post-list
|
||||||
|
|
||||||
/* Hide SideBar and TOC */
|
/* Hide SideBar and TOC */
|
||||||
@ -122,9 +129,9 @@
|
|||||||
|
|
||||||
/* Sidebar is visible */
|
/* Sidebar is visible */
|
||||||
@media all and (min-width: 831px) {
|
@media all and (min-width: 831px) {
|
||||||
|
|
||||||
#post-list {
|
#post-list {
|
||||||
margin-top: 1.5rem;
|
margin-top: 1.5rem;
|
||||||
|
|
||||||
.post-preview .post-meta {
|
.post-preview .post-meta {
|
||||||
.pin {
|
.pin {
|
||||||
background: var(--pin-bg);
|
background: var(--pin-bg);
|
||||||
|
@ -131,9 +131,11 @@
|
|||||||
top: 4rem;
|
top: 4rem;
|
||||||
transition: top 0.2s ease-in-out;
|
transition: top 0.2s ease-in-out;
|
||||||
animation: fade-up 0.8s;
|
animation: fade-up 0.8s;
|
||||||
|
|
||||||
&.topbar-down {
|
&.topbar-down {
|
||||||
top: 6rem;
|
top: 6rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
> span {
|
> span {
|
||||||
@include panel-label;
|
@include panel-label;
|
||||||
}
|
}
|
||||||
@ -162,6 +164,7 @@ nav[data-toggle=toc] {
|
|||||||
> h3 {
|
> h3 {
|
||||||
@include label(1.1rem, 600);
|
@include label(1.1rem, 600);
|
||||||
}
|
}
|
||||||
|
|
||||||
.card {
|
.card {
|
||||||
border-color: var(--card-border-color);
|
border-color: var(--card-border-color);
|
||||||
background-color: var(--card-bg);
|
background-color: var(--card-bg);
|
||||||
@ -169,9 +172,11 @@ nav[data-toggle=toc] {
|
|||||||
-webkit-transition: all 0.3s ease-in-out;
|
-webkit-transition: all 0.3s ease-in-out;
|
||||||
-moz-transition: all 0.3s ease-in-out;
|
-moz-transition: all 0.3s ease-in-out;
|
||||||
transition: all 0.3s ease-in-out;
|
transition: all 0.3s ease-in-out;
|
||||||
|
|
||||||
h3 {
|
h3 {
|
||||||
color: var(--text-color);
|
color: var(--text-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
-webkit-transform: translate3d(0, -3px, 0);
|
-webkit-transform: translate3d(0, -3px, 0);
|
||||||
transform: translate3d(0, -3px, 0);
|
transform: translate3d(0, -3px, 0);
|
||||||
@ -200,6 +205,7 @@ nav[data-toggle=toc] {
|
|||||||
ul {
|
ul {
|
||||||
list-style-type: none;
|
list-style-type: none;
|
||||||
padding-inline-start: 1.5rem;
|
padding-inline-start: 1.5rem;
|
||||||
|
|
||||||
> li::before {
|
> li::before {
|
||||||
background: #c2c9d4;
|
background: #c2c9d4;
|
||||||
width: 5px;
|
width: 5px;
|
||||||
@ -238,17 +244,21 @@ nav[data-toggle=toc] {
|
|||||||
|
|
||||||
.share-icons {
|
.share-icons {
|
||||||
font-size: 1.2rem;
|
font-size: 1.2rem;
|
||||||
|
|
||||||
a {
|
a {
|
||||||
&:not(:last-child) {
|
&:not(:last-child) {
|
||||||
margin-right: 0.25rem;
|
margin-right: 0.25rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
|
|
||||||
> i {
|
> i {
|
||||||
@extend %btn-share-hovor;
|
@extend %btn-share-hovor;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
> i {
|
> i {
|
||||||
position: relative;
|
position: relative;
|
||||||
bottom: 1px;
|
bottom: 1px;
|
||||||
@ -259,16 +269,20 @@ nav[data-toggle=toc] {
|
|||||||
@extend %btn-share-hovor;
|
@extend %btn-share-hovor;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.fab {
|
.fab {
|
||||||
&.fa-twitter {
|
&.fa-twitter {
|
||||||
@include btn-sharing-color(rgba(29, 161, 242, 1));
|
@include btn-sharing-color(rgba(29, 161, 242, 1));
|
||||||
}
|
}
|
||||||
|
|
||||||
&.fa-facebook-square {
|
&.fa-facebook-square {
|
||||||
@include btn-sharing-color(rgb(66, 95, 156));
|
@include btn-sharing-color(rgb(66, 95, 156));
|
||||||
}
|
}
|
||||||
|
|
||||||
&.fa-telegram {
|
&.fa-telegram {
|
||||||
@include btn-sharing-color(rgb(39, 159, 217));
|
@include btn-sharing-color(rgb(39, 159, 217));
|
||||||
}
|
}
|
||||||
|
|
||||||
&.fa-weibo {
|
&.fa-weibo {
|
||||||
@include btn-sharing-color(rgb(229, 20, 43));
|
@include btn-sharing-color(rgb(229, 20, 43));
|
||||||
}
|
}
|
||||||
@ -292,8 +306,10 @@ nav[data-toggle=toc] {
|
|||||||
|
|
||||||
.license-wrapper {
|
.license-wrapper {
|
||||||
line-height: 1.2rem;
|
line-height: 1.2rem;
|
||||||
|
|
||||||
> a {
|
> a {
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
@extend %link-hover;
|
@extend %link-hover;
|
||||||
}
|
}
|
||||||
@ -308,7 +324,8 @@ nav[data-toggle=toc] {
|
|||||||
.post-tail-bottom {
|
.post-tail-bottom {
|
||||||
-ms-flex-wrap: wrap-reverse !important;
|
-ms-flex-wrap: wrap-reverse !important;
|
||||||
flex-wrap: wrap-reverse !important;
|
flex-wrap: wrap-reverse !important;
|
||||||
>div:first-child {
|
|
||||||
|
> div:first-child {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
margin-top: 1rem;
|
margin-top: 1rem;
|
||||||
}
|
}
|
||||||
@ -324,9 +341,10 @@ nav[data-toggle=toc] {
|
|||||||
@media all and (min-width: 768px) {
|
@media all and (min-width: 768px) {
|
||||||
#post-wrapper {
|
#post-wrapper {
|
||||||
.post-meta {
|
.post-meta {
|
||||||
>div:not(:first-child)::before {
|
> div:not(:first-child)::before {
|
||||||
@include dot(0.5rem, 0.2rem);
|
@include dot(0.5rem, 0.2rem);
|
||||||
}
|
}
|
||||||
|
|
||||||
&.flex-column {
|
&.flex-column {
|
||||||
-webkit-box-orient: horizontal !important;
|
-webkit-box-orient: horizontal !important;
|
||||||
-webkit-box-direction: normal !important;
|
-webkit-box-direction: normal !important;
|
||||||
@ -342,7 +360,7 @@ nav[data-toggle=toc] {
|
|||||||
.post-navigation {
|
.post-navigation {
|
||||||
padding-left: 0;
|
padding-left: 0;
|
||||||
padding-right: 0;
|
padding-right: 0;
|
||||||
margin-left: -.5rem;
|
margin-left: -0.5rem;
|
||||||
margin-right: -.5rem;
|
margin-right: -0.5rem;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -10,6 +10,7 @@
|
|||||||
letter-spacing: 0;
|
letter-spacing: 0;
|
||||||
border: 1px solid var(--tag-border) !important;
|
border: 1px solid var(--tag-border) !important;
|
||||||
box-shadow: 0 0 3px 0 var(--tag-shadow);
|
box-shadow: 0 0 3px 0 var(--tag-shadow);
|
||||||
|
|
||||||
span {
|
span {
|
||||||
margin-left: 0.6em;
|
margin-left: 0.6em;
|
||||||
font-size: 0.7em;
|
font-size: 0.7em;
|
||||||
|
@ -6,7 +6,7 @@ layout: compress
|
|||||||
{% for post in site.posts %}
|
{% for post in site.posts %}
|
||||||
{
|
{
|
||||||
"title": "{{ post.title | escape }}",
|
"title": "{{ post.title | escape }}",
|
||||||
"url": "{{ site.baseurl }}{{ post.url }}",
|
"url": "{{ post.url | relative_url }}",
|
||||||
"categories": "{{ post.categories | join: ', '}}",
|
"categories": "{{ post.categories | join: ', '}}",
|
||||||
"tags": "{{ post.tags | join: ', ' }}",
|
"tags": "{{ post.tags | join: ', ' }}",
|
||||||
"date": "{{ post.date }}",
|
"date": "{{ post.date }}",
|
||||||
|
2
assets/js/dist/categories.min.js
vendored
2
assets/js/dist/categories.min.js
vendored
@ -1,5 +1,5 @@
|
|||||||
/*!
|
/*!
|
||||||
* Chirpy v4.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
* Chirpy v4.3.4 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
||||||
* © 2019 Cotes Chung
|
* © 2019 Cotes Chung
|
||||||
* MIT Licensed
|
* MIT Licensed
|
||||||
*/
|
*/
|
||||||
|
2
assets/js/dist/commons.min.js
vendored
2
assets/js/dist/commons.min.js
vendored
@ -1,5 +1,5 @@
|
|||||||
/*!
|
/*!
|
||||||
* Chirpy v4.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
* Chirpy v4.3.4 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
||||||
* © 2019 Cotes Chung
|
* © 2019 Cotes Chung
|
||||||
* MIT Licensed
|
* MIT Licensed
|
||||||
*/
|
*/
|
||||||
|
2
assets/js/dist/home.min.js
vendored
2
assets/js/dist/home.min.js
vendored
@ -1,5 +1,5 @@
|
|||||||
/*!
|
/*!
|
||||||
* Chirpy v4.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
* Chirpy v4.3.4 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
||||||
* © 2019 Cotes Chung
|
* © 2019 Cotes Chung
|
||||||
* MIT Licensed
|
* MIT Licensed
|
||||||
*/
|
*/
|
||||||
|
2
assets/js/dist/page.min.js
vendored
2
assets/js/dist/page.min.js
vendored
@ -1,5 +1,5 @@
|
|||||||
/*!
|
/*!
|
||||||
* Chirpy v4.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
* Chirpy v4.3.4 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
||||||
* © 2019 Cotes Chung
|
* © 2019 Cotes Chung
|
||||||
* MIT Licensed
|
* MIT Licensed
|
||||||
*/
|
*/
|
||||||
|
4
assets/js/dist/post.min.js
vendored
4
assets/js/dist/post.min.js
vendored
File diff suppressed because one or more lines are too long
2
assets/js/dist/pvreport.min.js
vendored
2
assets/js/dist/pvreport.min.js
vendored
@ -1,5 +1,5 @@
|
|||||||
/*!
|
/*!
|
||||||
* Chirpy v4.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
* Chirpy v4.3.4 (https://github.com/cotes2020/jekyll-theme-chirpy/)
|
||||||
* © 2019 Cotes Chung
|
* © 2019 Cotes Chung
|
||||||
* MIT Licensed
|
* MIT Licensed
|
||||||
*/
|
*/
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
<div align="right">
|
<div align="right">
|
||||||
|
|
||||||
中文(简体) /
|
[EN](https://github.com/cotes2020/jekyll-theme-chirpy#readme) / 中文
|
||||||
[EN](https://github.com/cotes2020/jekyll-theme-chirpy#readme)
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -9,15 +8,15 @@
|
|||||||
|
|
||||||
# Chirpy Jekyll Theme
|
# Chirpy Jekyll Theme
|
||||||
|
|
||||||
|
一款简约而强大、采用响应式设计的 Jekyll 主题,适合展示专业写作内容。
|
||||||
|
|
||||||
[](https://rubygems.org/gems/jekyll-theme-chirpy)
|
[](https://rubygems.org/gems/jekyll-theme-chirpy)
|
||||||
[](https://github.com/cotes2020/jekyll-theme-chirpy/actions?query=branch%3Amaster+event%3Apush)
|
[](https://github.com/cotes2020/jekyll-theme-chirpy/actions?query=branch%3Amaster+event%3Apush)
|
||||||
[](https://app.codacy.com/manual/cotes2020/jekyll-theme-chirpy?utm_source=github.com&utm_medium=referral&utm_content=cotes2020/jekyll-theme-chirpy&utm_campaign=Badge_Grade_Dashboard)
|
[](https://www.codacy.com/gh/cotes2020/jekyll-theme-chirpy/dashboard?utm_source=github.com&utm_medium=referral&utm_content=cotes2020/jekyll-theme-chirpy&utm_campaign=Badge_Grade)
|
||||||
[](https://github.com/cotes2020/jekyll-theme-chirpy/blob/master/LICENSE)
|
[](https://github.com/cotes2020/jekyll-theme-chirpy/blob/master/LICENSE)
|
||||||
[](https://996.icu)
|
[](https://996.icu)
|
||||||
|
|
||||||
一款简约而强大、采用响应式设计的 Jekyll 主题,适合展示专业写作内容。
|
[**线上体验 →**](https://chirpy.cotes.info)
|
||||||
|
|
||||||
**[线上体验 →](https://chirpy.cotes.info)**
|
|
||||||
|
|
||||||
[](https://chirpy.cotes.info)
|
[](https://chirpy.cotes.info)
|
||||||
|
|
||||||
@ -53,9 +52,8 @@
|
|||||||
|
|
||||||
有两种方式可以创建一个使用本主题的仓库:
|
有两种方式可以创建一个使用本主题的仓库:
|
||||||
|
|
||||||
- **[使用 Chirpy Starter](#使用-chirpy-starter)** - 易于版本升级,隔离无关的主题项目文件,让您的仓库舒适清爽。
|
- [**使用 Chirpy Starter**](#使用-chirpy-starter) - 易于版本升级,隔离无关的主题项目文件,让您的仓库舒适清爽。
|
||||||
|
- [**从 GitHub 上 Fork**](#从-github-上-fork) - 对个性化二次开发友好,但是难于升级。除非您决定魔改此款主题或者参与代码贡献,否则不推荐使用此方式。
|
||||||
- **[从 GitHub 上 Fork](#从-github-上-fork)** - 对个性化二次开发友好,但是难于升级。除非您决定魔改此款主题或者参与代码贡献,否则不推荐使用此方式。
|
|
||||||
|
|
||||||
#### 使用 Chirpy Starter
|
#### 使用 Chirpy Starter
|
||||||
|
|
||||||
@ -76,6 +74,7 @@ $ bash tools/init.sh
|
|||||||
上述脚本将会:
|
上述脚本将会:
|
||||||
|
|
||||||
1. 从您的仓库中删除了:
|
1. 从您的仓库中删除了:
|
||||||
|
|
||||||
- `.travis.yml`
|
- `.travis.yml`
|
||||||
- `_posts` 下的文件
|
- `_posts` 下的文件
|
||||||
- `docs` 目录
|
- `docs` 目录
|
||||||
@ -189,6 +188,7 @@ $ docker run -it --rm \
|
|||||||
这取决于您如何使用这个 theme:
|
这取决于您如何使用这个 theme:
|
||||||
|
|
||||||
- 如果您是使用 theme gem(`Gemfile` 会有 `gem "jekyll-theme-chirpy"`),编辑 `Gemfile` 并更新 them gem 的版本号,譬如:
|
- 如果您是使用 theme gem(`Gemfile` 会有 `gem "jekyll-theme-chirpy"`),编辑 `Gemfile` 并更新 them gem 的版本号,譬如:
|
||||||
|
|
||||||
```diff
|
```diff
|
||||||
- gem "jekyll-theme-chirpy", "~> 3.2", ">= 3.2.1"
|
- gem "jekyll-theme-chirpy", "~> 3.2", ">= 3.2.1"
|
||||||
+ gem "jekyll-theme-chirpy", "~> 3.3", ">= 3.3.0"
|
+ gem "jekyll-theme-chirpy", "~> 3.3", ">= 3.3.0"
|
||||||
|
@ -89,6 +89,5 @@ exports.liveRebuild = () => {
|
|||||||
`${ JS_SRC }/lib/*.js`
|
`${ JS_SRC }/lib/*.js`
|
||||||
],
|
],
|
||||||
buildJs
|
buildJs
|
||||||
)
|
);
|
||||||
}
|
};
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
Gem::Specification.new do |spec|
|
Gem::Specification.new do |spec|
|
||||||
spec.name = "jekyll-theme-chirpy"
|
spec.name = "jekyll-theme-chirpy"
|
||||||
spec.version = "4.3.0"
|
spec.version = "4.3.4"
|
||||||
spec.authors = ["Cotes Chung"]
|
spec.authors = ["Cotes Chung"]
|
||||||
spec.email = ["cotes.chung@gmail.com"]
|
spec.email = ["cotes.chung@gmail.com"]
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "jekyll-theme-chirpy",
|
"name": "jekyll-theme-chirpy",
|
||||||
"version": "4.3.0",
|
"version": "4.3.4",
|
||||||
"description": "A minimal, sidebar, responsive web design Jekyll theme that focuses on text presentation.",
|
"description": "A minimal, sidebar, responsive web design Jekyll theme that focuses on text presentation.",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"directories": {
|
"directories": {
|
||||||
|
@ -69,7 +69,7 @@ init_files() {
|
|||||||
rm -f "$_workflow.$TEMP_SUFFIX"
|
rm -f "$_workflow.$TEMP_SUFFIX"
|
||||||
|
|
||||||
## Cleanup image settings in site config
|
## Cleanup image settings in site config
|
||||||
sed -i.$TEMP_SUFFIX "s/^img_cdn:.*/img_cdn: ''/;s/^avatar:.*/avatar: ''/" _config.yml
|
sed -i.$TEMP_SUFFIX "s/^img_cdn:.*/img_cdn:/;s/^avatar:.*/avatar:/" _config.yml
|
||||||
rm -f _config.yml.$TEMP_SUFFIX
|
rm -f _config.yml.$TEMP_SUFFIX
|
||||||
|
|
||||||
fi
|
fi
|
||||||
@ -83,7 +83,7 @@ init_files() {
|
|||||||
rm -rf _posts/* docs
|
rm -rf _posts/* docs
|
||||||
|
|
||||||
# save changes
|
# save changes
|
||||||
git add -A && git add .github -f
|
git add -A
|
||||||
git commit -m "[Automation] Initialize the environment." -q
|
git commit -m "[Automation] Initialize the environment." -q
|
||||||
|
|
||||||
echo "[INFO] Initialization successful!"
|
echo "[INFO] Initialization successful!"
|
||||||
|
@ -28,6 +28,16 @@ check() {
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
## Remove unnecessary theme settings
|
||||||
|
cleanup_config() {
|
||||||
|
cp _config.yml _config.yml.bak
|
||||||
|
sed -i "s/^img_cdn:.*/img_cdn:/;s/^avatar:.*/avatar:/" _config.yml
|
||||||
|
}
|
||||||
|
|
||||||
|
resume_config() {
|
||||||
|
mv _config.yml.bak _config.yml
|
||||||
|
}
|
||||||
|
|
||||||
release() {
|
release() {
|
||||||
_default_branch="$(git symbolic-ref refs/remotes/origin/HEAD | sed 's@^refs/remotes/origin/@@')"
|
_default_branch="$(git symbolic-ref refs/remotes/origin/HEAD | sed 's@^refs/remotes/origin/@@')"
|
||||||
_version="$(grep "spec.version" jekyll-theme-chirpy.gemspec | sed 's/.*= "//;s/".*//')" # X.Y.Z
|
_version="$(grep "spec.version" jekyll-theme-chirpy.gemspec | sed 's/.*= "//;s/".*//')" # X.Y.Z
|
||||||
@ -49,9 +59,10 @@ release() {
|
|||||||
|
|
||||||
# build a gem package
|
# build a gem package
|
||||||
echo -e "Build the gem pakcage for v$_version\n"
|
echo -e "Build the gem pakcage for v$_version\n"
|
||||||
|
cleanup_config
|
||||||
rm -f ./*.gem
|
rm -f ./*.gem
|
||||||
gem build "$GEM_SPEC"
|
gem build "$GEM_SPEC"
|
||||||
|
resume_config
|
||||||
}
|
}
|
||||||
|
|
||||||
main() {
|
main() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user