Skip to content

Commit

Permalink
Merge pull request #77 from oldwinter/temp
Browse files Browse the repository at this point in the history
test3
  • Loading branch information
oldwinter committed Aug 9, 2023
2 parents d16032d + 78f4312 commit d299793
Show file tree
Hide file tree
Showing 12 changed files with 168 additions and 92 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/chatgpt-cr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ jobs:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
# optional
LANGUAGE: Chinese
PROMPT: "请用中文表达"
top_p: 1
temperature: 1
OPENAI_API_ENDPOINT: https://api.openai.com/v1
MODEL: gpt-3.5-turbo # https://platform.openai.com/docs/models
PROMPT: "请检查以下代码差异是否有混淆或不规范之处:" # example: Please check if there are any confusions or irregularities in the following code diff:
top_p: 1 # https://platform.openai.com/docs/api-reference/chat/create#chat/create-top_p
temperature: 1 # https://platform.openai.com/docs/api-reference/chat/create#chat/create-temperature
max_tokens: 10000
MAX_PATCH_LENGTH: 10000 # if the patch/diff length is large than MAX_PATCH_LENGTH, will be ignored and won't review. By default, with no MAX_PATCH_LENGTH set, there is also no limit for the patch/diff length.
14 changes: 14 additions & 0 deletions tmp-test-gpt-cr/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# 使用一个适当的基础镜像(这里使用 Python 3.8)
FROM python:3.8

# 设置工作目录
WORKDIR /app

# 将项目文件添加到容器中的工作目录
COPY . /app

# 安装依赖
RUN pip install -r requirements.txt

# 运行应用
CMD [ "python", "app.py" ]

This file was deleted.

11 changes: 0 additions & 11 deletions tmp-test-gpt-cr/安卓手机备份.md

This file was deleted.

11 changes: 0 additions & 11 deletions tmp-test-gpt-cr/安卓手机必备软件.md

This file was deleted.

24 changes: 24 additions & 0 deletions tmp-test-gpt-cr/本地优先的特点.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
date created: 2022-07-14
date modified: 2023-03-14
title: 本地优先的特点
---

x:: [[边缘云]]

我理解的最大2个优点:

- 数据私有
- 数据格式透明

