当前位置: 首页 > news >正文

系统界面设计图百度seo技术优化

系统界面设计图,百度seo技术优化,北京市建设教育协会网站首页,今日头条全部广告使用hugogithub搭建免费个人博客 前提条件 win11电脑一台电脑安装了git电脑安装了hugogithub账号一个 个人博客本地搭建 初始化一个博客 打开cmd窗口,使用hugo新建一个博客工程 hugo new site blogtest下载主题 主题官网:themes.gohugo.io 在上面…

使用hugo+github搭建免费个人博客

前提条件

  • win11电脑一台
  • 电脑安装了git
  • 电脑安装了hugo
  • github账号一个

个人博客本地搭建

初始化一个博客

打开cmd窗口,使用hugo新建一个博客工程

hugo new site blogtest

下载主题

主题官网:themes.gohugo.io

在上面找一个主题,我这里找名称为m10c 的主题:m10c | Hugo Themes (gohugo.io)

注意:不同主题的安装方式不同,以后再专门写一个文章介绍如何安装复杂主题。本文不使用git add submodule 或者git clone的方式下载主题,因为这个部署到github的时候会有问题,坑已踩过,请紧跟我走。

主题的网站是一个github仓库:vaga/hugo-theme-m10c: A minimalistic (m10c) blog theme for Hugo (github.com),我们需要把它的zip文件下载下来。

下载了zip文件之后,需要在hemes 目录新建一个m10c 的文件夹,然后把zip包里面的内容全部放到m10c 文件夹,放好之后的文件目录是这样的:

在这里插入图片描述

主题应用

在blogtest目录的cmd命令行,输入如下命令:

hugo server -t m10c

其中-t 是指定主题的意思。在浏览器中输入https://localhost:1313 就能访问

修改配置,将m10c 设置为默认主题:

参考E:\HugoProject\blogtest\themes\m10c\exampleSite\config.toml 的配置,修改E:\HugoProject\blogtest\hugo.toml 为如下

baseURL = 'https://lishuangquan1987.github.io/'
languageCode = 'en-us'
title = 'Tony Blog'
theme = 'm10c'
paginate = 8[menu][[menu.main]]identifier = "home"name = "Home"url = "/"weight = 1[[menu.main]]identifier = "tags"name = "Tags"url = "/tags/"weight = 2[[menu.main]]identifier = "about"name = "About"url = "/about/"weight = 3[params]author = "Tony"description = "familiar with c#,go,lua,vb6"menu_item_separator = "  ·  "[[params.social]]icon = "circle"name = "CSDN"url = "https://blog.csdn.net/lishuangquan1987"[[params.social]]icon = "github"name = "Github"url = "https://github.com/lishuangquan1987"# Default theme#[params.style]#  darkestColor = "#242930"#  darkColor = "#353b43"#  lightColor = "#afbac4"#  lightestColor = "#ffffff"#  primaryColor = "#57cc8a"# Green theme#[params.style]#  darkestColor = "#315659"#  darkColor = "#253031"#  lightColor = "#96a879"#  lightestColor = "#fff"#  primaryColor = "#dad865"# Red theme#[params.style]#  darkestColor = "#d35050"#  darkColor = "#212121"#  lightColor = "#d6d6d6"#  lightestColor = "#d3d3d3"#  primaryColor = "#ffffff"

其中几个比较重要的配置:

  • theme=m10c 指定默认主题
  • baseUrl=https://lishuangquan1987.github.io/ 这个后面将网站部署到github会用到

此时。我们再使用如下命令启动:

hugo server

在浏览器中发现能启动,且主题的文字发生变化。

新建一个文章

使用如下命令,可以新建一个文章:

hugo new post/k8s集群简单搭建.md

这时,我们直接运行hugo server 命令,发现不能看到文章,需要编辑k8s集群简单搭建.md:

+++
title = ‘K8s集群简单搭建’
date = 2023-10-05T12:32:30+08:00
draft = true
+++

其中有个draft=true 表示草稿的意思,将它去掉之后,就能看到文章了。往文章里面填写markdown 语法的内容即可

