1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-10-28 17:15:49 -04:00

clean up redirects, audit a few AMP pages with percy

This commit is contained in:
2020-07-25 14:13:27 -04:00
parent 4b599db0d5
commit 9d87dd46bd
5 changed files with 79 additions and 75 deletions

View File

@@ -3,18 +3,24 @@ snapshot:
widths: [450, 1050] # px
enable-javascript: true
percy-css: |
div.embed, iframe, video, img[src$=".gif"] {
display: none;
div.embed,
iframe,
video,
img[src$=".gif"],
.i-amphtml-element {
display: none; /* don't worry about third-party content/embeds */
}
code, div.highlight {
border: 0 !important; /* no clue why this bugs out... */
code,
div.highlight {
border: 0 !important; /* no clue why this bugs out... */
}
.wave, .beat {
.wave,
.beat {
animation: none;
}
static-snapshots:
path: public/
snapshot-files: 'index.html,notes/**/index.html,uses/index.html,previously/index.html'
snapshot-files: 'index.html,uses/index.html,notes/{netlify-analytics-review,shodan-search-queries,dropping-dropbox,coronavirus-open-source}/*.html'
agent:
asset-discovery:
network-idle-timeout: 2000 # ms

Binary file not shown.

Before

Width:  |  Height:  |  Size: 77 KiB

After

Width:  |  Height:  |  Size: 149 KiB

View File

@@ -12,7 +12,7 @@ sitemap:
> The [Jake Jarvis](https://jarv.is/) CLI (aka the most useless Node module ever published, in history, by anyone, ever).
{{< image src="images/screenshot.png" width="700" alt="Terminal Screenshot" />}}
{{< image src="images/screenshot.png" width="850" alt="Terminal Screenshot" />}}
## Usage

View File

@@ -3,39 +3,42 @@
publish = "public"
functions = ".netlify/functions"
[build.environment]
NODE_VERSION = "14"
YARN_VERSION = "1.22.4"
YARN_FLAGS = "--no-ignore-optional --frozen-lockfile"
GO_VERSION = "1.14.6"
[build.environment]
NODE_VERSION = "14"
YARN_VERSION = "1.22.4"
YARN_FLAGS = "--no-ignore-optional --frozen-lockfile"
GO_VERSION = "1.14.6"
# Ensure *only* Pretty URLs are enabled, even though this is already set up in
# the Netlify dashboard.
[build.processing]
skip_processing = false
[build.processing.css]
bundle = false
minify = false
[build.processing.js]
bundle = false
minify = false
[build.processing.html]
pretty_urls = true
[build.processing.images]
compress = false
# Ensure *only* Pretty URLs are enabled, even though this is already set up in
# the Netlify dashboard.
[build.processing]
skip_processing = false
[build.processing.css]
bundle = false
minify = false
[build.processing.js]
bundle = false
minify = false
[build.processing.html]
pretty_urls = true
[build.processing.images]
compress = false
[context.deploy-preview]
command = "yarn build:hugo --environment development --baseURL $DEPLOY_PRIME_URL --buildDrafts --buildFuture"
command = "yarn build:functions && yarn build:hugo --environment development --baseURL $DEPLOY_PRIME_URL --buildDrafts --buildFuture"
[context.branch-deploy]
command = "yarn build:hugo --environment development --baseURL $DEPLOY_PRIME_URL --buildDrafts --buildFuture"
command = "yarn build:functions && yarn build:hugo --environment development --baseURL $DEPLOY_PRIME_URL --buildDrafts --buildFuture"
# https://github.com/netlify/cli/blob/master/docs/netlify-dev.md#netlifytoml-dev-block
[dev]
framework = "#custom"
command = "yarn start:hugo --baseURL=/ --appendPort=false --disableLiveReload"
targetPort = 1337
port = 1338
# only start Hugo, `netlify dev` builds/serves functions itself
command = "yarn start:hugo --port 1338 --baseURL=/ --appendPort=false --disableLiveReload"
# swap ports to keep consistent w/ normal local server
targetPort = 1338
port = 1337
# don't launch browser automatically
autoLaunch = false
# Cache resoures between builds:
@@ -132,11 +135,6 @@
to = "https://queue.simpleanalyticscdn.com/noscript.gif:splat"
status = 200
force = true
# TEMPORARY: Moved analytics endpoints above into /api/views
[[redirects]]
from = "/sa/*"
to = "/api/views/:splat"
status = 301
# Prettier URLs for Netlify Functions (must come after /api/views rules above)
[[redirects]]
from = "/api/*"
@@ -164,10 +162,18 @@
from = "/favicon.ico"
to = "/img/favicon.ico"
status = 200
[[redirects]]
from = "/favicon-*"
to = "/img/favicon-:splat"
status = 301
[[redirects]]
from = "/apple-touch-icon.png"
to = "/img/apple-touch-icon.png"
status = 200
[[redirects]]
from = "/apple-touch-icon-precomposed.png"
to = "/img/apple-touch-icon.png"
status = 200
[[redirects]]
from = "/safari-pinned-tab.svg"
to = "/img/safari-pinned-tab.svg"
@@ -176,10 +182,6 @@
from = "/keybase.txt"
to = "/.well-known/keybase.txt"
status = 301
[[redirects]]
from = "/twemoji/svg/*"
to = "/vendor/emoji/svg/:splat"
status = 301
# Moved these random sites/projects elsewhere (mostly GitHub Pages) to keep
# this repo and domain squeaky clean:
@@ -191,25 +193,21 @@
from = "/ios-trackers/*"
to = "https://jakejarvis.github.io/ios-trackers/:splat"
status = 302
[[redirects]]
from = "/awesome/*"
to = "https://synonymsforawesome.com/"
status = 302
[[redirects]]
from = "/hugo-node/*"
to = "https://github.com/jakejarvis/hugo-extended"
status = 302
[[redirects]]
from = "/awesome/*"
to = "https://synonymsforawesome.com/:splat"
from = "/comp20/*"
to = "https://jakejarvis.github.io/comp20/"
status = 302
[[redirects]]
from = "/scrabble/*"
to = "https://scrabble.io/:splat"
status = 302
[[redirects]]
from = "/candies/*"
to = "https://jakejarvis.github.io/candies/:splat"
status = 302
[[redirects]]
from = "/comp20/*"
to = "https://jakejarvis.github.io/comp20/:splat"
to = "https://jakejarvis.github.io/scrabble/"
status = 302
# H A C K E R M A N ( ͡° ͜ʖ ͡°)

View File

@@ -864,9 +864,9 @@
integrity sha1-aaI6OtKcrwCX8G7aWbNh7i8GOfY=
"@types/node@*":
version "14.0.24"
resolved "https://registry.yarnpkg.com/@types/node/-/node-14.0.24.tgz#b0f86f58564fa02a28b68f8b55d4cdec42e3b9d6"
integrity sha512-btt/oNOiDWcSuI721MdL8VQGnjsKjlTMdrKyTcLCKeQp/n4AAMFJ961wMbp+09y8WuGPClDEv07RIItdXKIXAA==
version "14.0.26"
resolved "https://registry.yarnpkg.com/@types/node/-/node-14.0.26.tgz#22a3b8a46510da8944b67bfc27df02c34a35331c"
integrity sha512-W+fpe5s91FBGE0pEa0lnqGLL4USgpLgs4nokw16SrBBco/gQxuua7KnArSEOd5iaMqbbSHV10vUDkJYJJqpXKA==
"@types/normalize-package-data@^2.4.0":
version "2.4.0"
@@ -1861,7 +1861,7 @@ chokidar@^2.1.8:
optionalDependencies:
fsevents "^1.2.7"
chokidar@^3.3.0, chokidar@^3.4.0:
chokidar@^3.3.0, chokidar@^3.4.1:
version "3.4.1"
resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.4.1.tgz#e905bdecf10eaa0a0b1db0c664481cc4cbc22ba1"
integrity sha512-TQTJyr2stihpC4Sya9hs2Xh+O2wf+igjL36Y75xx2WdHuiICcn/XJza46Jwt0eT5hVpQOzo3FpY3cj3RVYLX0g==
@@ -2677,9 +2677,9 @@ ee-first@1.1.1:
integrity sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=
electron-to-chromium@^1.3.488:
version "1.3.505"
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.505.tgz#0e55edbdfc13700b6742a73c81c0af7d0d71364f"
integrity sha512-Aunrp3HWtmdiJLIl+IPSFtEvJ/4Q9a3eKaxmzCthaZF1gbTbpHUTCU2zOVnFPH7r/AD7zQXyuFidYXzSHXBdsw==
version "1.3.509"
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.509.tgz#830fcb89cd66dc2984d18d794973b99e3f00584c"
integrity sha512-cN4lkjNRuTG8rtAqTOVgwpecEC2kbKA04PG6YijcKGHK/kD0xLjiqExcAOmLUwtXZRF8cBeam2I0VZcih919Ug==
elliptic@^6.0.0, elliptic@^6.5.2:
version "6.5.3"
@@ -2721,7 +2721,7 @@ end-of-stream@^1.0.0, end-of-stream@^1.1.0:
dependencies:
once "^1.4.0"
enhanced-resolve@^4.1.0:
enhanced-resolve@^4.3.0:
version "4.3.0"
resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-4.3.0.tgz#3b806f3bfafc1ec7de69551ef93cca46c1704126"
integrity sha512-3e87LvavsdxyoCfGusJnrZ5G8SLPOFeHSNpZI/ATL9a5leXo2k0w6MKnbqhdBad9qTobSfB20Ld7UmgoNbAZkQ==
@@ -4727,9 +4727,9 @@ lint-staged@^10.2.11:
stringify-object "^3.3.0"
listr2@^2.1.0:
version "2.3.2"
resolved "https://registry.yarnpkg.com/listr2/-/listr2-2.3.2.tgz#918dabaad2def14246abc7d54d607f03c59ec407"
integrity sha512-/KxSjXQzkMkeVT3Tl2gPwmQPLmOv81l29p+a0+I3mLHs1PjOjgkWuc6Y6d1oGBGXWj57/IVeVMbZ+9Hlr3P/pQ==
version "2.3.3"
resolved "https://registry.yarnpkg.com/listr2/-/listr2-2.3.3.tgz#ee9f4d95dd325ad1ae89fe7327f2a4f4498224b5"
integrity sha512-vU2eiFEzUEaDjgwRJ/n8RB79K2cBcaTw1DigIGHnXGp/BEeQqxGwiM8R17Itit5l2ykrrST11kw2l9vSpCbqUQ==
dependencies:
chalk "^4.0.0"
cli-truncate "^2.1.0"
@@ -5907,9 +5907,9 @@ parse-json@^4.0.0:
json-parse-better-errors "^1.0.1"
parse-json@^5.0.0:
version "5.0.0"
resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.0.0.tgz#73e5114c986d143efa3712d4ea24db9a4266f60f"
integrity sha512-OOY5b7PAEFV0E2Fir1KOkxchnZNCdowAJgQ5NuxjpBKTRP3pQhwkrkxqQjeoKJ+fO7bCpmIZaogI4eZGDMEGOw==
version "5.0.1"
resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.0.1.tgz#7cfe35c1ccd641bce3981467e6c2ece61b3b3878"
integrity sha512-ztoZ4/DYeXQq4E21v169sC8qWINGpcosGv9XhTDvg9/hWvx/zrFkc9BiWxR58OJLHGk28j5BL0SDLeV2WmFZlQ==
dependencies:
"@babel/code-frame" "^7.0.0"
error-ex "^1.3.1"
@@ -8221,15 +8221,15 @@ watchpack-chokidar2@^2.0.0:
dependencies:
chokidar "^2.1.8"
watchpack@^1.6.1:
version "1.7.2"
resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-1.7.2.tgz#c02e4d4d49913c3e7e122c3325365af9d331e9aa"
integrity sha512-ymVbbQP40MFTp+cNMvpyBpBtygHnPzPkHqoIwRRj/0B8KhqQwV8LaKjtbaxF2lK4vl8zN9wCxS46IFCU5K4W0g==
watchpack@^1.7.4:
version "1.7.4"
resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-1.7.4.tgz#6e9da53b3c80bb2d6508188f5b200410866cd30b"
integrity sha512-aWAgTW4MoSJzZPAicljkO1hsi1oKj/RRq/OJQh2PKI2UKL04c2Bs+MBOB+BBABHTXJpf9mCwHN7ANCvYsvY2sg==
dependencies:
graceful-fs "^4.1.2"
neo-async "^2.5.0"
optionalDependencies:
chokidar "^3.4.0"
chokidar "^3.4.1"
watchpack-chokidar2 "^2.0.0"
wcwidth@^1.0.1:
@@ -8255,9 +8255,9 @@ webpack-sources@^1.4.0, webpack-sources@^1.4.1:
source-map "~0.6.1"
webpack@^4.43.0:
version "4.43.0"
resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.43.0.tgz#c48547b11d563224c561dad1172c8aa0b8a678e6"
integrity sha512-GW1LjnPipFW2Y78OOab8NJlCflB7EFskMih2AHdvjbpKMeDJqEgSx24cXXXiPS65+WSwVyxtDsJH6jGX2czy+g==
version "4.44.0"
resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.44.0.tgz#3b08f88a89470175f036f4a9496b8a0428668802"
integrity sha512-wAuJxK123sqAw31SpkPiPW3iKHgFUiKvO7E7UZjtdExcsRe3fgav4mvoMM7vvpjLHVoJ6a0Mtp2fzkoA13e0Zw==
dependencies:
"@webassemblyjs/ast" "1.9.0"
"@webassemblyjs/helper-module-context" "1.9.0"
@@ -8267,7 +8267,7 @@ webpack@^4.43.0:
ajv "^6.10.2"
ajv-keywords "^3.4.1"
chrome-trace-event "^1.0.2"
enhanced-resolve "^4.1.0"
enhanced-resolve "^4.3.0"
eslint-scope "^4.0.3"
json-parse-better-errors "^1.0.2"
loader-runner "^2.4.0"
@@ -8280,7 +8280,7 @@ webpack@^4.43.0:
schema-utils "^1.0.0"
tapable "^1.1.3"
terser-webpack-plugin "^1.4.3"
watchpack "^1.6.1"
watchpack "^1.7.4"
webpack-sources "^1.4.1"
which-module@^2.0.0: