Skip to content

Commit

Permalink
Better og:image fallbacks
Browse files Browse the repository at this point in the history
  • Loading branch information
Khemarato Bhikkhu committed Jun 21, 2023
1 parent 6e57579 commit 758295b
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 22 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ gem "jekyll-sass-converter", ">= 3.0", "< 4.0"
group :jekyll_plugins do
gem "jekyll-feed", github: 'buddhist-uni/jekyll-feed', branch: 'collection-tags'
gem "jekyll-sitemap", "~> 1.4.0"
gem "jekyll-seo-tag", github: "buddhist-uni/jekyll-seo-tag", ref: '644037c'
gem "jekyll-seo-tag", github: "buddhist-uni/jekyll-seo-tag", ref: '9d3cf62'
gem "jekyll-last-modified-at", github: "buddhist-uni/jekyll-last-modified-at", branch: 'post-date'
gem 'jekyll-include-cache'
end
Expand Down
18 changes: 9 additions & 9 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ GIT

GIT
remote: https://github.com/buddhist-uni/jekyll-seo-tag.git
revision: 644037c4bdc815bbd973bb2aad139428d0a2eea7
ref: 644037c
revision: 9d3cf620ed53cc2b0d0f5a6cefffed2aeb34289b
ref: 9d3cf62
specs:
jekyll-seo-tag (2.7.1)
jekyll (>= 3.8, < 5.0)
Expand All @@ -37,9 +37,9 @@ GEM
eventmachine (1.2.7)
ffi (1.15.5)
forwardable-extended (2.6.0)
google-protobuf (3.23.1)
google-protobuf (3.23.3)
http_parser.rb (0.8.0)
i18n (1.13.0)
i18n (1.14.1)
concurrent-ruby (~> 1.0)
jekyll (4.3.2)
addressable (~> 2.4)
Expand Down Expand Up @@ -88,11 +88,11 @@ GEM
rb-inotify (0.10.1)
ffi (~> 1.0)
rexml (3.2.5)
rouge (4.1.1)
rouge (4.1.2)
safe_yaml (1.0.5)
sass-embedded (1.62.1)
google-protobuf (~> 3.21)
rake (>= 10.0.0)
sass-embedded (1.63.5)
google-protobuf (~> 3.23)
rake (>= 13.0.0)
terminal-table (3.0.2)
unicode-display_width (>= 1.1.1, < 3)
unicode-display_width (2.4.2)
Expand All @@ -115,4 +115,4 @@ DEPENDENCIES
webrick (~> 1.7)

BUNDLED WITH
2.4.6
2.4.10
1 change: 1 addition & 0 deletions _content/av/shaligram_walters-holly.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ course: nepalese
tags:
- sociology
- things
- himalayas
year: 2022
month: dec
publisher: nbn
Expand Down
1 change: 0 additions & 1 deletion _content/booklets/mt-kailash_dhammika.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ tags:
- setting
- tibetan
- himalayas
- central-asia
- geology
- world
olid: OL32066674M
Expand Down
4 changes: 4 additions & 0 deletions _data/drive_folders.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
"private": "https://drive.google.com/drive/folders/1XmdOa0vsdASEQUqGehr9gWYkER_M3f2E",
"public": "https://drive.google.com/drive/folders/11Vw1aPuTWfqA3CX3rhKFA08xOSpmQkG1"
},
"asia": {
"private": "https://drive.google.com/drive/folders/198TBBIt-uTixQgxzh0BPB-U8hWWjqM0z",
"public": "https://drive.google.com/drive/folders/1LIR6PYyjfI2RXrAWkZ-IwckrsOx1DHLf"
},
"bart": {
"private": "https://drive.google.com/drive/folders/1n1CgTwagj5GPkFKiluRPPcsa71p3rVkc",
"public": null
Expand Down
24 changes: 13 additions & 11 deletions scripts/archive_site.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,14 @@
import time
import os
import xml.etree.ElementTree as XML
try:
import tqdm
except:
print(" pip install tqdm")
quit(1)
ARCHIVE_ORG_AUTH_FILE = '~/archive.org.auth'

# Must be in the format "LOW {accesskey}:{secretkey}"
# Get your keys here: https://archive.org/account/s3.php
ARCHIVE_ORG_AUTH_FILE = Path(os.path.expanduser('~/archive.org.auth'))
ARCHIVE_ORG_AUTH = ARCHIVE_ORG_AUTH_FILE.read_text()
ARCHIVE_ORG_AUTH_PATH = Path(os.path.expanduser(ARCHIVE_ORG_AUTH_FILE))
if ARCHIVE_ORG_AUTH_PATH.exists():
ARCHIVE_ORG_AUTH = ARCHIVE_ORG_AUTH_PATH.read_text()
else:
print(f"Please make a new {ARCHIVE_ORG_AUTH_FILE} text file and put in it the information from https://archive.org/account/s3.php in the following format: \"LOW <accesskey>:<secretkey>\"")
quit(1)

SITEMAP_NAMESPACE = {"ns": "http://www.sitemaps.org/schemas/sitemap/0.9"}

Expand Down Expand Up @@ -52,8 +50,12 @@ def save_url_to_archiveorg(url):
return False

if __name__ == "__main__":
from tqdm import tqdm, trange
skip_past = "https://buddhistuniversity.net/authors/gross-rita"
try:
from tqdm import tqdm, trange
except:
print(" pip install tqdm")
quit(1)
skip_past = "Last successful URL"
urls = list(all_urls_in_website("https://buddhistuniversity.net"))
def wait_secs(n):
print(f"Waiting {n} seconds...")
Expand Down

0 comments on commit 758295b

Please sign in to comment.