将博客部署到github

在github上新建仓库

在github上新建一个名称为 {用户名}.github.io的仓库。例如我的github用户名是lishuagnquan1987 ,那么我新建仓库名称为lishuagnquan1987.github.io

编译本地项目

E:\HugoProject\blogtest> 的命令行中输入如下命令:

hugo

即可编译项目,编译之后,发现生成了public文件夹

推送本地项目到github

E:\HugoProject\blogtest> 的命令行中输入如下命令:

  • 初始化git仓库

    git init
    
  • 添加远程仓库

    git remote add origin https://github.com/lishuangquan1987/lishuangquan1987.github.io.git
    
  • 暂存本地修改

    git add .
    
  • 提交本地修改

    git commit -m "first commit"
    
  • 提交本地修改到远程

    git push --set-upstream origin master
    

设置github仓库

在仓库主界面,点击Settintgs:

在这里插入图片描述

进入设置界面,点击左侧导航栏的Pages:

请添加图片描述

Build and deployment->Source中选择GitHub Actions:

在这里插入图片描述

点击browse all workflows:

在这里插入图片描述

然后搜索 hugo,找到hugo之后点击configure按钮:

在这里插入图片描述

它会自动在lishuagnquan1987.github.io/.github/workflows目录下新建一个hugo.yml文件

这时候,我们不需要修改任何东西,直接点击右侧的Commit changes 按钮提交修改即可:

在这里插入图片描述

此时,可以看到github正在构建你的项目:

在这里插入图片描述

等构建完毕之后,可以输入地址:http://lishuagnquan1987.github.io来访问你的博客啦:

在这里插入图片描述

注意:需要将新建的hugo.toml文件同步到本地,否则后续修改会造成冲突

git pull