[你好,THORN - 少数派](https://sspai.com/post/74228)

本地优先软件有七个特点:

1.**快速响应**:数据的主要副本保存在本地设备上,用户永远无需等待网络连接。与其他设备和用户的数据同步在后台静默地进行。
2.**多设备同步**:数据保存在每台设备的本地存储中,而且这些数据还能在用户工作的所有设备上自动同步。
3.**网络可选**:无论是否在线,用户随时可以读取和写入数据。网络连接可用时,本机设备会自动和其他设备同步。
4.**协作**:本机设备和其他设备(无论这些设备是否是您的)支持对同一数据进行实时协作。
5.**长寿**:您的数据应该可以无限期地访问。由于您具有本机软件和数据副本,这个软件就可以永远工作。即便软件制造商破产倒闭,您也可以继续运行该软件的最后发布版本。而且您可以将数据全部导出为通用格式,使用其他软件进行访问。
6.**安全和隐私**:和传统基于云的解决方案不通,本地优先软件不存在一个保存了用户所有数据的集中式数据库,您的本地设备只存储您自己的数据,通过避免使用集中式云数据库保存每个人的数据,本地优先软件具有很好的安全性和隐私性。
7.**数据所有权和控制权**:这里的数据所有权和控制权并不是法律意义上的,而是指本地优先软件制造商不会限制您访问本机副本数据,你被允许在任何时候通过任何方式复制和修改这些数据,而无需通过服务提供商的 API 去访问数据。
21 changes: 21 additions & 0 deletions tmp-test-gpt-cr/本库obsidian如何批量重命名文件.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
---
date created: 2022-08-24
date modified: 2023-03-14
title: 本库obsidian如何批量重命名文件
---

以将`+ MOC`等格式的文件批量重命名成`∑ MOC`为例。分2步:

- 批量重命名文件
- 批量重命名内部链接

## 批量重命名文件

[[vscode 文件批量重命名]]

## 批量重命名内部链接

- vscode中的正则搜索和替换
- 搜索表达式 `\[\[\+ (.*?)\]\]`
- 替换表达式 `[[∑ $1]]`
![](https://img2.oldwinter.top/202208241649678.png)
9 changes: 9 additions & 0 deletions tmp-test-gpt-cr/本库如何免费发布至web.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
date created: 2022-07-11
date modified: 2023-03-14
title: 本库如何免费发布至web
---

将obsidian双链笔记公开发布到网上的实操方法:[[obsidian 目前最完美的免费发布方案 - 渐进式教程]]

如果闭门造车,任何人都可能走错路。另一方面,只有输入没有输出,会让自己缺少反思机制,自以为自己懂了很多,其实一窍不通。所以[[要多分享自己的思考成果]]。为了自我成长的正反馈,也为了矫正反向的负反馈。不管反馈正负,比没有反馈,能带来更多的成长价值。
5 changes: 5 additions & 0 deletions tmp-test-gpt-cr/本库建设数字花园的愿景和理念.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
title: 本库建设数字花园的愿景和理念
date created: 2023-01-06
date modified: 2023-03-14
---
23 changes: 23 additions & 0 deletions tmp-test-gpt-cr/本库数字花园如何嵌入评论系统.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
date created: 2022-08-24
date modified: 2023-03-14
title: 本库数字花园如何嵌入评论系统
---

博客评论系统的常见3个方案:

- [[Waline]]:需要自己部署数据库、server端。支持匿名评论,可以导出评论数据。支持采用了[[SPA]]方案的博客。
- [[giscus]]:基于[[github discussion]],需要用户登录github再评论,支持markdown。
- [[gitalk]]:基于[[github issue]],功能和界面基本同[[giscus]]

目前

- [[obsidian pubilsh 官方方案]]嵌入评论系统失败,有点问题,待官方提供解决方案。
- [[obsidian jekyll发布方案]]使用gisucs,支持每一个笔记页面都是对应不同的评论主题,在github discussion中可见,且双向数据一致。
- [[obsidian quartz发布方案]]使用Waline,因为其是SPA方案,waline支持较好。

---

## 参考文献

[评论插件 | LearnData-开源笔记](https://newzone.top/web/Comments.html)
56 changes: 56 additions & 0 deletions tmp-test-gpt-cr/本机启用ssh免密自动登陆.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
---
aliases:
- vscode中启用ssh自动登陆
date created: 2022-05-11
date modified: 2023-03-14
title: 本机启用ssh自动登陆
---

1. 本地生成 RSA 密钥, 参考:[https://www.jianshu.com/p/09b81c07e03f](https://www.jianshu.com/p/09b81c07e03f)
2. 输入 (多个用户登录输入多次,将本机的证书公钥拷贝至远程机器):

```shell
ssh-copy-id -i ~/.ssh/id_rsa.pub [email protected]
```

成功后则会提示:

```bash
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed: "/Users/username/.ssh/id_rsa.pub"
/usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to filter out any that are already installed
/usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed -- if you are prompted now it is to install the new keys
[email protected]'s password:
Number of key(s) added: 1
Now try logging into the machine, with: "ssh '[email protected]'"
and check to make sure that only the key(s) you wanted were added.
```
3. 然后你登录服务器就会自动登录了
```bash
ssh [email protected]
```
如果本地之前已经配置好[[ssh config 文件]],则这边好像不用配了,vscode也能直接连上ssh
4. 这时候在 vscode 中安装好 `Remote-SSH` 插件, 点击 vscode 左下角绿色箭头打开远程连接, 选择 `open configuration file`, 输入:
```bash
Host 2.22_username
HostName 192.168.2.22
User username
PreferredAuthentications publickey
IdentityFile "/Users/username/.ssh/id_rsa"
Host 2.22_username2
HostName 192.168.2.22
User username2
PreferredAuthentications publickey
IdentityFile "/Users/username/.ssh/id_rsa"
```
保存后, 再次用 vscode 登录即可
9 changes: 9 additions & 0 deletions tmp-test-gpt-cr/鼻子呼吸.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
title: 鼻子呼吸
date created: 2023-03-31
date modified: 2023-03-31
---

日常情况、睡觉时候:[[鼻子呼吸]]有各种好处,脸型矫正,放松,利于睡眠。
而运动时、深呼吸时:[[鼻吸口呼]]效果也很好。除了超高强度有氧反应不过来的时候,任何其他时候都不要用嘴巴吸气。
如果有从小[[嘴巴呼吸]]的习惯,很大可能造成脸部下方内陷畸形。[[嘴巴呼吸]]也是[[睡眠呼吸暂停综合症]][[打呼噜]]的原因。

0 comments on commit d299793

Please sign in to comment.