You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Change Dev Containers logo in README:
Simple Icons has removed all Microsoft icons due to copyright restrictions, see <simple-icons/simple-icons#11236>
Copy file name to clipboardExpand all lines: _posts/2019-08-09-getting-started.md
+38-29
Original file line number
Diff line number
Diff line change
@@ -11,61 +11,70 @@ pin: true
11
11
media_subpath: '/posts/20180809'
12
12
---
13
13
14
-
## Creating a site repository
14
+
## Creating a Site Repository
15
15
16
-
There are two methods to create a site repository for **Chirpy**:
16
+
When creating your site repository, you have two options depending on your needs:
17
17
18
-
-[**Using the starter**](#option-1-using-the-starter) — This approach simplifies upgrades and isolates unnecessary project files, enabling you to concentrate on your content. It's ideal for those who want a hassle-free setup focused primarily on writing.
19
-
-[**Forking the theme**](#option-2-forking-the-theme) — This method allows for customization and development but presents challenges during upgrades. It is not recommended to use this approach unless you are familiar with Jekyll and plan to modify this project.
18
+
### Option 1. Using the Starter (Recommended)
20
19
21
-
### Option 1: using the starter
20
+
This approach simplifies upgrades, isolates unnecessary files, and is perfect for users who want to focus on writing with minimal configuration.
22
21
23
22
1. Sign in to GitHub and navigate to the [**starter**][starter].
24
23
2. Click the <kbd>Use this template</kbd> button and then select <kbd>Create a new repository</kbd>.
24
+
3. Name the new repository `<username>.github.io`, replacing `username` with your lowercase GitHub username.
25
25
26
-
### Option 2: forking the theme
26
+
### Option 2. Forking the Theme
27
27
28
-
Sign in to GitHub and [fork the theme](https://github.com/cotes2020/jekyll-theme-chirpy/fork).
28
+
This approach is convenient for modifying features or UI design, but presents challenges during upgrades. So don't try this unless you are familiar with Jekyll and plan to heavily modify this theme.
29
29
30
-
## Name your new repository
30
+
1. Sign in to GitHub.
31
+
2.[Fork the theme repository](https://github.com/cotes2020/jekyll-theme-chirpy/fork).
32
+
3. Name the new repository `<username>.github.io`, replacing `username` with your lowercase GitHub username.
31
33
32
-
Rename your repository to `<username>.github.io`. The `username` represents your lowercase GitHub username.
34
+
## Setting up the Environment
33
35
34
-
## Setting up the environment
36
+
Once your repository is created, it's time to set up your development environment. There are two primary methods:
35
37
36
-
The easiest way to set up the runtime environment, especially on Windows, is by using [Dev Containers](#setting-up-in-dev-containers). This method installs all packages within a Docker container, isolating them from the host machine and ensuring no interference with existing settings.
38
+
### Using Dev Containers (Recommended for Windows)
37
39
38
-
For Unix-like systems, besides using Dev Containers, you can also [natively set up](#setting-up-natively) the runtime environment to achieve optimal performance.
40
+
Dev Containers offer an isolated environment using Docker, which prevents conflicts with your system and ensures all dependencies are managed within the container.
39
41
40
-
### Setting up in Dev Containers
42
+
**Steps**:
41
43
42
44
1. Install Docker:
43
45
- On Windows/macOS, install [Docker Desktop][docker-desktop].
44
46
- On Linux, install [Docker Engine][docker-engine].
45
47
2. Install [VS Code][vscode] and the [Dev Containers extension][dev-containers].
46
48
3. Clone your repository:
47
49
- For Docker Desktop: Start VS Code and [clone your repo in a container volume][dc-clone-in-vol].
48
-
- For Docker Engine: Clone your repo to the local disk, then launch VS Code and [open your repo in the container][dc-open-in-container].
49
-
4. Wait a few minutes for Dev Containers to finish installing.
50
+
- For Docker Engine: Clone your repo locally, then [open it in a container][dc-open-in-container] via VS Code.
51
+
4. Wait for the Dev Containers setup to complete.
50
52
51
-
### Setting up natively
53
+
### Setting up Natively (Recommended for Unix-like OS)
52
54
53
-
1. Follow the instructions in the [Jekyll Docs](https://jekyllrb.com/docs/installation/) to complete the installation of the basic environment. Ensure that [Git](https://git-scm.com/) is also installed.
54
-
2. Clone your repository to a local disk.
55
-
3. If your site is created by forking the theme, install [Node.js][nodejs] and run `bash tools/init.sh` in the root directory. This will initialize the repository files and create a commit to save the changes.
56
-
4. Install the dependencies by running `bundle`.
55
+
For Unix-like systems, you can set up the environment natively for optimal performance, though you can also use Dev Containers as an alternative.
57
56
58
-
### Start the local server
57
+
**Steps**:
58
+
59
+
1. Follow the [Jekyll installation guide](https://jekyllrb.com/docs/installation/) to install Jekyll and ensure [Git](https://git-scm.com/) is installed.
60
+
2. Clone your repository to your local machine.
61
+
3. If you forked the theme, install [Node.js][nodejs] and run `bash tools/init.sh` in the root directory to initialize the repository.
62
+
4. Run command `bundle` in the root of your repository to install the dependencies.
63
+
64
+
## Usage
65
+
66
+
### Start the Jekyll Server
59
67
60
68
To run the site locally, use the following command:
61
69
62
-
```console
70
+
```terminal
63
71
$ bundle exec jekyll s
64
72
```
65
73
66
-
After a few seconds, the local server will be available at <http://127.0.0.1:4000>.
74
+
> If you are using Dev Containers, you must run that command in the **VS Code** Terminal.
75
+
{: .prompt-info }
67
76
68
-
## Usage
77
+
After a few seconds, the local server will be available at <http://127.0.0.1:4000>.
69
78
70
79
### Configuration
71
80
@@ -76,17 +85,17 @@ Update the variables in `_config.yml`{: .filepath} as needed. Some typical optio
76
85
-`timezone`
77
86
-`lang`
78
87
79
-
### Social contact options
88
+
### Social Contact Options
80
89
81
90
Social contact options are displayed at the bottom of the sidebar. You can enable or disable specific contacts in the `_data/contact.yml`{: .filepath} file.
82
91
83
-
### Customizing the stylesheet
92
+
### Customizing the Stylesheet
84
93
85
94
To customize the stylesheet, copy the theme's `assets/css/jekyll-theme-chirpy.scss`{: .filepath} file to the same path in your Jekyll site, and add your custom styles at the end of the file.
86
95
87
96
Starting with version `6.2.0`, if you want to overwrite the SASS variables defined in `_sass/addon/variables.scss`{: .filepath}, copy the main SASS file `_sass/main.scss`{: .filepath} to the `_sass`{: .filepath} directory in your site's source, then create a new file `_sass/variables-hook.scss`{: .filepath} and assign your new values there.
88
97
89
-
### Customizing static assets
98
+
### Customizing Static Assets
90
99
91
100
Static assets configuration was introduced in version `5.1.0`. The CDN of the static assets is defined in `_data/origin/cors.yml`{: .filepath }. You can replace some of them based on the network conditions in the region where your website is published.
92
101
@@ -98,7 +107,7 @@ Before deploying, check the `_config.yml`{: .filepath} file and ensure the `url`
98
107
99
108
Now you can choose _ONE_ of the following methods to deploy your Jekyll site.
100
109
101
-
### Deploy using GitHub Actions
110
+
### Deploy Using Github Actions
102
111
103
112
Prepare the following:
104
113
@@ -119,7 +128,7 @@ Next, configure the _Pages_ service:
119
128
120
129
You can now visit the URL provided by GitHub to access your site.
121
130
122
-
### Manual build and deployment
131
+
### Manual Build and Deployment
123
132
124
133
For self-hosted servers, you will need to build the site on your local machine and then upload the site files to the server.
0 commit comments