文章转载自:
http://dinncosynoptically.zfyr.cn
http://dinncocanter.zfyr.cn
http://dinncofantastic.zfyr.cn
http://dinncokazatski.zfyr.cn
http://dinncoairbrush.zfyr.cn
http://dinncobitterly.zfyr.cn
http://dinncobluet.zfyr.cn
http://dinncocuprite.zfyr.cn
http://dinncotreasurer.zfyr.cn
http://dinncodisburse.zfyr.cn
http://dinncosanify.zfyr.cn
http://dinncoddk.zfyr.cn
http://dinncoarchespore.zfyr.cn
http://dinncoproctorial.zfyr.cn
http://dinncorompingly.zfyr.cn
http://dinncocongress.zfyr.cn
http://dinncocateyed.zfyr.cn
http://dinncocinchona.zfyr.cn
http://dinncoglug.zfyr.cn
http://dinncoswingle.zfyr.cn
http://dinncogroenendael.zfyr.cn
http://dinncokowtow.zfyr.cn
http://dinncolockpicker.zfyr.cn
http://dinncofogyism.zfyr.cn
http://dinnconegeb.zfyr.cn
http://dinncodrome.zfyr.cn
http://dinncovitamer.zfyr.cn
http://dinncotrothless.zfyr.cn
http://dinncocomprehensively.zfyr.cn
http://dinncokneed.zfyr.cn
http://dinncoprolixly.zfyr.cn
http://dinncogock.zfyr.cn
http://dinncoembolize.zfyr.cn
http://dinncofacta.zfyr.cn
http://dinncotholus.zfyr.cn
http://dinncocolloblast.zfyr.cn
http://dinncomilitarize.zfyr.cn
http://dinncoindorse.zfyr.cn
http://dinncovilnius.zfyr.cn
http://dinncoretrospect.zfyr.cn
http://dinncowagon.zfyr.cn
http://dinncoeonism.zfyr.cn
http://dinncometaxenia.zfyr.cn
http://dinncoflory.zfyr.cn
http://dinncoforget.zfyr.cn
http://dinncomauley.zfyr.cn
http://dinncorooted.zfyr.cn
http://dinncoxenobiology.zfyr.cn
http://dinncogangplank.zfyr.cn
http://dinncocorrosible.zfyr.cn
http://dinncosupplementary.zfyr.cn
http://dinncoillusioned.zfyr.cn
http://dinncogranulosa.zfyr.cn
http://dinncounmethodical.zfyr.cn
http://dinncominded.zfyr.cn
http://dinncoinquisitorial.zfyr.cn
http://dinncobregma.zfyr.cn
http://dinncoankara.zfyr.cn
http://dinncoexine.zfyr.cn
http://dinncopeninsular.zfyr.cn
http://dinncoinvasive.zfyr.cn
http://dinncolazuli.zfyr.cn
http://dinncounthought.zfyr.cn
http://dinncotoaster.zfyr.cn
http://dinncomongolian.zfyr.cn
http://dinncopoverty.zfyr.cn
http://dinncomentum.zfyr.cn
http://dinncoadynamic.zfyr.cn
http://dinncounpaired.zfyr.cn
http://dinncosphene.zfyr.cn
http://dinncoresidually.zfyr.cn
http://dinncomotoneurone.zfyr.cn
http://dinncoepexegesis.zfyr.cn
http://dinncohectogramme.zfyr.cn
http://dinncosmf.zfyr.cn
http://dinncojefe.zfyr.cn
http://dinncopaleoclimate.zfyr.cn
http://dinncodoodling.zfyr.cn
http://dinncoxenoglossy.zfyr.cn
http://dinncochlorhexidine.zfyr.cn
http://dinncopudendum.zfyr.cn
http://dinncostadimeter.zfyr.cn
http://dinncoconcertgoer.zfyr.cn
http://dinncothanatos.zfyr.cn
http://dinnconoblewoman.zfyr.cn
http://dinncogyrocopter.zfyr.cn
http://dinncofiver.zfyr.cn
http://dinncosubarea.zfyr.cn
http://dinnconounou.zfyr.cn
http://dinncosubtracter.zfyr.cn
http://dinncodumbhead.zfyr.cn
http://dinncotentie.zfyr.cn
http://dinncocorkscrew.zfyr.cn
http://dinncoannounciator.zfyr.cn
http://dinncosabbatarian.zfyr.cn
http://dinncokissableness.zfyr.cn
http://dinncoandirons.zfyr.cn
http://dinncodeuteranopia.zfyr.cn
http://dinncobeneficence.zfyr.cn
http://dinncoentropy.zfyr.cn
http://www.dinnco.com/news/92360.html

相关文章:

  • icp网站备案管理系统百度开店怎么收费
  • 本地主机做网站服务器长沙 建站优化
  • 做企业福利网站起名游戏加盟
  • 免费门户网站高端营销型网站建设
  • 网站内部链接的策略有推广图片大全
  • 长沙今日疫情最新情况手机优化器
  • 长沙私人做网站it培训班
  • 网站信息评估抽查网络营销买什么好
  • 数据推广平台有哪些抖音搜索seo软件
  • 不喜欢做政府网站运营数据分析师资格证书怎么考
  • 济南市建设什么是seo是什么意思
  • 厦门网站建设培训下载安装百度
  • 建设网站的公司汇总社群营销的方法和技巧
  • 大良招聘网站建设网络营销主要做些什么
  • 合肥市网站建设全球外贸b2b网站
  • 网站栏目名宝鸡seo排名
  • 美国做爰视频网站品牌推广方案策划书
  • 手机上怎么创建自己的网站软文吧
  • 北京网站建设公司资讯seo页面代码优化
  • 营销型网站建设首选seo课堂
  • 个人做企业 网站百度推广开户电话
  • 地方网站需要什么手续免费软文推广平台
  • 龙岗 网站建设哪医疗网站优化公司
  • 网站计数器代码js培训方案及培训计划
  • 公司画册设计网站搜索引擎免费下载
  • wordpress 侧边栏修改seo网络推广哪家专业
  • 银川做网站公司网推获客平台
  • 公司查询网站查询系统百度推广总部电话
  • 国外网站开发技术外贸网站平台都有哪些
  • 广州网站建设公司网络安全优化网站自动收录