This commit is contained in:
Eigeen 2022-03-30 01:52:49 +08:00
commit a7edcc9f9b
16 changed files with 2304 additions and 0 deletions

8
.gitignore vendored Normal file
View File

@ -0,0 +1,8 @@
.DS_Store
Thumbs.db
db.json
*.log
node_modules/
public/
.deploy*/
*.lnk

108
_config.yml Normal file
View File

@ -0,0 +1,108 @@
# Hexo Configuration
## Docs: https://hexo.io/docs/configuration.html
## Source: https://github.com/hexojs/hexo/
# Site
title: Eigeen's Blog
subtitle: 'Eigeen的个人博客'
description: Eigeen's Blog
keywords:
author: Eigeen
language: cn
timezone: ''
# URL
## If your site is put in a subdirectory, set url as 'http://example.com/child' and root as '/child/'
url: https://www.eigeen.com/
root: /
permalink: :year/:month/:title/
permalink_defaults:
pretty_urls:
trailing_index: true # Set to false to remove trailing 'index.html' from permalinks
trailing_html: true # Set to false to remove trailing '.html' from permalinks
# Directory
source_dir: source
public_dir: public
tag_dir: tags
archive_dir: archives
category_dir: categories
code_dir: downloads/code
i18n_dir: :lang
skip_render:
# Writing
new_post_name: :title.md # File name of new posts
default_layout: post
titlecase: false # Transform title into titlecase
external_link:
enable: true # Open external links in new tab
field: site # Apply to the whole site
exclude: ''
filename_case: 0
render_drafts: false
post_asset_folder: false
relative_link: false
future: true
highlight:
enable: true
line_number: true
auto_detect: false
tab_replace: ''
wrap: true
hljs: false
prismjs:
enable: false
preprocess: true
line_number: true
tab_replace: ''
# Home page setting
# path: Root path for your blogs index page. (default = '')
# per_page: Posts displayed per page. (0 = disable pagination)
# order_by: Posts order. (Order by date descending by default)
index_generator:
path: ''
per_page: 10
order_by: -date
# Category & Tag
default_category: uncategorized
category_map:
tag_map:
# Metadata elements
## https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta
meta_generator: true
# Date / Time format
## Hexo uses Moment.js to parse and display date
## You can customize the date format as defined in
## http://momentjs.com/docs/#/displaying/format/
date_format: YYYY-MM-DD
time_format: HH:mm:ss
## updated_option supports 'mtime', 'date', 'empty'
updated_option: 'mtime'
# Pagination
## Set per_page to 0 to disable pagination
per_page: 10
pagination_dir: page
# Include / Exclude file(s)
## include:/exclude: options only apply to the 'source/' folder
include:
exclude:
ignore:
# Extensions
## Plugins: https://hexo.io/plugins/
## Themes: https://hexo.io/themes/
theme: hexo-theme-ayer
# Deployment
## Docs: https://hexo.io/docs/one-command-deployment
deploy:
type: git
repo: git@e.coding.net:eigenwaves/blog/blog.git
branch: master

1679
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

29
package.json Normal file
View File

@ -0,0 +1,29 @@
{
"name": "hexo-site",
"version": "0.0.0",
"private": true,
"scripts": {
"build": "hexo generate",
"clean": "hexo clean",
"deploy": "hexo deploy",
"server": "hexo server"
},
"hexo": {
"version": "5.2.0"
},
"dependencies": {
"hexo": "^5.0.0",
"hexo-deployer-git": "^2.1.0",
"hexo-generator-archive": "^1.0.0",
"hexo-generator-category": "^1.0.0",
"hexo-generator-feed": "^3.0.0",
"hexo-generator-index": "^2.0.0",
"hexo-generator-index-pin-top": "^0.2.2",
"hexo-generator-searchdb": "^1.3.3",
"hexo-generator-tag": "^1.0.0",
"hexo-renderer-ejs": "^1.0.0",
"hexo-renderer-marked": "^3.0.0",
"hexo-renderer-stylus": "^2.0.0",
"hexo-server": "^2.0.0"
}
}

4
scaffolds/draft.md Normal file
View File

@ -0,0 +1,4 @@
---
title: {{ title }}
tags:
---

4
scaffolds/page.md Normal file
View File

@ -0,0 +1,4 @@
---
title: {{ title }}
date: {{ date }}
---

5
scaffolds/post.md Normal file
View File

@ -0,0 +1,5 @@
---
title: {{ title }}
date: {{ date }}
tags:
---

9
source/_posts/about.md Normal file
View File

@ -0,0 +1,9 @@
---
title: 关于
date: 2020-11-19 20:19:02
tags: another
---
这个家伙很懒,什么都没有留下
*2333*

View File

@ -0,0 +1,42 @@
---
title: 解决Cloudflare Partner不能添加站点的问题
date: 2021-09-15 00:00:00
tags:
- Cloudflare
- 网站
category: 技术
---
没错就是现在博客正在使用的域名eigeen.com不能添加到Cloudflare。
众所周知Cloudflare官方只允许NS接入意味着你的域名解析都要通过CF在国内解析速度会明显变慢。表现就是新用户访问你的网站普遍会白屏转圈两三秒再显示内容。这对我的博客影响巨大毕竟服务器和CDN都在国内被cf的DNS解析拉慢了速度可不能忍。
但我又不想放弃Cloudflare的优质服务和超强的防御力所以其实可以另辟蹊径通过CNAME解析使用CF的服务。官方只能NS接入但是CF Partner网站是允许CNAME接入的于是尝试使用这类网站管理解析。
我的其他几个域名是没有问题的正常接入。但是唯独主要域名eigeen.com不行提示这个错误:
![添加站点报错](https://os1.eigeen.com/static/2021/09/Snipaste_2021-09-06_09-48-15.png)
所有的Partner站点都是同样的报错
好家伙,我啥时候添加了?有内鬼?
经过一番思考和调查我高度怀疑是之前使用了百度云加速的缘故。百度云加速与Cloudflare的合作还算挺多的海外也有为Cloudflare提供的服务器。我怀疑百度之前也用了类似的方案但是在我取消接入百度云加速后他们并没有把我的域名从CF中删除于是就出现了这种冲突。
<!-- more -->
# 解决
最开始尝试了工单然后发现CF的工单简直就是摆设还折磨就没有正常人能回复我全都是bot而且发了几次工单全都告诉我一个信息去社区问那你工单的存在意义是什么
不过好在我从社区翻了几十条相关话题后,终于找到了一个可行的解决方案,就是**用NS方式接入一次域名就能验证所有权了**。所以我花了点时间改NS解析使用了一段时间CF后又切了回来再次尝试接入竟然成功了。
看来社区还是有点用的哈。
# CNAME接入Cloudflare
最开始使用的是笨牛网https://cdn.bnxb.com 他们也服务了很久不过就在我写这篇文章的时间段他们正清理违规接入的网站于是暂时关闭了网站停止登录和注册。于是我也尝试了另一家https://cdn.imtqy.com 使用体验同样不错。反正都是CF Partner功能是一样的。
> 参考文章教程:[Cloudflare 免费CDN自定义ip详细解释和配置教程 - 山野莽夫 (shanyemangfu.com)](https://www.shanyemangfu.com/cloudflare-ip.html)
>
> 文章是教你自定义IP我试了一下确实是百度云的节点不过物理地址也在美国快不了多少。想使用这种方法让你的网站变得神速还是不太可能。不过可以通过DNS解析服务商的功能让国外的访问者走CF线路减少流量费用。

View File

@ -0,0 +1,25 @@
---
title: 解决.git文件夹过大的问题
date: 2021-09-14 00:00:00
tags:
- git
- 技术
- 脚本
category: 技术
---
# 起因
事件起因是在之前的项目中,使用命令`git add .`将当前改动添加到暂存区。但是因为疏忽,刚刚放进来的几百兆大小的视频文件没有设置忽略,于是理所当然的被加入了暂存区...
然后,项目内的.git文件夹就一下子大了几百兆。我赶紧从暂存区取消掉视频文件但是.git文件夹并没有因此变小。继续执行`git commit`,即使版本管理中已经没有这个文件,.git文件夹依旧保持几百兆的大小。
# 解决方案
我认为这种情况肯定有解决方案,可以释放掉存在暂存区但实际上并没有被提交的无用文件。通过一番搜索和走了一点弯路后,发现只需要一条命令即可解决:
```shell
git gc --prune=now
```
执行命令后,文件夹大小立刻减小,问题解决。

View File

@ -0,0 +1,190 @@
---
title: 求生之路2安装8人房间插件
date: 2021-09-07 00:00:00
tags:
- 游戏
- 求生之路2
category: 游戏
---
这次又遇到了求生之路需要开多人房间的需求。在原版游戏中,战役模式最多只能四人同时游玩。即使服务器通过后台修改指令,让更多的人进入游戏房间,也只有四人能玩,剩下的玩家都进入旁观者模式。
所以,为了让更多的人同时游玩,不再出现“四人游戏,一人围观”的情况,我将本次安装插件的过程记录下来,方便回顾,顺便帮助更多人。
<!-- more -->
# 注意事项
插件安装后无法使用VAC启动。即你无法进入带有VAC验证的玩家房间在你的房间游玩的其他人无法获得成就。
当你不需要使用插件时在游戏启动选线内启用VAC就会自动忽略插件和原版游戏一模一样无需卸载插件。
# 下载插件
这里采用的是望夜的整合包。自己到插件官网下载核心、安装插件当然是可行的不过稍微麻烦一点。望夜的整合包包含了插件核心SourceMod和几个实用插件快速入门相当好用。
**原帖:**https://bbs.3dmgame.com/thread-4920489-1-1.html
原帖需要回复才能下载。这里为了方便一些没有账号的人,提供一份镜像链接:[蓝奏云链接](https://wwa.lanzoui.com/iL3Hjtptpcf)
> 请尽量去原帖下回复并下载,支持原作者!
>
> 此镜像不保证持续更新。
# 安装插件
## 1.复制到游戏目录内
### 解压文件
先将下载的安装包解压,得到以下文件。除去.html后缀的说明书和.png后缀的端口映射图片说明其他文件都是有用的**复制**。
![解压后文件](https://os1.eigeen.com/static/2021/09/image-20210907144001632.png)
### 打开游戏所在目录
在Steam库找到求生之路2右击选择"属性..."
![](https://os1.eigeen.com/static/2021/09/image-20210907144208816-1.png)
在弹出的窗口内依次点击"本地文件""浏览",即可自动打开游戏目录。
![](https://os1.eigeen.com/static/2021/09/image-20210907144320542-1.png)
### 粘贴文件
将之前复制的文件全部粘贴到游戏根目录下,如图所示。
![](https://os1.eigeen.com/static/2021/09/image-20210907144531559.png)
至此,安装即完成。
## 2.配置
### 选择安装插件
"JSGME.exe"是一个自动插件安装器,免去了手动安装的麻烦。运行程序,在界面中选择所需的插件。
![插件安装器](https://os1.eigeen.com/static/2021/09/image-20210907144925146.png)
若弹出这个警告,点击确定即可。
![忽略警告](https://os1.eigeen.com/static/2021/09/image-20210907145000886-1.png)
### 设置管理员
"L4D2管理员添加工具.exe"用于快速设置管理员。直接运行,点击“添加本机为管理员”。
![管理员添加工具](https://os1.eigeen.com/static/2021/09/image-20210907145139974.png)
输入自己的游戏内名称即Steam名称即可。
### 启动选项
在游戏的属性中,为启动选项添加`-insecure`。启用这个选项后将不再受到VAC保护。若不使用插件则将此参数删除。
![启动选项设置](https://os1.eigeen.com/static/2021/09/image-20210907145502797.png)
### 修改插件配置文件
每个插件都有自己的配置文件。到`...\Left 4 Dead 2\left4dead2\cfg\sourcemod`目录下查看并编辑相关的配置文件,根据文件内的指示修改即可。
## 3. 安装8人房间mod
进入游戏的创意工坊搜索“8 slots”关键字找到此mod点击订阅。
![安装8人房间插件](https://os1.eigeen.com/static/2021/09/image-20210907145755848.png)
至此,所有配置均已完成。进入游戏享受添加了插件后带来的游戏体验吧。
------
# 附录
## 游戏内指令
### 多人控制
!rhelp 显示插件使用说明
!sinfo 显示服务器人数信息
!jg 或 !joingame 加入游戏
!away 观察者
!ab 或 !addbot 增加一个电脑
!kb 踢除所有bot (只管理员可用)
!sset 设置服务器人数 (只管理员可用)
!bd 绑定键盘 L 键自动输入!joingame
!sp 显示还在加载的玩家
!zs 自杀
### 角色选择
!c 角色选择菜单
!csc 管理员设置某人角色
### 多重补给
!mmn 可随时变更多重补给倍数但不保存至cfg,下次游戏重开还是以cfg设置的为准.
### 功能插件
!rygive
### MVP排名
!mvp 立即显示排名
### 回血插件
!onhx 开启回血
!offhx 关闭回血
### 备弹量
!onammo 开启2倍备弹
!onammo1 开启自定备弹
!onammo2 开启无限备弹
!offammo 恢复默认备弹
!df 开关伤害修正
### 多特插件
2种刷新方式, !on14 和 !on142
!on14(按cfg配置来刷) , !on142 按人数来刷(最少8特) , !addif按人增加特感数 , !off14关 !it 设置多样特感刷新时间
### 开关无限推或自动红外或自动连跳
!ontui 开启无限推
!offtui 关闭无限推
!onhw 开启自动红外
!offhw 关闭自动红外
!onrb 开启按住空格自动连跳
!offrb 关闭按住空格自动连跳
### 反伤控制
AI及投掷,燃烧,爆炸类(榴弹除外)的不反
反伤百分比,0.5=50% 1.0=100% (取值范围0.0-2.0) 默认0.5
开关命令:!onfs !offfs

View File

@ -0,0 +1,54 @@
---
title: Matlab使用Simpson辛普森法计算数值积分
date: 2021-11-12 00:00:00
tags:
- Matlab
- 编程
category: 技术
---
![Matlab 运用Simpson辛普森公式求定积分附代码](http://os1.eigeen.com/static/2021/11/Snipaste_2021-11-12_14-41-58.png)
<!-- more -->
直接附代码
```matlab
simpson.m
function [out] = simpson(f,n,a,b)
%SIMPSON 此处显示有关此函数的摘要
% 此处显示详细说明
h=(b-a)/n;
s1=fi(f,1,h,a)+fi(f,n+1,h,a);
s2=0;
for index=3:2:n-1
s2=s2+2*fi(f,index,h,a);
end
s4=0;
for index=2:2:n
s4=s4+4*fi(f,index,h,a);
end
out=h/3*(s1+s2+s4);
end
function [out] = fi(f,i,h,a)
out=f(a+(i-1)*h);
end
```
调用:
```matlab
simpson(<函数句柄>, <n>, <下限>, <上限>)
```
> 参考文章
>
> [matlab用辛普森公式求积分_积分近似计算之辛普森公式_weixin_39726131的博客-CSDN博客](https://blog.csdn.net/weixin_39726131/article/details/110226598)

130
source/_posts/vite.md Normal file
View File

@ -0,0 +1,130 @@
---
title: Vite新建vue项目模板自用
date: 2022-03-15 00:00:00
tags:
- 前端
- 编程
- vue
- vite
category: 技术
---
# 初始化
## 创建项目
```shell
yarn create vite
cd ./module-name
yarn
```
## 引入常用依赖
### 功能
```shell
yarn add -S vue-router
```
### 界面
```shell
yarn add -D naive-ui
```
### 插件
```shell
yarn add -D unplugin-vue-components
yarn add -D unplugin-auto-import
yarn add -D @types/node
```
# 配置
## vite.config.ts
```typescript
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import Components from 'unplugin-vue-components/vite'
import AutoImport from 'unplugin-auto-import/vite'
import { resolve } from 'path'
import { NaiveUiResolver } from 'unplugin-vue-components/resolvers'
// https://vitejs.dev/config/
export default defineConfig({
plugins: [
vue(),
Components({
resolvers: [NaiveUiResolver()]
}),
AutoImport({
imports: ['vue', 'vue-router',]
})
],
resolve: {
// 配置路径别名
alias: {
'@': resolve('./src'),
},
},
})
```
## tsconfig.json
```json
"baseUrl": ".",
"paths": {
"@/*": ["src/*"]
}
```
## router.ts
```typescript
import { createRouter, createWebHistory } from "vue-router";
const routes = [
{
path: '/',
name: 'index',
component: () => import('@/components/Index.vue')
}
]
const router = createRouter({
routes,
history: createWebHistory()
})
export default router
```
## main.ts
```typescript
import { createApp } from 'vue'
import App from './App.vue'
import router from '@/modules/router'
const app = createApp(App)
app.use(router)
app.mount('#app')
```

View File

@ -0,0 +1,6 @@
---
title: categories
type: categories
layout: "categories"
---

5
source/friends/index.md Normal file
View File

@ -0,0 +1,5 @@
---
title: friends
type: friends
layout: "friends"
---

6
source/tags/index.md Normal file
View File

@ -0,0 +1,6 @@
---
title: tags
type: tags
layout: "tags"
---