ooo
parent
348b95df0f
commit
d1c5d8a67c
|
|
@ -0,0 +1,84 @@
|
|||
{
|
||||
"baseURL": "",
|
||||
"languageCode": "en-us",
|
||||
"title": "Site Title",
|
||||
"theme": "anubis",
|
||||
"paginate": 5,
|
||||
"paginatePath": "posts/-/pages",
|
||||
"enableRobotsTXT": true,
|
||||
"disableLiveReload": true,
|
||||
"minify": true,
|
||||
"noHTTPCache": true,
|
||||
"disableFastRender": true,
|
||||
"rssLimit": 5,
|
||||
"canonifyurls": true,
|
||||
"relativeurls": false,
|
||||
"params": {
|
||||
"toc": true,
|
||||
"author": "me",
|
||||
"email": "",
|
||||
"avatar": "",
|
||||
"description": "",
|
||||
"dateFormat": "2006-01-02",
|
||||
"paginationSinglePost": false,
|
||||
"style": "light",
|
||||
"readMore": true,
|
||||
"disableSummary": false,
|
||||
"social": [
|
||||
{
|
||||
"id": "email",
|
||||
"name": "contact"
|
||||
}
|
||||
]
|
||||
},
|
||||
"menu": {
|
||||
"main": [
|
||||
{
|
||||
"identifier": "archive",
|
||||
"name": "Archive",
|
||||
"title": "Archive",
|
||||
"url": "/posts/",
|
||||
"weight": 0
|
||||
},
|
||||
{
|
||||
"identifier": "about",
|
||||
"name": "About",
|
||||
"title": "About",
|
||||
"url": "/about/",
|
||||
"weight": 1
|
||||
}
|
||||
]
|
||||
},
|
||||
"markup": {
|
||||
"defaultMarkdownHandler": "goldmark",
|
||||
"goldmark": {
|
||||
"extensions": {
|
||||
"linkify": true,
|
||||
"strikethrough": true,
|
||||
"table": true,
|
||||
"taskList": true
|
||||
},
|
||||
"parser": {
|
||||
"autoHeadingID": true,
|
||||
"autoHeadingIDType": "github"
|
||||
},
|
||||
"renderer": {
|
||||
"unsafe": true
|
||||
}
|
||||
},
|
||||
"highlight": {
|
||||
"anchorLineNos": true,
|
||||
"guessSyntax": true,
|
||||
"lineNos": true,
|
||||
"tabWidth": 3
|
||||
},
|
||||
"tableOfContents": {
|
||||
"endLevel": 3,
|
||||
"ordered": false,
|
||||
"startLevel": 2
|
||||
}
|
||||
},
|
||||
"permalinks": {
|
||||
"posts": "/posts/:year-:month-:day-:filename"
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
"Path": "about.md.zip",
|
||||
"Name": "about.md.zip",
|
||||
"Size": -1,
|
||||
"MimeType": "application/zip",
|
||||
"ModTime": "2021-11-29T20:24:55.218Z",
|
||||
"IsDir": false,
|
||||
"ID": "14F-QFbXLWuXm3ScC1nr4iEnRcwBLMBFLQfDWmDeLcKM"
|
||||
}
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
"title": "the title of my blog",
|
||||
"theme": "anubis",
|
||||
"params": {
|
||||
"author": "bel",
|
||||
"email": "bel@bel.bel",
|
||||
"social": [
|
||||
{
|
||||
"id": "email",
|
||||
"name": "bel@bel.bel"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
"Path": "config.yaml.zip",
|
||||
"Name": "config.yaml.zip",
|
||||
"Size": -1,
|
||||
"MimeType": "application/zip",
|
||||
"ModTime": "2021-11-29T20:24:37.024Z",
|
||||
"IsDir": false,
|
||||
"ID": "1MpoWp-78TfLI5_Iz0ygMg5gu-JHux68t-LM49u0mACA"
|
||||
}
|
||||
|
|
@ -1,31 +1 @@
|
|||
---
|
||||
title: "About"
|
||||
description: "Hugo, the world’s fastest framework for building websites"
|
||||
date: "2019-02-28"
|
||||
aliases:
|
||||
- "about-us"
|
||||
- "about-hugo"
|
||||
- "contact"
|
||||
author: "Hugo Authors"
|
||||
---
|
||||
|
||||
Written in Go, Hugo is an open source static site generator available under the [Apache Licence 2.0.](https://github.com/gohugoio/hugo/blob/master/LICENSE) Hugo supports TOML, YAML and JSON data file types, Markdown and HTML content files and uses shortcodes to add rich content. Other notable features are taxonomies, multilingual mode, image processing, custom output formats, HTML/CSS/JS minification and support for Sass SCSS workflows.
|
||||
|
||||
Hugo makes use of a variety of open source projects including:
|
||||
|
||||
* https://github.com/yuin/goldmark
|
||||
* https://github.com/alecthomas/chroma
|
||||
* https://github.com/muesli/smartcrop
|
||||
* https://github.com/spf13/cobra
|
||||
* https://github.com/spf13/viper
|
||||
|
||||
Hugo is ideal for blogs, corporate websites, creative portfolios, online magazines, single page applications or even a website with thousands of pages.
|
||||
|
||||
Hugo is for people who want to hand code their own website without worrying about setting up complicated runtimes, dependencies and databases.
|
||||
|
||||
Websites built with Hugo are extremelly fast, secure and can be deployed anywhere including, AWS, GitHub Pages, Heroku, Netlify and any other hosting provider.
|
||||
|
||||
Learn more and contribute on [GitHub](https://github.com/gohugoio).
|
||||
|
||||
|
||||
|
||||
<html><head><meta content="text/html; charset=UTF-8" http-equiv="content-type"><style type="text/css">ol{margin:0;padding:0}table td,table th{padding:0}.c1{color:#000000;font-weight:400;text-decoration:none;vertical-align:baseline;font-size:11pt;font-family:"Arial";font-style:normal}.c0{padding-top:0pt;padding-bottom:0pt;line-height:1.15;orphans:2;widows:2;text-align:left}.c2{background-color:#ffffff;max-width:468pt;padding:72pt 72pt 72pt 72pt}.title{padding-top:0pt;color:#000000;font-size:26pt;padding-bottom:3pt;font-family:"Arial";line-height:1.15;page-break-after:avoid;orphans:2;widows:2;text-align:left}.subtitle{padding-top:0pt;color:#666666;font-size:15pt;padding-bottom:16pt;font-family:"Arial";line-height:1.15;page-break-after:avoid;orphans:2;widows:2;text-align:left}li{color:#000000;font-size:11pt;font-family:"Arial"}p{margin:0;color:#000000;font-size:11pt;font-family:"Arial"}h1{padding-top:20pt;color:#000000;font-size:20pt;padding-bottom:6pt;font-family:"Arial";line-height:1.15;page-break-after:avoid;orphans:2;widows:2;text-align:left}h2{padding-top:18pt;color:#000000;font-size:16pt;padding-bottom:6pt;font-family:"Arial";line-height:1.15;page-break-after:avoid;orphans:2;widows:2;text-align:left}h3{padding-top:16pt;color:#434343;font-size:14pt;padding-bottom:4pt;font-family:"Arial";line-height:1.15;page-break-after:avoid;orphans:2;widows:2;text-align:left}h4{padding-top:14pt;color:#666666;font-size:12pt;padding-bottom:4pt;font-family:"Arial";line-height:1.15;page-break-after:avoid;orphans:2;widows:2;text-align:left}h5{padding-top:12pt;color:#666666;font-size:11pt;padding-bottom:4pt;font-family:"Arial";line-height:1.15;page-break-after:avoid;orphans:2;widows:2;text-align:left}h6{padding-top:12pt;color:#666666;font-size:11pt;padding-bottom:4pt;font-family:"Arial";line-height:1.15;page-break-after:avoid;font-style:italic;orphans:2;widows:2;text-align:left}</style></head><body class="c2"><p class="c0"><span class="c1">Welcome :)</span></p></body></html>
|
||||
|
|
@ -1,9 +1,9 @@
|
|||
baseURL: ''
|
||||
languageCode: 'en-us'
|
||||
title: 'Site Title'
|
||||
theme: "anubis"
|
||||
baseURL: ""
|
||||
languageCode: en-us
|
||||
title: the title of my blog
|
||||
theme: anubis
|
||||
paginate: 5
|
||||
paginatePath: "posts/-/pages"
|
||||
paginatePath: posts/-/pages
|
||||
enableRobotsTXT: true
|
||||
disableLiveReload: true
|
||||
minify: true
|
||||
|
|
@ -12,43 +12,32 @@ disableFastRender: true
|
|||
rssLimit: 5
|
||||
canonifyurls: true
|
||||
relativeurls: false
|
||||
|
||||
params:
|
||||
toc: true
|
||||
author: "me"
|
||||
email: ""
|
||||
avatar: ""
|
||||
description: ""
|
||||
#customJS: [ "js/main.js" ] # relative to ./assets/
|
||||
dateFormat: "2006-01-02"
|
||||
paginationSinglePost: false
|
||||
style: light
|
||||
#style: auto-without-switcher
|
||||
#style: light-without-switcher
|
||||
readMore: true
|
||||
disableSummary: false
|
||||
social:
|
||||
- id: email
|
||||
name: contact
|
||||
#- id: linkedin
|
||||
# name: lapoba16
|
||||
#- id: rss
|
||||
# name: rss
|
||||
# url: '/index.xml'
|
||||
|
||||
toc: true
|
||||
author: bel
|
||||
email: bel@bel.bel
|
||||
avatar: ""
|
||||
description: ""
|
||||
dateFormat: "2006-01-02"
|
||||
paginationSinglePost: false
|
||||
style: light
|
||||
readMore: true
|
||||
disableSummary: false
|
||||
social:
|
||||
- id: email
|
||||
name: bel@bel.bel
|
||||
menu:
|
||||
main:
|
||||
- identifier: archive
|
||||
name: Archive
|
||||
title: Archive
|
||||
url: /posts/
|
||||
weight: 0
|
||||
- identifier: about
|
||||
name: About
|
||||
title: About
|
||||
url: /about/
|
||||
weight: 1
|
||||
|
||||
- identifier: archive
|
||||
name: Archive
|
||||
title: Archive
|
||||
url: /posts/
|
||||
weight: 0
|
||||
- identifier: about
|
||||
name: About
|
||||
title: About
|
||||
url: /about/
|
||||
weight: 1
|
||||
markup:
|
||||
defaultMarkdownHandler: goldmark
|
||||
goldmark:
|
||||
|
|
@ -61,7 +50,7 @@ markup:
|
|||
autoHeadingID: true
|
||||
autoHeadingIDType: github
|
||||
renderer:
|
||||
unsafe: true # raw HTML OK
|
||||
unsafe: true
|
||||
highlight:
|
||||
anchorLineNos: true
|
||||
guessSyntax: true
|
||||
|
|
@ -71,6 +60,5 @@ markup:
|
|||
endLevel: 3
|
||||
ordered: false
|
||||
startLevel: 2
|
||||
|
||||
permalinks:
|
||||
posts: /posts/:year-:month-:day-:filename
|
||||
|
|
|
|||
47
posts.sh
47
posts.sh
|
|
@ -11,7 +11,7 @@ TMPDIR="${TMPDIR:-"/tmp"}"
|
|||
|
||||
main() {
|
||||
flags "$@"
|
||||
#posts
|
||||
posts
|
||||
meta
|
||||
}
|
||||
|
||||
|
|
@ -161,11 +161,11 @@ meta() {
|
|||
}
|
||||
|
||||
meta_file() {
|
||||
echo "$TMPDIR/.meta.$(echo "$1" | jq -r .Name)"
|
||||
echo "./meta/.overrides/$(echo "$1" | jq -r .Name)/.meta"
|
||||
}
|
||||
|
||||
up_to_date() {
|
||||
test -f "$(meta_file "$1")" && test "$1" == "$(cat "$(meta_file "$1")")"
|
||||
test -f "$(meta_file "$1")" && test "$1" == "$(cat "$(meta_file "$1")")" && test -e "$(must "$1")"
|
||||
}
|
||||
|
||||
extracted_dir() {
|
||||
|
|
@ -176,6 +176,10 @@ meta() {
|
|||
echo "./meta/.overrides/$(echo "$1" | jq -r .Name | sed 's/.zip$//')"
|
||||
}
|
||||
|
||||
must() {
|
||||
echo "./meta/$(basename "$(extracted "$1")")"
|
||||
}
|
||||
|
||||
extract() {
|
||||
local extracted_dir="$(extracted_dir "$1")"
|
||||
rm -rf "$extracted_dir" "${extracted_dir%.zip}"
|
||||
|
|
@ -197,6 +201,38 @@ meta() {
|
|||
cat "$extracted" | html_to_plaintext > "$extracted.2"; mv "$extracted.2" "$extracted"
|
||||
}
|
||||
|
||||
merge() {
|
||||
local extracted="$(extracted "$1")"
|
||||
case "${extracted##*.}" in
|
||||
yaml ) merge_yaml "$1" ;;
|
||||
* )
|
||||
esac
|
||||
}
|
||||
|
||||
merge_yaml() {
|
||||
local override="$(extracted "$1")"
|
||||
local default="$(echo "$override" | sed 's/\.overrides/\.default/')"
|
||||
if [ ! -f "$default" ]; then
|
||||
return
|
||||
fi
|
||||
cat "$override" | yq -j eval - | jq > "$override.json"
|
||||
cat "$default" | yq -j eval - | jq > "$default.json"
|
||||
jq -s '.[0] * .[1]' "$default.json" "$override.json" | yq -P eval - > ./meta/"$(basename "$override")"
|
||||
}
|
||||
|
||||
import() {
|
||||
local must="$(must "$1")"
|
||||
if [ -f "$must" ]; then
|
||||
rm "$must"
|
||||
fi
|
||||
merge "$1"
|
||||
if [ -f "$must" ]; then
|
||||
return
|
||||
fi
|
||||
log cp -r "${must%/*}/.overrides/${must##*/}" "$must"
|
||||
cp -r "${must%/*}/.overrides/${must##*/}" "$must"
|
||||
}
|
||||
|
||||
for b64_json in $(list); do
|
||||
local json="$(echo "$b64_json" | base64 --decode | jq .)"
|
||||
local filename="$(echo "$json" | jq -r .Name)"
|
||||
|
|
@ -208,10 +244,9 @@ meta() {
|
|||
pull "$json"
|
||||
log "$filename: extracting"
|
||||
extract "$json"
|
||||
merge "$json"
|
||||
# todo: echo "$json" > "$(meta_file $json)"
|
||||
import "$json"
|
||||
echo "$json" > "$(meta_file "$json")"
|
||||
done
|
||||
false
|
||||
}
|
||||
|
||||
fatal() {
|
||||
|
|
|
|||
|
|
@ -6,5 +6,5 @@ scope = drive
|
|||
#team_drive = 1-p043gwMk88rj4-Sm5otARi_AJZYskbj
|
||||
#root_folder_id = 1-p043gwMk88rj4-Sm5otARi_AJZYskbj
|
||||
formats = zip,html,rtf,odt,docx,xlsx,pptx,svg
|
||||
token = {"access_token":"ya29.a0ARrdaM-P6wKzub3feWIaQlG3YXq2REc0rfS1LDxfeV1m1rr5Zwhe_XqYTInCEcCHP4bHNPvcBcZufAnJpgLZlVBte-abfEOvwfk4Qz25__FboaddAXthlv_EeIxPwVTlKJTy7MOKGLz2Rhg47CjjagfFYMcCKw","token_type":"Bearer","refresh_token":"1//04sQD4800FsqyCgYIARAAGAQSNwF-L9IrB1_7BV8ScFnqmIz8FNWgXfr80--6VG6KX1pTnneQKAz6Ss3YtxqmCdf2tRBy2ndkhek","expiry":"2021-11-29T14:49:21.903576-07:00"}
|
||||
token = {"access_token":"ya29.a0ARrdaM-gyIY7jtRZuCMXsXx0apjLSVmd1dpGeuluOlVHoOcEPNpghYjqOfWK7aM_RQRC2xwomdQqLgsSzEHNAkQ0Jv9v6_QqiGwbqscPxTnVIaeMpmDLsxMFVYse29Ofba9bSsOyqfOhb1BeS_7KW3CVtDlTuA","token_type":"Bearer","refresh_token":"1//04sQD4800FsqyCgYIARAAGAQSNwF-L9IrB1_7BV8ScFnqmIz8FNWgXfr80--6VG6KX1pTnneQKAz6Ss3YtxqmCdf2tRBy2ndkhek","expiry":"2021-11-29T15:49:20.965947-07:00"}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue