Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/alshedivat/al-folio
Browse files Browse the repository at this point in the history
  • Loading branch information
Szymok committed Jul 9, 2024
2 parents 5ef9639 + 16cee9c commit 12e12f1
Show file tree
Hide file tree
Showing 139 changed files with 5,991 additions and 523 deletions.
31 changes: 31 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/jekyll
{
"name": "Jekyll",
"image": "mcr.microsoft.com/devcontainers/jekyll",

// Features to add to the dev container. More info: https://containers.dev/features.
"features": {
"ghcr.io/rocker-org/devcontainer-features/apt-packages:1": {
"packages": "build-essential,imagemagick,inotify-tools,jupyter-nbconvert,procps,ruby-full,zlib1g-dev"
},
"ghcr.io/devcontainers-contrib/features/prettier:1": {}
},

// Optionally: run jekyll serve automatically on container entering using the Docker entrypoint
"postAttachCommand": "./bin/entry_point.sh",

"customizations": {
"vscode": {
"extensions": ["esbenp.prettier-vscode", "sissel.shopify-liquid", "yzhang.markdown-all-in-one"],
"settings": {
// use prettier code formatter as default formatter
"editor.defaultFormatter": "esbenp.prettier-vscode",
"prettier.configPath": ".prettierrc",
"editor.formatOnSave": true
}
}
},

"remoteUser": "vscode"
}
2 changes: 1 addition & 1 deletion .github/workflows/axe.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
run: |
pip3 install --upgrade jupyter
export JEKYLL_ENV=production
bundle exec jekyll build --lsi
bundle exec jekyll build
- name: Purge unused CSS 🧹
run: |
npm install -g purgecss
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/broken-links-site.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
run: |
pip3 install --upgrade jupyter
export JEKYLL_ENV=production
bundle exec jekyll build --lsi
bundle exec jekyll build
- name: Purge unused CSS 🧹
run: |
npm install -g purgecss
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/broken-links.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,4 @@ jobs:
with:
fail: true
# removed md files that include liquid tags
args: --exclude-path README.md --exclude-path _pages/404.md --exclude-path _pages/blog.md --exclude-path _posts/2018-12-22-distill.md --verbose --no-progress './**/*.md' './**/*.html'
args: --user-agent 'curl/7.54' --exclude-path README.md --exclude-path _pages/404.md --exclude-path _pages/blog.md --exclude-path _posts/2018-12-22-distill.md --exclude-path _posts/2023-04-24-videos.md --verbose --no-progress './**/*.md' './**/*.html'
2 changes: 2 additions & 0 deletions .github/workflows/deploy-docker-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ on:
tags:
- "v*"
paths:
- ".github/workflows/deploy-docker-tag.yml"
- ".github/workflows/deploy-image.yml"
- "bin/entry_point.sh"
- "Dockerfile"
- "Gemfile"
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/deploy-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ on:
- master
- main
paths:
- ".github/workflows/deploy-image.yml"
- "bin/entry_point.sh"
- "Dockerfile"
- "Gemfile"
Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,14 @@ on:
- main
paths:
- "assets/**"
- "**.bib"
- "**.html"
- "**.js"
- "**.liquid"
- "**/*.md"
- "**.yml"
- "Gemfile"
- "Gemfile.lock"
- "!.github/workflows/axe.yml"
- "!.github/workflows/broken-links.yml"
- "!.github/workflows/deploy-docker-tag.yml"
Expand All @@ -31,11 +34,14 @@ on:
- main
paths:
- "assets/**"
- "**.bib"
- "**.html"
- "**.js"
- "**.liquid"
- "**/*.md"
- "**.yml"
- "Gemfile"
- "Gemfile.lock"
- "!.github/workflows/axe.yml"
- "!.github/workflows/broken-links.yml"
- "!.github/workflows/deploy-docker-tag.yml"
Expand Down Expand Up @@ -77,7 +83,7 @@ jobs:
run: |
pip3 install --upgrade jupyter
export JEKYLL_ENV=production
bundle exec jekyll build --lsi
bundle exec jekyll build
- name: Purge unused CSS 🧹
run: |
npm install -g purgecss
Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/docker-slim.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@ name: Docker Slim

