Coder Social home page Coder Social logo

hugo-pacman-theme's Introduction

hugo-pacman-theme

Demo: http://coderzh.github.io/hugo-pacman-theme/

config.toml

BaseURL = "http://coderzh.github.io/hugo-pacman-theme/"
LanguageCode = "zh-CN"
HasCJKLanguage = true
Title = "Hugo PacMan Theme Demo"
Theme = "hugo-pacman-theme"
pygmentsStyle = "default"
pygmentsUseClasses = true

[Author]
  Name = "coderzh"

[outputs]
  home = [ "RSS", "HTML" ]
    
[outputFormats] 
  [outputFormats.RSS]
    mediatype = "application/rss"
    baseName = "feed"

[Params]
  AuthorHomepage = "https://blog.coderzh.com"
  BottomIntroduce = "Introduce1 <br/> Introduce2"
  Description = ""
  Subtitle = "subtitle"
  Weibo = "coderzh"
  WeiboID = 1816308191
  Twitter = "coderzh"
  GitHub = "coderzh"
  Facebook = "coderzh"
  LinkIn = "coderzh"
  Imglogo = "img/logo.svg"
  AuthorImg = "img/author.jpg"
  DateFormat = "2006年01月02日"
  MonthFormat = "2006年01月"
  FancyBox = true

  [Params.GoogleAnalytics]
    ID = "UA-10147768-2"

  [Params.Disqus]
    ShortName = "coderzh"

  [Params.Strings]
    Search = "搜索"
    PageNotFound = "你访问的页面不存在"
    ShowSideBar = "显示侧边栏"
    HideSideBar = "隐藏侧边栏"
    Categories = "分类"
    Archive = "归档"
    Tags = "标签"
    TagCloud = "标签云"
    Rss = "RSS 订阅"
    TableOfContents = "文章目录"

[Menu]
  [[Menu.Main]]
    Name = "首页"
    URL = "/"
    Weight = 1
  [[Menu.Main]]
    Name = "关于"
    URL = "/about"
    Weight = 2

ScreenShot

hugo-pacman-theme

hugo-pacman-theme's People

Contributors

bep avatar bivectorfoil avatar coderzh avatar dovahcrow avatar kaitakoinuma avatar reyoung avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

hugo-pacman-theme's Issues

Something wrong with the date

I have applied the theme to my website. But it will show WARNING message when I run "hugo server" as follows:

capture

What's more, the dates of the post are wrong:

capture_2

capture_3

The setting is as follows:
capture_4

Any solution for this?

Thank you.

.Now will be deprecated with Hugo v0.20

.Now will be replaced with the now template function in Hugo v0.20 which eventually will be released on Monday. It's likely that the deprecation will cause builds to fail.

Comment area failed to load

I noticed that in line 35 of file hugo-pacman-theme/layouts/partials/comment.html, in the middle of the .DisqusShortName variable , a dot " . " is missing. The dot should be between .Disqus and ShortName. Like this:
s.src = '//{{ .Site.Params.Disqus.ShortName }}.disqus.com/embed.js;

Otherwise it will not be able to load the Disqus js file and causes the comment area failed to load.

Anyway, Truly thanks for the Theme!

点more的时候,链接地址在哪里?

请问一下,列表底下点more以后...进入了 baseurl/post/ 这个地址
但是我的文档没有建post文件夹,我也不太想把所有的文章都放在post下...
请问应该如何更改

latest google analytics format is not supported

Script for google analytics 'analytics.js' is renewed, now 'gtag.js' is commonly used.

I'm able to add code for it.
On the way, GoogleAnalytics.ID is not loaded because period is forgotten when load in google_analytics.html, I will also fix it.

Pacman Demo on Hugo website has 3rd party tracking enabled

Hello again @coderzh

Recently I audited the Hugo Themes website and it has come to my attention that your theme's demo has third party tracking enabled.

     \hugo-pacman-theme\exampleSite\config.toml:
        [Params.GoogleAnalytics]
        ID = "UA-10147768-2"

        [Params.Disqus]
        ShortName = "coderzh"

To fix this issue please leave the above parameters blank i.e.

     \hugo-pacman-theme\exampleSite\config.toml:
        [Params.GoogleAnalytics]
        ID = ""

        [Params.Disqus]
        ShortName = ""

Once you look into this please let me know.

Thank you!

Errors on site without expected parameters set

Hello!

