After some thorough testing, finally made prettier on PR work. Since an
html file can't be used as comment on GitHub, changed to simply point to
the action that failed and to the file containing the html diff.
Signed-off-by: George Araújo <george.gcac@gmail.com>
Splitted prettier GitHub action into two:
- `on push`, only runs on direct pushes, if test fails generates an
artifact (that lasts for 3 days) with an html version of the changes
needed to pass prettier test
- `on PR`, only runs on PRs, if test fails comments on the PR with the
HTML content of the diff
I couldn't actually test the `on PR` version since it needs to be on a
PR in the master branch, so this will only be triggered after this PR is
accepted, and for the next PR that fails prettier test.
PS: currently the artifact is a zip file with the html inside. It is not
currently possible to generate it other way, we have to wait for [this
issue](https://github.com/actions/upload-artifact/issues/14) to be
closed.
---------
Signed-off-by: George Araújo <george.gcac@gmail.com>
The GitHub actions were running everytime a new commit was made to the
repo, but that wasn't needed. For example, we don't need to try to
create a new docker image if the libraries didn't change, same to build
the whole site after a change in the README.md.
---------
Signed-off-by: George Araújo <george.gcac@gmail.com>
Added GitHub action to do axe accessibility tests with [axe
cli](https://github.com/dequelabs/axe-core-npm/tree/develop/packages/cli).
I believe it is best by default to let this be run only manually, since
fixing some of the issues are not straightforward (I haven't fixed them
all for this template yet).
---------
Signed-off-by: George Araújo <george.gcac@gmail.com>
Added another GitHub action to check for broken local links on version
of the site that will be deployed.
The `broken-links` action check for broken links considering
documentation files (like INSTALLING.md) and also pages like
[_pages/about.md](https://github.com/alshedivat/al-folio/blob/master/_pages/about.md),
but it can't check for broken links when the link will be handled by
jekyll tags (like in
[_pages/blog.md](https://github.com/alshedivat/al-folio/blob/master/_pages/blog.md).
With `broken-links-site` we can check if all the links that will be used
on the final site that refer to local files are correct. Focusing only
on local files since this would end up calling too many checks for
library files, like
`https://unpkg.com/bootstrap-table@1.22.1/dist/bootstrap-table.min.css`.
---------
Signed-off-by: George Araújo <george.gcac@gmail.com>
Added GitHub action to check for broken links in repo before commit,
ignoring files with liquid tags since these were not yet processed and
also README since some sites created from this template doesn't have
valid urls anymore. Fixed some broken links in repo.
---------
Signed-off-by: George Araújo <george.gcac@gmail.com>
summary:
- adds prettier formatter configuration
- formats the entire repo using prettier, ignoring minified files
(`*.min.css`) and heavy generated html
- changes extensions of all `.html` files to `.liquid`, which is more
correct and necessary for prettier to work correctly
- replaces "%-" and "-%" with just "%" — manual liquid formatting using
minus signs is superfluous since we are compressing and minifying the
code anyway
- adds CI action for running prettier check on PR and pushes to master
Since the citation file and other stuff is already defined in
`_config.yml`, removed them when calling `{% bibliography %}`. Also
realized that `jekyll-scholar` helps in displaying only the papers cited
in page, changed to use that.
Signed-off-by: George Araújo <george.gcac@gmail.com>
I decided to break the README file into different ones to declutter it
from the main page. Also adding some more explanation on the structure
of the template. Tackling #2032 and #2033
---------
Signed-off-by: George Araujo <george.gcac@gmail.com>
I had added -strip arg to the imagemagick call as it is generally
desirable to strip metadata from images before publishing them, however
it seems to occasionally cause issues with jekyll-imagemagick
auto-regeneration, regenerating images even when they have not changed.
Fixes#1967
Update the way responsive images are used to only use one srcset, and
add corresponding `sizes` attribute to the relevant layouts and
templates.
I did not go through and add `sizes` to all the example posts/projects.
When `sizes` is not specified by the user, the `figure.html` template
defaults to 95% the width of the viewport which should work fine for
most cases; users can optimize further if they wish by feeding `sizes`
into the template.
Additionally:
- Enabled support for .gif to .webp compression
- fix error in jekyll-imagemagick config where all images were resized
to be 800px or less. (for example img-1400.webp was actually only 800px
wide, etc.)
- added note about making sure imagemagick is installed before enabling
it in responsive images section of `_config.yml`
After deploying my website (Cloudflare Pages), my Giscus did not work, I
realized these two paramesters are removed. After adding them again, my
Giscus worked correctly.
These new values are values from previous commits of original repository
---------
Co-authored-by: Maruan Al-Shedivat <maruan@genesistherapeutics.ai>