hexo 常用操作

日志發布

發布新日志,新博客

hexo new "Hello"

然后到source/_post下編輯同名md文件再clean && d -g

ps: md文件里 ##后面需要空格

刪除日志

直接_post下刪了,再clean,d -g

日志添加分類,標簽

生成md文件時,在頂部會有填寫分類標簽的地方,像這篇我就是這樣寫的

categories: hexo
tags: [hexo,node.js]

下面的日志,分類,標簽是有了1個后才會出來,日志本來就有一篇,所以其他的兩個一開始是沒有的。

放音樂

打開網頁版網易云音樂。搜索歌曲,點擊生成外鏈播放器,復制html代碼。

<iframe frameborder="no" border="0" marginwidth="0" marginheight="0" width=330 height=86 src="http://music.163.com/outchain/player?type=2&id=471374061&auto=1&height=66"></iframe>

嵌入不自動播放只需要把以上代碼中的auto改為=0即可,樣子是這樣的

<iframe frameborder="no" border="0" marginwidth="0" marginheight="0" width=330 height=86 src="http://music.163.com/outchain/player?type=2&id=471374061&auto=1&height=66"></iframe>

<iframe frameborder="no" border="0" marginwidth="0" marginheight="0" width=330 height=86 src="http://music.163.com/outchain/player?type=2&id=471374061&auto=1&height=66"></iframe>

閱讀更多 設置

在文章的想要截斷的區域, 添加這個``

本地圖片方便引入

http://www.lxweimin.com/p/c2ba9533088a

  1. 首先確認_config.yml 中有 post_asset_folder:true
  2. hexo下執行npm install https://github.com/CodeFalling/hexo-asset-image --save
  3. 之后新建的md會在_posts下出現同名文件夾,是放圖片的,之后[圖片上傳失敗...(image-170cf0-1510579736404)]
最后編輯于
?著作權歸作者所有,轉載或內容合作請聯系作者
平臺聲明:文章內容(如有圖片或視頻亦包括在內)由作者上傳并發布,文章內容僅代表作者本人觀點,簡書系信息發布平臺,僅提供信息存儲服務。

推薦閱讀更多精彩內容