Hexo主题 - Butterfly(三) 主题配置-1
语言修改站点配置文件 _config.yml 默认语言是 en 主题支持三种语言 default(en) zh-CN (简体中文) zh-TW (繁体中文) 网站资料修改网站各种资料,例如标题、副标题和邮箱等个人资料,请修改博客根目录的 _config.yml 导航菜单修改 主题配置文件 注意: 如果我们前面配置了_config.butterfly.yml,那么就修改根目录的_config.butterfly.yml 如果没有配置_config.butterfly.yml,就修改node_modules\hexo-theme-butterfly\_config.xml Home: / || fas fa-homeArchives: /archives/ || fas fa-archiveTags: /tags/ || fas fa-tagsCategories: /categories/ || fas fa-folder-openList||fas fa-list: Music: /music/ || fas fa-music Movie: /movies/ ||...
Hexo主题 - Butterfly(二) 主题页面
Front-matterFront-matter 是 markdown 文件最上方以 — 分隔的区域,用于指定个别档案的变数。 Page Front-matter 用于页面 配置Post Front-matter 用于文章页 配置 如果标注可选的参数,可根据自己需要添加,不用全部都写在markdown里 Page Front-matter---title:date:updated:type:comments:description:keywords:top_img:mathjax:katex:aside:aplayer:highlight_shrink:--- 写法 解释 title 【必需】页面标题 date 【必需】页面创建日期 type 【必需】标签、分类和友情链接三个页面需要配置 updated 【可选】页面更新日期 description 【可选】页面描述 keywords 【可选】页面关键字 comments 【可选】显示页面评论模块(默认...
Hexo主题 - Butterfly(一)--快速开始
安装Github在Hexo根目录 稳定版 git clone -b master https://github.com/jerryc127/hexo-theme-butterfly.git themes/butterfly 升级方法:在主题目录下,运行 git pull npm安装 此方法只支持 Hexo 5.0.0 以上版本 通过npm安装不会在themes里生成主题文件夹,而是在node_modules里生成。 在Hexo根目录 npm i hexo-theme-butterfly 升级方法:在Hexo根目录下,运行 npm update hexo-theme-butterfly 这里我是通过npm安装的。 应用主题修改Hexo根目录下的 _config.yml,把主题改为butterfly theme: butterfly 安装插件如果你没有pug以及stylus的渲染器,需要安装: npm install hexo-renderer-pug hexo-renderer-stylus --save 升级建议 升级完成后,请到Github的...
Hexo安装配置教程
安装前提安装使用hexo之前需要先安装Node.js和Git Node.js(Node.js 版本需不低于 10.13,建议使用 Node.js 12.0 及以上版本) Git如果您的电脑中已经安装上述必备程序,那么恭喜您!你可以直接前往 安装 Hexo 步骤。 安装Hexo可以通过以下命令查看主机中是否安装了node.js和npm $ node --version #检查是否安装了node.js$ npm --version #检查是否安装了npm 如下所示表示已经安装了node.js和npm $ node --versionv18.14.2$ npm --version9.5.0 所有必备的应用程序安装完成后,即可使用 npm 安装 Hexo。 $ npm install -g hexo-cli 进阶安装和使用对于熟悉 npm 的进阶用户,可以仅局部安装 hexo 包。 $ npm install hexo 安装以后,可以使用以下两种方式执行 Hexo: npx hexo <command> 将 Hexo 所在的目录下的...
2023-03-03-MonoCloudProxy 代理问题
问题场景在配置Flutter安装环境时,运行flutter doctor时,有这个错误 X HTTP host "https://maven.google.com/" is not reachable. Reason: An error occurred while checking the HTTP host: 信号灯超时时间已到 X HTTP host "https://pub.dev/" is not reachable. Reason: An error occurred while checking the HTTP host: 信号灯超时 时间已到 X HTTP host "https://cloud.google.com/" is not reachable. Reason: An error occurred while checking the HTTP host: 信号灯超时时间已到 原因是无法访问外网的服务器,直接打开MonoCloud,发现还是一样的结果 在Windows下: 使用...
Python基础 - 高级特性
切片取前面3个元素 L = ['Michael', 'Sarah', 'Tracy', 'Bob', 'Jack'] 如果用循环过程十分繁琐,Python提供了切片(Slice)操作符。 L[0:3]# ['Michael', 'Sarah', 'Tracy'] L[0:3]表示,从索引0开始取,直到索引3为止,但不包括索引3。即索引0,1,2,正好是3个元素。 如果第一个索引是0,还可以省略: L[:3] 也可以从索引1开始,取出2个元素出来: L[1:3]# ['Sarah', 'Tracy'] 类似的,既然Python支持L[-1]取倒数第一个元素,那么它同样支持倒数切片,试试: L[-2:]# ['Bob', 'Jack']L[-2:-1]#...
Python基础 - 集合
Python基础 - 集合dict类似于Java的Map 定义d = {'Michael': 95, 'Bob': 75, 'Tracy': 85} 取值d['Michael'] 如果key,不存在,就会报错 Traceback (most recent call last): File "C:\Users\Administrator\PycharmProjects\pythonProject\forp.py", line 29, in <module> d['Jason']KeyError: 'Jason' 解决办法: 通过 in判断key是否存在'Tomas' in d# False 通过get()方法,如果key存在,可以返回None,或者自己指定的值。 print(d.get('Tomas') #...
Python基础 - 列表
Python基础 – 列表列表定义bicycles = ['trek', 'cannondale', 'redline', 'specialized']print(bicycles) 列表访问print(bicycles[0])print(bicycles[2]) 在不确定列表的长度时,访问最后一个元素 print(bicycles[-1]) 同理,这种约定也适用于其他负数索引,例如,索引 -2 返回倒数第二个列表元素,索引 -3 返回倒数第三个元素 添加元素在列表末尾添加元素motorcycles = ['honda', 'yamaha', 'suzuki']motorcycles.append('ducati') 在列表中插入元素使用方法insert()可以在列表的任何位置添加新元素。为此,你需要制定新元素的索引和值 motorcycles.insert(0,...
实现一个简易的开机自动跳过广告App
借助Android的无障碍服务,实现打开App自动跳过广告 class AdSkipAccessibilityService: AccessibilityService() { override fun onAccessibilityEvent(event: AccessibilityEvent?) { val source = event?.source ?: return for (i in 0 until source.childCount) { if (source.getChild(i)?.text?.contains("跳过") == true) { source.getChild(i).performAction(ACTION_CLICK) } } source.recycle() } override fun...
读取excel的数据,向服务器插入
Python - 读取excel的数据,向服务器插入import jsonimport xlrdimport requestsdef read_excel(): workbook = xlrd.open_workbook(r"D:\Downloads\用户数据模板.xlsx") print(f"包含的表单数量{workbook.nsheets}") print(f"表单的名称为{workbook.sheet_names()}") # 表单索引从0开始,获取第一个表单对象 ds = workbook.sheet_by_index(0) print(workbook.sheets()) print(ds.name) print(f"行数:{ds.nrows}") print(f"列数:{ds.ncols}") row: int = 1 ...