$subj, when trying to run this theme against my blog source I get following (and site won't render at all):

Building sites … ERROR 2018/03/20 16:00:45 Error while rendering "page" in "": template: theme/_default/single.html:8:7: executing "theme/_default/single.html" at <partial "sidebar.htm...>: error calling partial: template: theme/partials/sidebar.html:7:5: executing "theme/partials/sidebar.html" at <partial "widgets/arc...>: error calling partial: template: theme/partials/widgets/archive.html:5:83: executing "theme/partials/widgets/archive.html" at <.Site.Params.monthfo...>: invalid value; expected string
ERROR 2018/03/20 16:00:45 Error while rendering "page" in "post/": template: theme/_default/single.html:8:7: executing "theme/_default/single.html" at <partial "sidebar.htm...>: error calling partial: template: theme/partials/sidebar.html:7:5: executing "theme/partials/sidebar.html" at <partial "widgets/arc...>: error calling partial: template: theme/partials/widgets/archive.html:5:83: executing "theme/partials/widgets/archive.html" at <.Site.Params.monthfo...>: invalid value; expected string
ERROR 2018/03/20 16:00:45 Error while rendering "page" in "": template: theme/_default/single.html:7:7: executing "theme/_default/single.html" at <partial "article_con...>: error calling partial: template: theme/partials/article_content.html:13:5: executing "theme/partials/article_content.html" at <partial "article_foo...>: error calling partial: template: theme/partials/article_footer.html:2:5: executing "theme/partials/article_footer.html" at <partial "article_cat...>: error calling partial: template: theme/partials/article_catetags.html:2:15: executing "theme/partials/article_catetags.html" at <len .Params.tags>: error calling len: len of untyped nil
ERROR 2018/03/20 16:00:45 Error while rendering "page" in "post/": template: theme/_default/single.html:7:7: executing "theme/_default/single.html" at <partial "article_con...>: error calling partial: template: theme/partials/article_content.html:13:5: executing "theme/partials/article_content.html" at <partial "article_foo...>: error calling partial: template: theme/partials/article_footer.html:2:5: executing "theme/partials/article_footer.html" at <partial "article_cat...>: error calling partial: template: theme/partials/article_catetags.html:2:15: executing "theme/partials/article_catetags.html" at <len .Params.tags>: error calling len: len of untyped nil
ERROR 2018/03/20 16:00:45 Error while rendering "taxonomy" in "": template: theme/_default/list.html:15:7: executing "theme/_default/list.html" at <partial "sidebar.htm...>: error calling partial: template: theme/partials/sidebar.html:7:5: executing "theme/partials/sidebar.html" at <partial "widgets/arc...>: error calling partial: template: theme/partials/widgets/archive.html:5:83: executing "theme/partials/widgets/archive.html" at <.Site.Params.monthfo...>: invalid value; expected string
ERROR 2018/03/20 16:00:45 Error while rendering "home" in "": template: theme/index.html:15:7: executing "theme/index.html" at <partial "sidebar.htm...>: error calling partial: template: theme/partials/sidebar.html:7:5: executing "theme/partials/sidebar.html" at <partial "widgets/arc...>: error calling partial: template: theme/partials/widgets/archive.html:5:83: executing "theme/partials/widgets/archive.html" at <.Site.Params.monthfo...>: invalid value; expected string
ERROR 2018/03/20 16:00:45 Error while rendering "taxonomyTerm" in "": template: theme/_default/list.html:15:7: executing "theme/_default/list.html" at <partial "sidebar.htm...>: error calling partial: template: theme/partials/sidebar.html:7:5: executing "theme/partials/sidebar.html" at <partial "widgets/arc...>: error calling partial: template: theme/partials/widgets/archive.html:5:83: executing "theme/partials/widgets/archive.html" at <.Site.Params.monthfo...>: invalid value; expected string
ERROR 2018/03/20 16:00:45 Error while rendering "section" in "": template: theme/_default/list.html:15:7: executing "theme/_default/list.html" at <partial "sidebar.htm...>: error calling partial: template: theme/partials/sidebar.html:7:5: executing "theme/partials/sidebar.html" at <partial "widgets/arc...>: error calling partial: template: theme/partials/widgets/archive.html:5:83: executing "theme/partials/widgets/archive.html" at <.Site.Params.monthfo...>: invalid value; expected string
ERROR 2018/03/20 16:00:46 Error while rendering "404" in "": template: theme/404.html:14:7: executing "theme/404.html" at <partial "sidebar.htm...>: error calling partial: template: theme/partials/sidebar.html:7:5: executing "theme/partials/sidebar.html" at <partial "widgets/arc...>: error calling partial: template: theme/partials/widgets/archive.html:5:83: executing "theme/partials/widgets/archive.html" at <.Site.Params.monthfo...>: invalid value; expected string

The reason is likely some absent .Site. parameter but you can't tell it from error message, I guess input parameters handling could be improved.

Mixed Content in the Hugo-Pacman README on the Hugo website

Hello @coderzh I am one of the maintainers of the Hugo Themes repository.

Recently I reviewed the deploy log of the Hugo Themes website and it seems that in line 75 of your theme's README you have entered insecure URLS to the following external image:

    http://7xlx3k.com1.z0.glb.clouddn.com/hugo-pacman-theme.png

This image's URL now throws a 404 error but also it throws a Mixed Content browser warning on the Hugo website since it is served under HTTPS.

Can you please replace the above non-existent and insecure URL with the proper secure URL of your theme's screenshot? i.e. https://raw.githubusercontent.com/coderzh/hugo-pacman-theme/eda9c351a538558f42a0b086a9320c99dd98e579/images/screenshot.png?

Once you do this please let me know.

Thanks

summary size

Define the size of the summary. I would like to be able to define the size of all summary in the main page.

hugo0.27的兼容性问题

使用hugo的0.27版本生成时,报有警告
WARNING: Site config's rssURI is deprecated and will be removed in a future release. Set baseName in outputFormats.RSS.
ERROR Page's Now is deprecated and will be removed in Hugo 0.27. Use now (the template func).

image

没有“首页”和“关于”的菜单项

主题很漂亮也很好用!!
用hugo0.20+生成和调试时的页面里都没有“首页”和“关于”两项,而且disqus也没有。而多次尝试后发现退回到hugo0.17之后就正常了,不知道是hugo自己的bug还是标准变化导致的兼容性问题,希望能够得到修复。谢谢!

No demo on theme site

Hello @coderzh,

could you add a folder named static to the exampleSite directory? Otherwise the build script of the theme site isn't able to generate a demo for your theme.

Thanks

I got an error when I executed it: can't evaluate field URL in type *hugolib.pageState

xjj@xjj:~/Documents/myblog/themes/hugo-pacman-theme/exampleSite$ hugo server --themesDir ../../
Start building sites … 
hugo v0.106.0 linux/amd64 BuildDate=unknown
ERROR 2022/11/19 01:54:26 render of "term" failed: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/_default/list.html:1:3": execute of template failed: template: _default/list.html:1:3: executing "_default/list.html" at <partial "head.html" .>: error calling partial: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/partials/head.html:5:18": execute of template failed: template: partials/head.html:5:18: executing "partials/head.html" at <.URL>: can't evaluate field URL in type *hugolib.pageState           
ERROR 2022/11/19 01:54:26 render of "term" failed: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/_default/list.html:1:3": execute of template failed: template: _default/list.html:1:3: executing "_default/list.html" at <partial "head.html" .>: error calling partial: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/partials/head.html:5:18": execute of template failed: template: partials/head.html:5:18: executing "partials/head.html" at <.URL>: can't evaluate field URL in type *hugolib.pageState           
ERROR 2022/11/19 01:54:26 render of "term" failed: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/_default/list.html:1:3": execute of template failed: template: _default/list.html:1:3: executing "_default/list.html" at <partial "head.html" .>: error calling partial: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/partials/head.html:5:18": execute of template failed: template: partials/head.html:5:18: executing "partials/head.html" at <.URL>: can't evaluate field URL in type *hugolib.pageState           
ERROR 2022/11/19 01:54:26 render of "page" failed: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/_default/single.html:1:3": execute of template failed: template: _default/single.html:1:3: executing "_default/single.html" at <partial "head.html" .>: error calling partial: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/partials/head.html:5:18": execute of template failed: template: partials/head.html:5:18: executing "partials/head.html" at <.URL>: can't evaluate field URL in type *hugolib.pageState     
Error: Error building site: failed to render pages: render of "page" failed: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/_default/single.html:1:3": execute of template failed: template: _default/single.html:1:3: executing "_default/single.html" at <partial "head.html" .>: error calling partial: "/home/xjj/Documents/myblog/themes/hugo-pacman-theme/layouts/partials/head.html:5:18": execute of template failed: template: partials/head.html:5:18: executing "partials/head.html" at <.URL>: can't evaluate field URL in type *hugolib.pageState
Built in 49 ms
xjj@xjj:~/Documents/myblog/themes/hugo-pacman-theme/exampleSite$ hugo env
hugo v0.106.0 linux/amd64 BuildDate=unknown
GOOS="linux"
GOARCH="amd64"
GOVERSION="go1.18.6"

How can I fix it ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.