Skip to content

Commit

Permalink
First commit.
Browse files Browse the repository at this point in the history
  • Loading branch information
superxxm committed Jul 12, 2019
0 parents commit b6e543e
Show file tree
Hide file tree
Showing 8 changed files with 120 additions and 0 deletions.
6 changes: 6 additions & 0 deletions archetypes/default.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
title: "{{ replace .Name "-" " " | title }}"
date: {{ .Date }}
draft: true
---

83 changes: 83 additions & 0 deletions config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
baseURL = "https://xxm404.github.io"
title = "辛二's Blog"
languageCode = "zh-hans"
theme = "hermit"
# googleAnalytics = "UA-130696996-1"
enableRobotsTXT = true
enableEmoji = true
disqusShortname = "xxm404-github-io"
paginate = 5
rssLimit = 20
hasCJKLanguage = true
pygmentsCodefences = true
pygmentsUseClasses = true
pygmentsCodefencesGuessSyntax = true
pygmentsStyle = "dracula"
defaultContentDir = "post"

enableGitInfo = true

# [sitemap]
# changefreq = "weekly"
# priority = 0.5
# filename = "sitemap.xml"

[author]
name = "辛二"

[taxonomies]
tag = "tags"

[params]
dateform = "Jan 2, 2006"
dateformShort = "Jan 2"
dateformNum = "2006-01-02"
dateformNumTime = "2006-01-02 15:04"

# gitUrl = "https://github.com/aylei/blog/commit/"

homeSubtitle = "Reliability, Scalability, Maintainability"

footerCopyright = ' &#183; <a href="https://creativecommons.org/licenses/by-nc/4.0/" target="_blank" rel="noopener">CC BY-NC 4.0</a>'

logoImage = "me.jpeg"
since = "2019"
homeFullContent = false
rssFullContent = true
archive-paginate = 10
dateFormatToUse = "2006-01-02"
moreMeta = true
showMenuLanguageChooser = true
showAuthorInfo = true
toc = true
photoswipe = true
keywords = ["cloudnative","devops","kubernetes","golang","php","programming"]
description = "One more!"
[[params.social]]
name = "twitter"
url = ""

[[params.social]]
name = "github"
url = "https://github.com/xxm404"


[[params.social]]
name = "email"
url = "mail:[email protected]"

[params.meta]
description = "辛二's Blog"
keywords = "cloudnative,devops,kubernetes,prometheus,golang,java,programming"

[menu]

[[menu.main]]
name = "文章"
url = "post/"
weight = 10

[[menu.main]]
name = "关于"
url = "about/"
weight = 20
14 changes: 14 additions & 0 deletions content/posts/first-post.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: "First Post"
date: 2019-07-12T12:16:43+08:00
draft: true
toc: false
images:
tags:
- untagged
---

## Test post

1. 测试
2. 测试
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
const throttle=(callback,limit)=>{let timeoutHandler=null;return()=>{if(timeoutHandler==null){timeoutHandler=setTimeout(()=>{callback();timeoutHandler=null;},limit);}};};const listen=(ele,e,callback)=>{if(document.querySelector(ele)!==null){document.querySelector(ele).addEventListener(e,callback);}}
let header=document.getElementById('site-header');let lastScrollPosition=window.pageYOffset;const autoHideHeader=()=>{let currentScrollPosition=Math.max(window.pageYOffset,0);if(currentScrollPosition>lastScrollPosition){header.classList.remove('slideInUp');header.classList.add('slideOutDown');}else{header.classList.remove('slideOutDown');header.classList.add('slideInUp');}
lastScrollPosition=currentScrollPosition;}
let mobileMenuVisible=false;const toggleMobileMenu=()=>{let mobileMenu=document.getElementById('mobile-menu');if(mobileMenuVisible==false){mobileMenu.style.animationName='bounceInRight';mobileMenu.style.webkitAnimationName='bounceInRight';mobileMenu.style.display='block';mobileMenuVisible=true;}else{mobileMenu.style.animationName='bounceOutRight';mobileMenu.style.webkitAnimationName='bounceOutRight'
mobileMenuVisible=false;}}
const showImg=()=>{document.querySelector('.bg-img').classList.add('show-bg-img');}
const hideImg=()=>{document.querySelector('.bg-img').classList.remove('show-bg-img');}
const toggleToc=()=>{document.getElementById('toc').classList.toggle('show-toc');}
if(header!==null){listen('#menu-btn',"click",toggleMobileMenu);listen('#toc-btn',"click",toggleToc);listen('#img-btn',"click",showImg);listen('.bg-img',"click",hideImg);document.querySelectorAll('.post-year').forEach((ele)=>{ele.addEventListener('click',()=>{window.location.hash='#'+ele.id;});});window.addEventListener('scroll',throttle(()=>{autoHideHeader();if(mobileMenuVisible==true){toggleMobileMenu();}},250));}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"Target":"js/main.min.35ccbf1cdceb91e4c64c06b5d009d6e2977fafe56beda7762febd4e67528d2ac.js","MediaType":"application/javascript","Data":{"Integrity":"sha256-Ncy/HNzrkeTGTAa10AnW4pd/r+Vr7ad2L+vU5nUo0qw="}}

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"Target":"css/style.min.568c54a56780af2a70c45272522247710b69dbfc080b315211fb98381e3796f8.css","MediaType":"text/css","Data":{"Integrity":"sha256-VoxUpWeArypwxFJyUiJHcQtp2/wICzFSEfuYOB43lvg="}}
1 change: 1 addition & 0 deletions themes/hermit
Submodule hermit added at 00dbd4

0 comments on commit b6e543e

Please sign in to comment.