Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CNAME
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
blog.jaysinh.dev
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Blog - [Jaysinh's own heed](https://ultimatecoder.github.io/Blog/)
# Blog - [Jaysinh's own heed](https://blog.jaysinh.dev/)

This repository contains backend tool I use to write and publish my blog. Since begining, I have invested more time in identifying proper flow than writing blog post.

* Framework: Jekyll
* URL: https://ultimatecoder.github.io/Blog/
* URL: https://blog.jaysinh.dev/
* Build/deploy: GitHub Actions ([`.github/workflows/`](.github/workflows)) — every pull request runs a build + link-check ([`ci.yml`](.github/workflows/ci.yml)), and pushes to `master` build and publish to GitHub Pages ([`pages.yml`](.github/workflows/pages.yml)).
5 changes: 2 additions & 3 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,8 @@ description: > # this means to ignore newlines until "baseurl:"
and an Actor by gene. I write mostly on programming topics. Browse through
my blog posts to identify my taste of writing.

# GitHub Pages project site path. Keep in sync with the "^/Blog" prefix
# in scripts/test's --swap-urls, which strips it for local link-checking.
baseurl: "/Blog" # the subpath of your site, e.g. /blog
# Served at the root of the custom domain in CNAME, so there is no subpath.
baseurl: "" # the subpath of your site, e.g. /blog
twitter_username: jaysinhp
github_username: ultimatecoder

Expand Down
2 changes: 1 addition & 1 deletion _config_production.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
url: "https://ultimatecoder.github.io" # the base hostname & protocol for your site, e.g. https://example.com
url: "https://blog.jaysinh.dev" # the base hostname & protocol for your site, e.g. https://example.com
12 changes: 5 additions & 7 deletions scripts/test
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ export LANG=en_US.UTF-8

# External URLs htmlproofer should not fail on. Two reasons appear here:
# dead — confirmed 404/gone, unrelated to this repo
# ci-block — live (200 from a browser) but returns 403 to GitHub Actions'
# shared runner IPs, i.e. bot/WAF blocking, not a broken link
# ci-block — live (200 from a browser) but returns 403/415 to htmlproofer,
# i.e. bot/WAF blocking, not a broken link
ignore_urls=(
"https://drive.google.com/file/d/0B_TmiicGbqjHb2ZGcE5QYmtXRHc/view?usp=sharing" # dead
"https://reps.mozilla.org/e/maker-party-gujarat/" # dead
Expand All @@ -17,14 +17,12 @@ ignore_urls=(
"https://www.ahduni.edu.in/" # ci-block
"https://pythonexpress.in/" # ci-block
"https://www.hackerearth.com" # ci-block
"http://www.gweca.ac.in" # ci-block
)
# htmlproofer wants a single comma-separated string.
ignore_urls_csv=$(IFS=,; echo "${ignore_urls[*]}")

# _site/ is the site root on disk, but pages link internally with the
# "/Blog" baseurl (this is a GitHub Pages project site, not a custom
# domain) — strip it so internal-link checks resolve against ./_site/.
# Keep this "^/Blog" prefix in sync with baseurl in _config.yml.
# baseurl is empty (the site is served at the root of a custom domain), so
# internal links already resolve against ./_site/ with no URL rewriting.
bundle exec htmlproofer ./_site/ --only-4xx --no-enforce-https \
--swap-urls "^/Blog:" \
--ignore-urls "$ignore_urls_csv"
Loading