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
Moved information about creating your repo to front (alshedivat#1298)
Moved information about using this template to the beginning of the
installation part, added a few more documentation links in it, fixed
some typos.
---------
Signed-off-by: George Araújo <[email protected]>
Want to learn more about Jekyll? Check out [this tutorial](https://www.taniarascia.com/make-a-static-website-with-jekyll/).
173
170
Why Jekyll? Read [Andrej Karpathy's blog post](https://karpathy.github.io/2014/07/01/switching-to-jekyll/)!
174
171
175
-
176
172
### Installation
177
173
178
174
For a hands-on walkthrough of al-folio installation, check out [this cool video tutorial](https://www.youtube.com/watch?v=g6AJ9qPPoyc) by one of the community members! 🎬 🍿
179
175
176
+
The preferred way of using this template is by clicking in [Use this template](https://docs.github.com/en/repositories/creating-and-managing-repositories/creating-a-repository-from-a-template#creating-a-repository-from-a-template) above the file list.
177
+
Then, create a new repository at `github.com:<your-username>/<your-repo-name>`. If you plan to upload your site to `<your-github-username>.github.io`,
178
+
note that the name of your repository must be `<your-github-username>.github.io` or `<your-github-orgname>.github.io`, as stated in the [GitHub pages docs](https://docs.github.com/en/pages/getting-started-with-github-pages/about-github-pages#types-of-github-pages-sites).
179
+
For more information on how to deploy your site, check the [Deployment](#deployment) section below. After you created your new repository, just download it to your machine:
Finally, run the following command that will pull a pre-built image from DockerHub and will run your website.
193
+
- Finally, run the following command that will pull a pre-built image from DockerHub and will run your website.
195
194
196
195
```bash
197
196
$ docker-compose up
@@ -208,9 +207,11 @@ Now, feel free to customize the theme however you like (don't forget to change t
208
207
> Note: this approach is only necessary if you would like to build an older or very custom version of al-folio.
209
208
210
209
Build and run a new docker image using:
210
+
211
211
```bash
212
212
$ docker-compose -f docker-local.yml up
213
213
```
214
+
214
215
> If you want to update jekyll, install new ruby packages, etc., all you have to do is build the image again using `--force-recreate` argument at the end of previous command! It will download ruby and jekyll and install all ruby packages again from scratch.
215
216
216
217
</details>
@@ -219,11 +220,9 @@ $ docker-compose -f docker-local.yml up
219
220
220
221
#### Local Setup (Standard)
221
222
222
-
Assuming you have [Ruby](https://www.ruby-lang.org/en/downloads/) and [Bundler](https://bundler.io/) installed on your system (*hint: for ease of managing ruby gems, consider using [rbenv](https://github.com/rbenv/rbenv)*), first click [Use this template](https://docs.github.com/repositories/creating-and-managing-repositories/creating-a-repository-from-a-template) above the file list, create a new repository at `github.com:<your-username>/<your-repo-name>` from `github.com:alshedivat/al-folio` and do the following:
223
+
Assuming you have [Ruby](https://www.ruby-lang.org/en/downloads/) and [Bundler](https://bundler.io/) installed on your system (*hint: for ease of managing ruby gems, consider using [rbenv](https://github.com/rbenv/rbenv)*).
@@ -239,19 +238,22 @@ Deploying your website to [GitHub Pages](https://pages.github.com/) is the most
239
238
Starting version [v0.3.5](https://github.com/alshedivat/al-folio/releases/tag/v0.3.5), **al-folio** will automatically re-deploy your webpage each time you push new changes to your repository! :sparkles:
240
239
241
240
**For personal and organization webpages:**
242
-
1. Rename your repository to `<your-github-username>.github.io` or `<your-github-orgname>.github.io`.
241
+
242
+
1. The name of your repository **MUST BE**`<your-github-username>.github.io` or `<your-github-orgname>.github.io`.
243
243
2. In `_config.yml`, set `url` to `https://<your-github-username>.github.io` and leave `baseurl` empty.
244
244
3. Set up automatic deployment of your webpage (see instructions below).
245
245
4. Make changes, commit, and push!
246
246
5. After deployment, the webpage will become available at `<your-github-username>.github.io`.
247
247
248
248
**For project pages:**
249
+
249
250
1. In `_config.yml`, set `url` to `https://<your-github-username>.github.io` and `baseurl` to `/<your-repository-name>/`.
250
251
2. Set up automatic deployment of your webpage (see instructions below).
251
252
3. Make changes, commit, and push!
252
253
4. After deployment, the webpage will become available at `<your-github-username>.github.io/<your-repository-name>/`.
253
254
254
255
**To enable automatic deployment:**
256
+
255
257
1. Click on **Actions** tab and **Enable GitHub Actions**; do not worry about creating any workflows as everything has already been set for you.
256
258
2. Go to Settings -> Actions -> General -> Workflow permissions, and give **Read and write permissions** to GitHub Actions
257
259
3. Make any other changes to your webpage, commit, and push. This will automatically trigger the **Deploy** action.
@@ -268,26 +270,29 @@ If you need to manually re-deploy your website to GitHub pages, go to Actions, c
268
270
<details><summary>(click to expand) <strong>Deployment to another hosting server (non GitHub Pages):</strong></summary>
269
271
270
272
If you decide to not use GitHub Pages and host your page elsewhere, simply run:
273
+
271
274
```bash
272
275
$ bundle exec jekyll build --lsi
273
276
```
277
+
274
278
which will (re-)generate the static webpage in the `_site/` folder.
275
-
Then simply copy the contents of the `_site/`foder to your hosting server.
279
+
Then simply copy the contents of the `_site/`directory to your hosting server.
276
280
277
-
**Note:** Make sure to correctly set the `url` and `baseurl` fields in `_config.yml` before building the webpage. If you are deploying your webpage to `your-domain.com/your-project/`, you must set `url: your-domain.com` and `baseurl: /your-project/`. If you are deploing directly to `your-domain.com`, leave `baseurl` blank.
281
+
**Note:** Make sure to correctly set the `url` and `baseurl` fields in `_config.yml` before building the webpage. If you are deploying your webpage to `your-domain.com/your-project/`, you must set `url: your-domain.com` and `baseurl: /your-project/`. If you are deploying directly to `your-domain.com`, leave `baseurl` blank.
278
282
279
283
</details>
280
284
281
285
<details><summary>(click to expand) <strong>Deployment to a separate repository (advanced users only):</strong></summary>
282
286
283
287
**Note:** Do not try using this method unless you know what you are doing (make sure you are familiar with [publishing sources](https://help.github.com/en/github/working-with-github-pages/about-github-pages#publishing-sources-for-github-pages-sites)). This approach allows to have the website's source code in one repository and the deployment version in a different repository.
284
288
285
-
Let's assume that your website's publishing source is a `publishing-source`sub-directory of a git-versioned repository cloned under `$HOME/repo/`.
289
+
Let's assume that your website's publishing source is a `publishing-source`subdirectory of a git-versioned repository cloned under `$HOME/repo/`.
286
290
For a user site this could well be something like `$HOME/<user>.github.io`.
287
291
288
292
Firstly, from the deployment repo dir, checkout the git branch hosting your publishing source.
289
293
290
294
Then from the website sources dir (commonly your al-folio fork's clone):
@@ -305,7 +310,7 @@ The quote below is taken directly from the [jekyll configuration docs](https://j
305
310
> Do not use an important location for `<destination>`; instead, use it as a staging area and copy files from there to your web server.
306
311
307
312
If `$HOME/repo/publishing-source` contains files that you want jekyll to leave untouched, specify them under `keep_files` in `_config.yml`.
308
-
In its default configuration, al-folio will copy the top-level `README.md` to the publishing source. If you want to change this behaviour, add `README.md` under `exclude` in `_config.yml`.
313
+
In its default configuration, al-folio will copy the top-level `README.md` to the publishing source. If you want to change this behavior, add `README.md` under `exclude` in `_config.yml`.
309
314
310
315
**Note:** Do _not_ run `jekyll clean` on your publishing source repo as this will result in the entire directory getting deleted, irrespective of the content of `keep_files` in `_config.yml`.
311
316
@@ -315,7 +320,7 @@ In its default configuration, al-folio will copy the top-level `README.md` to th
315
320
316
321
#### Upgrading from a previous version
317
322
318
-
If you installed **al-folio** as described above, you can configure a [github action](https://github.com/AndreasAugustin/actions-template-sync) to automatically sync your repository with the latest version of the theme:
323
+
If you installed **al-folio** as described above, you can configure a [GitHub action](https://github.com/AndreasAugustin/actions-template-sync) to automatically sync your repository with the latest version of the theme:
319
324
320
325
```yaml
321
326
name: Sync from template
@@ -348,13 +353,13 @@ Another option is to manually update your code by following the steps below:
348
353
# Assuming the current directory is <your-repo-name>
If you have extensively customized a previous version, it might be trickier to upgrade.
355
360
You can still follow the steps above, but `git rebase` may result in merge conflicts that must be resolved.
356
361
See [git rebase manual](https://help.github.com/en/github/using-git/about-git-rebase) and how to [resolve conflicts](https://help.github.com/en/github/using-git/resolving-merge-conflicts-after-a-git-rebase) for more information.
357
-
If rebasing is too complicated, we recommend to re-install the new version of the theme from scratch and port over your content and changes from the previous version manually.
362
+
If rebasing is too complicated, we recommend re-installing the new version of the theme from scratch and port over your content and changes from the previous version manually.
358
363
359
364
---
360
365
@@ -394,18 +399,17 @@ If you have a different question, please ask using [Discussions](https://github.
394
399
5.**Q:** My site doesn't work when I enable `related_blog_posts`. Why? <br>
395
400
**A:** This is probably due to the [classifier reborn](https://github.com/jekyll/classifier-reborn) plugin, which is used to calculate
396
401
related posts. If the error states `Liquid Exception: Zero vectors can not be normalized...`, it means that it could not calculate related
397
-
posts for a specific post. This is usually caused by [empty or really small blog posts](https://github.com/jekyll/classifier-reborn/issues/64)
398
-
without meaningful words (i.e. only [stop words](https://en.wikipedia.org/wiki/Stop_words)) or even
402
+
posts for a specific post. This is usually caused by [empty or minimal blog posts](https://github.com/jekyll/classifier-reborn/issues/64)
403
+
without meaningful words (i.e. only [stop words](https://en.wikipedia.org/wiki/Stop_words)) or even
399
404
[specific characters](https://github.com/jekyll/classifier-reborn/issues/194) you used in your posts. Also, the calculus for similar posts are
400
405
made for every `post`, which means every page that uses `layout: post`, including the announcements. To change this behavior, simply add
401
406
`related_posts: false` to the front matter of the page you don't want to display related posts on.
402
-
403
407
404
408
## Features
405
409
406
410
### Publications
407
411
408
-
Your publications page is generated automatically from your BibTex bibliography.
412
+
Your publications' page is generated automatically from your BibTex bibliography.
409
413
Simply edit `_bibliography/papers.bib`.
410
414
You can also add new `*.bib` files and customize the look of your publications however you like by editing `_pages/publications.md`.
411
415
@@ -414,15 +418,18 @@ You can also add new `*.bib` files and customize the look of your publications h
414
418
<details><summary>(click to expand) <strong>Author annotation:</strong></summary>
415
419
416
420
In publications, the author entry for yourself is identified by string array `scholar:last_name` and string array `scholar:first_name` in `_config.yml`:
417
-
```
421
+
422
+
```yaml
418
423
scholar:
419
424
last_name: [Einstein]
420
425
first_name: [Albert, A.]
421
426
```
427
+
422
428
If the entry matches one form of the last names and the first names, it will be underlined.
423
429
Keep meta-information about your co-authors in `_data/coauthors.yml` and Jekyll will insert links to their webpages automatically.
424
-
The coauthor data format in `_data/coauthors.yml` is as follows,
425
-
```
430
+
The co-author data format in `_data/coauthors.yml` is as follows,
If the entry matches one of the combinations of the last names and the first names, it will be highlighted and linked to the url provided.
446
454
447
455
</details>
@@ -454,7 +462,7 @@ There are several custom bibtex keywords that you can use to affect how the entr
454
462
- `abstract`: Adds an "Abs" button that expands a hidden text field when clicked to show the abstract text
455
463
- `arxiv`: Adds a link to the Arxiv website (Note: only add the arxiv identifier here - the link is generated automatically)
456
464
- `bibtex_show`: Adds a "Bib" button that expands a hidden text field with the full bibliography entry
457
-
-`html`: Inserts a "HTML" button redirecting to the user-specified link
465
+
- `html`: Inserts an "HTML" button redirecting to the user-specified link
458
466
- `pdf`: Adds a "PDF" button redirecting to a specified file (if a full link is not specified, the file will be assumed to be placed in the /assets/pdf/ directory)
459
467
- `supp`: Adds a "Supp" button to a specified file (if a full link is not specified, the file will be assumed to be placed in the /assets/pdf/ directory)
460
468
- `blog`: Adds a "Blog" button redirecting to the specified link
@@ -463,7 +471,7 @@ There are several custom bibtex keywords that you can use to affect how the entr
463
471
- `slides`: Adds a "Slides" button redirecting to a specified file (if a full link is not specified, the file will be assumed to be placed in the /assets/pdf/ directory)
464
472
- `website`: Adds a "Website" button redirecting to the specified link
465
473
- `altmetric`: Adds an [Altmetric](https://www.altmetric.com/) badge (Note: if DOI is provided just use `true`, otherwise only add the altmetric identifier here - the link is generated automatically)
466
-
-`dimensions`: Adds an[Dimensions](https://www.dimensions.ai/) badge (Note: if DOI or PMID is provided just use `true`, otherwise only add the dimensions identifier here - the link is generated automatically)
474
+
- `dimensions`: Adds a [Dimensions](https://www.dimensions.ai/) badge (Note: if DOI or PMID is provided just use `true`, otherwise only add the Dimensions' identifier here - the link is generated automatically)
467
475
468
476
You can implement your own buttons by editing the bib.html file.
469
477
@@ -521,14 +529,16 @@ Easily create beautiful grids within your blog posts and project pages:
521
529
522
530
### Other features
523
531
524
-
#### GitHub repositories and user stats
532
+
#### GitHub's repositories and user stats
533
+
525
534
**al-folio** uses [github-readme-stats](https://github.com/anuraghazra/github-readme-stats) and [github-profile-trophy](https://github.com/ryo-ma/github-profile-trophy)
526
-
to display GitHub repositories and user stats on the the `/repositories/` page.
535
+
to display GitHub repositories and user stats on the `/repositories/` page.
527
536
528
-
Edit the `_data/repositories.yml` and change the `github_users` and `github_repos` lists to include your own GitHub profile and repositories to the the `/repositories/` page.
537
+
Edit the `_data/repositories.yml` and change the `github_users` and `github_repos` lists to include your own GitHub profile and repositories to the `/repositories/` page.
529
538
530
539
You may also use the following codes for displaying this in any other pages.
@@ -538,7 +548,7 @@ You may also use the following codes for displaying this in any other pages.
538
548
</div>
539
549
{% endif %}
540
550
541
-
<!-- code for Github trophies -->
551
+
<!-- code for GitHub trophies -->
542
552
{% if site.repo_trophies.enabled %}
543
553
{% for user in site.data.repositories.github_users %}
544
554
{% if site.data.repositories.github_users.size > 1 %}
@@ -561,6 +571,7 @@ You may also use the following codes for displaying this in any other pages.
561
571
```
562
572
563
573
#### Theming
574
+
564
575
A variety of beautiful theme colors have been selected for you to choose from.
565
576
The default is purple, but you can quickly change it by editing the
566
577
`--global-theme-color`variable in the `_sass/_themes.scss` file.
@@ -570,6 +581,7 @@ You can also add your own colors to this file assigning each a name for ease of
570
581
use across the template.
571
582
572
583
#### Social media previews
584
+
573
585
**al-folio** supports preview images on social media.
574
586
To enable this functionality you will need to set `serve_og_meta` to `true` in your `_config.yml`.
575
587
Once you have done so, all your site's pages will include Open Graph data in the HTML head element.
@@ -580,12 +592,14 @@ If for an individual page this variable is not set, then the theme will fall bac
580
592
In both the page-specific and site-wide cases, the `og_image` variable needs to hold the URL for the image you wish to display in social media previews.
581
593
582
594
#### Atom (RSS-like) Feed
595
+
583
596
It generates an Atom (RSS-like) feed of your posts, useful for Atom and RSS readers.
584
597
The feed is reachable simply by typing after your homepage `/feed.xml`.
585
598
E.g. assuming your website mountpoint is the main folder, you can type `yourusername.github.io/feed.xml`
586
599
587
600
#### Related posts
588
-
By default, there will be a related posts section on the bottom of the blog posts.
601
+
602
+
By default, there will be a related posts section on the bottom of the blog posts.
589
603
These are generated by selecting the `max_related` most recent posts that share at least `min_common_tags` tags with the current post.
590
604
If you do not want to display related posts on a specific post, simply add `related_posts: false` to the front matter of the post.
591
605
If you want to disable it for all posts, simply set `enabled` to false in the `related_blog_posts` section in `_config.yml`.
0 commit comments