#Only trigger, when the build workflow succeeded
on:
push:
branches:
- master
- main
paths:
- ".github/workflows/docker-slim.yml"
workflow_run:
workflows: ["Docker Image CI"]
types:
Expand All @@ -15,7 +21,7 @@ on:
jobs:
build:
# https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#running-a-workflow-based-on-the-conclusion-of-another-workflow
if: ${{ github.event.workflow_run.conclusion == 'success' }} and github.repository_owner == 'alshedivat'
if: ${{ github.event.workflow_run.conclusion == 'success' && github.repository_owner == 'alshedivat' }}
runs-on: ubuntu-latest
defaults:
run:
Expand All @@ -37,7 +43,7 @@ jobs:
sed -i "s|\.:|${{ github.workspace }}:|g" ${{ github.workspace }}/docker-compose.yml
cat ${{ github.workspace }}/docker-compose.yml
- uses: kitabisa/docker-slim-action@v1.0.3
- uses: kitabisa/docker-slim-action@v1.1.1
env:
DSLIM_PULL: true
DSLIM_COMPOSE_FILE: ${{ github.workspace }}/docker-compose.yml
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ _site
.ruby-version
.tweet-cache
Gemfile.lock
assets/libs/
node_modules/
vendor
google2faff1e60f4e9638.html
google2faff1e60f4e9638.html
.idea
4 changes: 4 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
**/*.map
**/*.min.css
**/*.min.js
assets/css/main.scss
assets/js/search-data.js
assets/js/distillpub/template.v2.js
assets/js/search/*.js
assets/plotly/demo.html
lighthouse_results/**
_posts/2015-10-20-math.md
2 changes: 2 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ We welcome your pull requests (PRs).
For minor fixes (e.g., documentation improvements), feel free to submit a PR directly.
If you would like to implement a new feature or a bug, please make sure you (or someone else) has opened an appropriate issue first; in your PR, please mention the issue it addresses.

Note that since [#2048](https://github.com/alshedivat/al-folio/pull/2048) al-folio uses the [prettier formatter](https://prettier.io/) for its code, meaning all new submitted code must conform to its standard. If you don't have `prettier` installed for your setup and the `prettier` code check fails when submitting a PR, you can check the referred failed action in our repo. In that action there will be an artifact with an HTML diff showing the needed changes.

## Issues

We use GitHub issues to track bugs and feature requests.
Expand Down
11 changes: 9 additions & 2 deletions CUSTOMIZE.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ The configuration file [\_config.yml](_config.yml) contains the main configurati

> Note that the `url` and `baseurl` settings are used to generate the links of the website, as explained in the [install instructions](INSTALL.md).
All changes made to this file are only visible after you rebuild the website. That means that you need to run `bundle exec jekyll serve --lsi` again if you are running the website locally or push your changes to GitHub if you are using GitHub Pages. All other changes are visible immediately, you only need to refresh the page.
All changes made to this file are only visible after you rebuild the website. That means that you need to run `bundle exec jekyll serve` again if you are running the website locally or push your changes to GitHub if you are using GitHub Pages. All other changes are visible immediately, you only need to refresh the page.

## Modifying the CV information

Expand Down Expand Up @@ -80,7 +80,7 @@ You can easily create your own collections, apps, short stories, courses, or wha

To add publications create a new entry in the [\_bibliography/papers.bib](_bibliography/papers.bib) file. You can find the BibTeX entry of a publication in Google Scholar by clicking on the quotation marks below the publication title, then clicking on "BibTeX", or also in the conference page itself. By default, the publications will be sorted by year and the most recent will be displayed first. You can change this behavior and more in the `Jekyll Scholar` section in [\_config.yml](_config.yml) file.

You can add extra information to a publication, like a PDF file in the `assets/pdfs/` directory and add the path to the PDF file in the BibTeX entry with the `pdf` field. Some of the supported fields are: `abstract`, `altmetric`, `arxiv`, `bibtex_show`, `blog`, `code`, `dimensions`, `doi`, `eprint`, `html`, `isbn`, `pdf`, `pmid`, `poster`, `slides`, `supp`, `video`, and `website`.
You can add extra information to a publication, like a PDF file in the `assets/pdfs/` directory and add the path to the PDF file in the BibTeX entry with the `pdf` field. Some of the supported fields are: `abstract`, `altmetric`, `annotation`, `arxiv`, `bibtex_show`, `blog`, `code`, `dimensions`, `doi`, `eprint`, `html`, `isbn`, `pdf`, `pmid`, `poster`, `slides`, `supp`, `video`, and `website`.

### Author annotation

Expand Down Expand Up @@ -124,6 +124,7 @@ There are several custom bibtex keywords that you can use to affect how the entr
- `abbr`: Adds an abbreviation to the left of the entry. You can add links to these by creating a venue.yaml-file in the \_data folder and adding entries that match.
- `abstract`: Adds an "Abs" button that expands a hidden text field when clicked to show the abstract text
- `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)
- `annotation`: Adds a popover info message to the end of the author list that can potentially be used to clarify superscripts. HTML is allowed.
- `arxiv`: Adds a link to the Arxiv website (Note: only add the arxiv identifier here - the link is generated automatically)
- `bibtex_show`: Adds a "Bib" button that expands a hidden text field with the full bibliography entry
- `blog`: Adds a "Blog" button redirecting to the specified link
Expand All @@ -145,3 +146,9 @@ A variety of beautiful theme colors have been selected for you to choose from. T
## Adding social media information

You can add your social media links by adding the specified information at the `Social integration` section in the [\_config.yml](_config.yml) file. This information will appear at the bottom of the `About` page.

## Adding a newsletter

You can add a newsletter subscription form by adding the specified information at the `newsletter` section in the [\_config.yml](_config.yml) file. To set up a newsletter, you can use a service like [Loops.so](https://loops.so/), which is the current supported solution. Once you have set up your newsletter, you can add the form [endpoint](https://loops.so/docs/forms/custom-form) to the `endpoint` field in the `newsletter` section of the [\_config.yml](_config.yml) file.

Depending on your specified footer behavior, the sign up form either will appear at the bottom of the `About` page and at the bottom of blogposts if `related_posts` are enabled, or in the footer at the bottom of each page.
10 changes: 5 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
FROM ubuntu:latest
FROM ruby:latest
ENV DEBIAN_FRONTEND noninteractive

Label MAINTAINER Amir Pourmand

RUN apt-get update -y && apt-get install -y --no-install-recommends \
locales \
imagemagick \
ruby-full \
build-essential \
zlib1g-dev \
jupyter-nbconvert \
Expand All @@ -23,15 +22,16 @@ ENV LANG=en_US.UTF-8 \
LC_ALL=en_US.UTF-8 \
JEKYLL_ENV=production

# install jekyll and dependencies
RUN gem install jekyll bundler

RUN mkdir /srv/jekyll

ADD Gemfile.lock /srv/jekyll
ADD Gemfile /srv/jekyll

WORKDIR /srv/jekyll

# install jekyll and dependencies
RUN gem install jekyll bundler

RUN bundle install --no-cache
# && rm -rf /var/lib/gems/3.1.0/cache
EXPOSE 8080
Expand Down
Loading

0 comments on commit 12e12f1

Please sign in to comment.