Skip to content

Commit 9ce8993

Browse files
committed
Updated Docs.
1 parent 76b13e6 commit 9ce8993

8 files changed

Lines changed: 355 additions & 62 deletions

.github/FUNDING.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
custom: ['https://www.buymeacoffee.com/6wOkxTo', 'https://cotes.gitee.io/alipay-wechat-donation']
1+
custom: ['https://www.buymeacoffee.com/coteschung', 'https://cotes.gitee.io/alipay-wechat-donation']

README.md

Lines changed: 79 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,21 @@
22

33
[![Build Status](https://travis-ci.com/cotes2020/jekyll-theme-chirpy.svg?branch=master)](https://travis-ci.com/cotes2020/jekyll-theme-chirpy)
44
[![GitHub license](https://img.shields.io/github/license/cotes2020/jekyll-theme-chirpy.svg)](https://github.com/cotes2020/jekyll-theme-chirpy/blob/master/LICENSE)
5-
[![996.icu](https://img.shields.io/badge/link-996.icu-red.svg)](https://996.icu)
5+
[![996.icu](https://img.shields.io/badge/link-996.icu-%23FF4D5B.svg)](https://996.icu)
6+
7+
English | [中文](README_zh-CN.md)
68

79
![devices-mockup](https://raw.githubusercontent.com/cotes2020/jekyll-theme-chirpy/master/assets/img/sample/devices-mockup.png)
810

9-
A minimal, portfolio, sidebar, bootstrap Jekyll theme with responsive web design and focuses on text presentation. Hope you like it! [Live Demo »](https://chirpy.cotes.info)
11+
A minimal, portfolio, sidebar, bootstrap Jekyll theme with responsive web design and focuses on text exhibition. It will help you easily record, manage and share your knowledge and experience. Hope you like it! [**Live Demo** »](https://chirpy.cotes.info)
12+
1013

1114
## Features
1215

16+
* Auto Dark Mode
1317
* Posts' Last Modified Date
1418
* Table of Contents
19+
* Recommand Related Post Automatically
1520
* Disqus Comments
1621
* Syntax highlighting
1722
* Two Level Categories
@@ -23,18 +28,18 @@ A minimal, portfolio, sidebar, bootstrap Jekyll theme with responsive web design
2328
* SEO Tag
2429
* Performance Optimization
2530

26-
## Getting Started
31+
## Quick Start
2732

2833
### Preparation
2934

3035
Follow the [Jekyll Docs](https://jekyllrb.com/docs/installation/) to complete the installtion of basic environment (Ruby, RubyGem, Bundler and Jekyll). In addition, to use the funny script tools, we also need to install [Python](https://www.python.org/downloads/)(version 3.5 or abover) and [ruamel.yaml](https://pypi.org/project/ruamel.yaml/).
3136

32-
Next, [fork](https://github.com/cotes2020/jekyll-theme-chirpy/fork) **Chirpy** and then clone your replicated repository locally.
37+
Next, [fork](https://github.com/cotes2020/jekyll-theme-chirpy/fork) **Chirpy** and then clone your forked repo locally.
3338

3439

3540
### Install Jekyll Plugins
3641

37-
Go to root directory of the repository and run the following:
42+
Go to the root of repo and run:
3843

3944
```terminal
4045
$ bundle install
@@ -56,7 +61,7 @@ jekyll-theme-chirpy/
5661
├── _scripts
5762
│ └── travis # CI stuff, remove it
5863
├── .travis.yml # remove this, too
59-
├── .github # remove
64+
├── .github # remove it
6065
├── assets
6166
├── tabs
6267
│   └── about.md # the ABOUT page
@@ -74,20 +79,34 @@ jekyll-theme-chirpy/
7479
```
7580

7681

82+
As mentioned above, some files or directories should be removed from your repo:
83+
84+
- .travis.yml
85+
- .github
86+
- _scripts/travis
87+
88+
7789
### Configuration
7890

7991
Customize the variables in file `_config.yml` as needed.
8092

93+
* Avatar
94+
95+
The sample avatar is `/assets/img/sample/avatar.jpg`. It should be replaced by your own one. Notice that a huge image file will increase the load time of your site, so keep your avatar size as samll as possible(may be *<https://tinypng.com/>* will help).
8196

82-
### Atom Feed
97+
* TimeZone
8398

84-
The Atom feed url of your site will be:
99+
To ensure that the posts' release date matches the city you live in, please modify the field `timezone` correctly. A list of all available values can be found on [TimezoneConverter](http://www.timezoneconverter.com/cgi-bin/findzone/findzone) or [Wikipedia](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
85100

86-
```
87-
<SITE_URL>/feed.xml
88-
```
101+
* Atom Feed
102+
103+
The Atom feed url of your site will be:
104+
105+
```
106+
<SITE_URL>/feed.xml
107+
```
89108
90-
The `SITE_URL` was defined by variable `url` in file `_config.yml`.
109+
The `SITE_URL` was defined by variable `url` of `_config.yml`.
91110
92111
93112
### Run Locally
@@ -104,53 +123,84 @@ Open a brower and visit <http://localhost:4000>.
104123

105124
Few days later, you may find that the file changes does not refresh in real time by using `run.sh`. Don't worry, the advanced option `-r` (or `--realtime`) will solve this problem, but it requires [**fswatch**](http://emcrisostomo.github.io/fswatch/) to be installed on your machine.
106125

107-
108126
### Deploying to GitHub Pages
109127

110-
Before the deployment begins, ensure the `url` in `_config.yml` has been set to `https://<username>.github.io`.
128+
Before the deployment begins, ensure the `url` in file `_config.yml` has been set to `https://<username>.github.io`(or the custom domain, if you have. e.g. `https://yourdomain.com`).
111129

112130
#### Option 1: Built by GitHub Pages
113131

114-
By deploying your site in this way, you can push the source code to GitHub repository directly.
132+
By deploying the site in this way, you're allowed to push the source code directly to the remote.
133+
134+
> **Note**: If you want to use any third-party Jekyll plugins that not in [this list](https://pages.github.com/versions/), stop reading the current approach and go to [*Option 2: Build locally*](#option-2-build-locally).
115135
116-
> **Note**: If you want to add any third-party Jekyll plugins or custom scripts to your project, please refer to [*Option 2: Build locally*](#option-2-build-locally).
136+
**1**. Rename the repository to:
117137

118-
**1**. Rename your repository as `<username>.github.io`.
138+
|Site Type | Repo's Name|
139+
|:---|:---|
140+
|User or Organization | `<username>.github.io`|
141+
|Project| any one except `<username>.github.io`, let's say `project`|
119142

120-
**2**. Commit the changes of your repository, then run the initialization script:
143+
**2**. Commit the changes of the repo first, then run the initialization script:
121144

122145
```console
123146
$ bash tools/init.sh
124147
```
125148

126-
It will automatically generates the *Latest Modified Date* and *Categories / Tags* page for the posts.
149+
it will automatically generates the *Latest Modified Date* and *Categories / Tags* page for the posts.
127150

128-
**3**. Push the changes to `origin/master` then go to GitHub website and enable GitHub Pages service for the repository `<username>.github.io`.
151+
**3**. Push the changes to `origin/master` then go to GitHub website and enable GitHub Pages service for the repo.
129152

130-
**4**. Visit `https://<username>.github.io` and enjoy.
153+
**4**. Check it out:
154+
155+
|Site Type | Site URL |
156+
|:---|:---|
157+
|User or Organization | `https://<username>.github.io/`|
158+
|Project| `https://<username>.github.io/project/`|
131159

132160

133161
#### Option 2: Build Locally
134162

135-
For security reasons, GitHub Pages runs on `safe` mode, which means the third-party Jekyll plugins or custom scripts will not work. If you want to use any another third-party Jekyll plugins, **your have to build locally rather than on GitHub Pages**.
163+
For security reasons, GitHub Pages runs on `safe` mode, which means the third-party Jekyll plugins or custom scripts won't work. If you want to use any another plugins that not in the [whitelist](https://pages.github.com/versions/), **you have to generate the site locally rather than on GitHub Pages**.
164+
165+
**1**. Browse to GitHub website, create a brand new repo named:
166+
167+
|Site Type | Repo's Name|
168+
|:---|:---|
169+
|User or Organization | `<username>.github.io`|
170+
|Project| any one except `<username>.github.io`, let's say `project`|
136171

137-
**1**. On GitHub website, create a brand new repository with name `<username>.github.io` and then clone it locally.
172+
and clone it.
138173

139-
**2**. Build your site by:
174+
**2**. In the root of the source project, build your site by:
140175

141176
```console
142-
$ bash tools/build.sh -d /path/to/<username>.github.io/
177+
$ bash tools/build.sh -d /path/to/local/project/
143178
```
144179

145-
The build results will be stored in the root directory of `<username>.github.io` and don't forget to push the changes of `<username>.github.io` to branch `master` on GitHub.
180+
If you prefer to the Project site, change `baseurl` of file `_config.yml` to your project name, starting with a slash. e.g. `/project`. Or, simply add argument `-b /project` behide the command above.
181+
182+
The generated static files will be placed in the root of `/path/to/local/project`. Commit and push the changes to the `master` branch on GitHub.
183+
184+
**3**. Go to GitHub website and enable Pages service for the new repository.
146185

147-
**3**. Go to GitHub website and enable GitHub Pages service for the new repository `<username>.github.io`.
186+
**4**. Visit at:
187+
188+
|Site Type | Site URL |
189+
|:---|:---|
190+
|User or Organization | `https://<username>.github.io/`|
191+
|Project| `https://<username>.github.io/project/`|
192+
193+
and enjoy!
148194

149-
**4**. Visit `https://<username>.github.io` and enjoy.
150195

151196
## Documentation
152197

153-
For more information, please see the [tutorial](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).
198+
For more information, please check out the [tutorial](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).
199+
200+
## Sponsor
201+
202+
Want to buy me a coffee? Click the button <kbd>❤️Sponsor</kbd> at the top of the [Home Page](https://github.com/cotes2020/jekyll-theme-chirpy) and choose a link that suits you to donate. I'd really appreciate it and take it as encouragement to work on better projects.
203+
154204

155205

156206
## License

0 commit comments

Comments
 (0)