add some files
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# Vivado使用乘法器、除法器IP核实现乘除取余仿真
|
||||
### 环境
|
||||
Vivado 20.2
|
||||
**Vivado 20.2**
|
||||
## 添加并配置IP核
|
||||
1. 打开vivado,找到对应IP核,如下图
|
||||

|
||||
|
||||
121
BlogWebsite/Article/Technology/Typecho插件Aplayer使用教程.md
Normal file
121
BlogWebsite/Article/Technology/Typecho插件Aplayer使用教程.md
Normal file
@@ -0,0 +1,121 @@
|
||||
# APlayer-Typecho-Plugin
|
||||
Typecho plugin for a beautiful html5 music player https://github.com/DIYgod/APlayer
|
||||
|
||||
[Demo](http://blog.izgq.net/archives/456/)
|
||||
|
||||
## 介绍
|
||||
1. 通过简短的代码在文章或页面中插入漂亮的Html5播放器
|
||||
2. 自动解析lrc链接,可根据歌曲名和歌手名自动查找封面并生成缓存
|
||||
3. 支持网易云音乐单曲、歌单、专辑、歌手id的解析
|
||||
4. 与APlayer保持同步更新
|
||||
|
||||
## 声明
|
||||
本插件仅供个人学习研究使用,请勿将其用作商业用途,音乐版权归网易云音乐 music.163.com 所有。
|
||||
|
||||
## 安装
|
||||
安装前请确保插件中的cache目录可写(保存缓存用,否则会让博客加载缓慢)
|
||||
|
||||
主机需支持curl扩展,否则将可能不能自动查找封面、解析网易云音乐id、从https的url中获取歌词(file_get_contents在不支持openssl的主机中不能打开https链接)
|
||||
|
||||
Download ZIP, 解压,将 APlayer-Typecho-Plugin-master 重命名为 APlayer ,之后上传到你博客中的 /usr/plugins 目录,在后台启用即可
|
||||
|
||||
## 使用方法
|
||||
在文章或页面中加入下方格式的短代码即可
|
||||
|
||||
#### 调用格式
|
||||
|
||||
##### 单曲播放:
|
||||
```
|
||||
[player 属性1="值1" 属性2="值2" 属性3="值3" /]
|
||||
or
|
||||
[player 属性1="值1" 属性2="值2" 属性3="值3"][lrc]歌词[/lrc][/player]
|
||||
```
|
||||
|
||||
<mark style="background: #FFB86CA6;">example:</mark>
|
||||
```
|
||||
[player url="http://xxx.com/xxx.mp3" artist="Someone" title="Title" showlrc="false"/]
|
||||
|
||||
[player url="http://xxx.com/xxx.mp3" artist="Someone" title="Title"][lrc][00:00.00]Test lyrics[/lrc][/player]
|
||||
|
||||
网易云音乐:
|
||||
[player id="29947420"/]
|
||||
|
||||
```
|
||||
|
||||
|
||||
##### 多首歌曲:
|
||||
|
||||
```
|
||||
[player 属性1="值1" 属性2="值2" 属性3="值3"]
|
||||
[mp3 歌曲属性1="值1" 歌曲属性2="值2" 歌曲属性3="值3"/]
|
||||
[mp3 歌曲属性1="值1" 歌曲属性2="值2" 歌曲属性3="值3"][lrc]歌词[/lrc][/mp3]
|
||||
[/player]
|
||||
```
|
||||
|
||||
<mark style="background: #FFF3A3A6;">example:</mark>
|
||||
```
|
||||
[player theme="#e6d0b2" autoplay='1']
|
||||
[mp3 url="http://xxx.com/xxx.mp3" artist="Someone" title="Title"/]
|
||||
[mp3 url="http://xxx.com/xxx.mp3" artist="Someone" title="Title"][lrc][00:00.00]Test lyrics[/lrc][/mp3]
|
||||
[mp3 id="29947420"/] //网易云音乐歌曲id直接解析
|
||||
[/player]
|
||||
```
|
||||
|
||||
##### 网易云音乐解析示例:
|
||||
```
|
||||
[player id='346069,346080,29947420'/] //一次加入三首歌
|
||||
[player id='11362719' type='collect'/] //歌单
|
||||
[player id='3684' type='artist'/] //艺人热门五十首
|
||||
[player id='3084335' type='album'/] //专辑
|
||||
|
||||
```
|
||||
|
||||
如果要阻止代码解析成为播放器的话,用[]包裹[player]标签即可
|
||||
|
||||
```
|
||||
[[player id='3084335' type='album'/]]
|
||||
|
||||
输出:
|
||||
[player id='3084335' type='album'/]
|
||||
```
|
||||
|
||||
#### 用到的shortcode标签
|
||||
```
|
||||
[player] :整个播放器的标签,里面可用下面提到的所有属性
|
||||
[mp3] :可以用歌曲属性和网易云音乐属性,用于嵌套在[player]标签内部添加音乐
|
||||
[lrc] :用以添加文本的歌词,可嵌套在[mp3],[player]标签内部;只有当其父标签只定义一首歌的时候才起作用
|
||||
```
|
||||
|
||||
#### 关于各个标签的属性
|
||||
播放器配置(只能在[player]标签中使用):
|
||||
```
|
||||
showlrc: 当showlrc的值为 0 或 false 时,不显示歌词,否则将按照歌曲有无歌词来判断是否输出歌词
|
||||
autoplay: 是否自动播放,默认为 false (注:由于移动端浏览器限制,此功能在移动端浏览器将不起作用)
|
||||
theme: 设置主题颜色(十六进制),默认为 '#e6d0b2'
|
||||
```
|
||||
歌曲的属性(可在[mp3]或[player]中使用,不能用于修改整个歌单的属性):
|
||||
```
|
||||
url: mp3文件的链接,必需
|
||||
lrc: 歌词的lrc链接,非必需
|
||||
lrcoffset: 歌词整体提前时间(ms)若这个值为负数则为歌词整体延后的时间
|
||||
title: 歌曲的标题,若值为空则显示 Unknown
|
||||
artist: 歌曲的艺术家,若值为空则显示 Unknown
|
||||
cover: 封面图片链接,非必需,若该值为图片链接则按照链接加载封面图,若没有此属性则会按照title和artist自动从豆瓣api中查找封面图,若值为 false 则不自动查找封面,显示默认封面图片
|
||||
```
|
||||
网易云音乐(与歌曲属性用法一样)
|
||||
```
|
||||
id: 歌曲/歌单/专辑/艺人的id ,如果是歌曲的话可用 , 分隔歌曲id一次插入多首歌曲
|
||||
type: 用以判断id的类型,分为4种:song:歌曲,album:专辑,artist:艺人,collect:歌单
|
||||
```
|
||||
|
||||
### 清空歌词,播放列表、封面图片url的缓存
|
||||
|
||||
前往插件设置页面点击红色清空缓存按钮即可
|
||||
|
||||
## 支持作者
|
||||
如果你觉得这个项目对您有所帮助,不妨考虑小额支持我一下
|
||||
[支持作者](http://blog.izgq.net/donate.html)
|
||||
|
||||
## LICENSE
|
||||
|
||||
MIT © [zgq354](https://github.com/zgq354/)
|
||||
@@ -1 +0,0 @@
|
||||
[所有 - 滴答清单](https://dida365.com/webapp/#q/all/tasks)
|
||||
@@ -1,6 +1,6 @@
|
||||
# SSH舍弃密码,拥抱密钥
|
||||
## 前提条件
|
||||
使用**ROOT**用户(个人喜好)、客户端使用Windows PowerShell终端、服务端使用Debian12+或是Ubuntu24+
|
||||
使用**ROOT**用户(普通用户请自己加sudo)、客户端使用Windows PowerShell终端、服务端使用Debian12+或是Ubuntu24+
|
||||
## 客户端操作
|
||||
### 创建密钥对
|
||||
随便在哪按 WIN + X 再按 I 打开PowerShell终端
|
||||
@@ -22,7 +22,7 @@ ssh-keygen -t ed25519
|
||||
## 服务端操作
|
||||
### 上传公钥至服务器
|
||||
#### 创建实例阶段
|
||||
在创建实例阶段,如阿里云服务器,可以在**管理设置-登录凭证**中选择密钥对;**登录名**选择root;**密钥**对选择右边创建密钥对
|
||||
在创建实例阶段,如阿里云服务器,可以在**管理设置-登录凭证**中选择密钥对;**登录名**选择root;**密钥**对选择右边创建密钥对
|
||||
创建密钥对界面,密钥对名称随意;创建类型选择导入已有密钥对,
|
||||
在客户端Windows电脑中进入 ~\.ssh文件夹中,找到第一步创建的test.pub,用任意编辑器打开后,复制其内容到公钥内容框中,标签键随意,
|
||||
然后回到实例创建页面,在密钥对选择刚刚创建的密钥对即可
|
||||
@@ -32,16 +32,16 @@ ssh-keygen -t ed25519
|
||||
sudo -i
|
||||
```
|
||||
##### 复制公钥到服务器
|
||||
进入/root/.ssh文件夹
|
||||
进入/root/.ssh文件夹(普通用户进入到~/.ssh文件夹中)
|
||||
```shell
|
||||
cd /root/.ssh #root用户
|
||||
#cd ~/.ssh #普通用户
|
||||
```
|
||||
创建或编辑 authorized_keys 文件
|
||||
```shell
|
||||
vim authorized_keys
|
||||
vim authorized_keys #没有会自动创建
|
||||
```
|
||||
按 I 进入编辑模式,将公钥内容复制进去
|
||||
按 I 进入编辑模式,将公钥内容复制进去
|
||||
按 Esc ,输入 :wq 保存并退出
|
||||
|
||||
##### 编辑SSH-SERVER配置文件
|
||||
@@ -49,22 +49,22 @@ vim authorized_keys
|
||||
```shell
|
||||
cd /etc/ssh
|
||||
```
|
||||
这一步,有可能服务器没有安装SSH服务端,就没有sshd_config文件
|
||||
这一步,有可能服务器没有安装SSH服务端,就没有sshd_config文件
|
||||
安装ssh服务端
|
||||
```shell
|
||||
apt intsall openssh-server #安装openssh服务端
|
||||
```
|
||||
验证服务状态
|
||||
```shell
|
||||
systemctl status ssh #查看SSH服务运行状态
|
||||
systemctl status ssh #查看SSH服务运行状态,有些老版会是sshd
|
||||
```
|
||||
看到绿色的active(running)说明正常运行
|
||||
按Ctrl + C退回到命令行
|
||||
看到绿色的active(running)说明正常运行
|
||||
按Ctrl + C退回到命令行
|
||||
查看ssh目录下的文件
|
||||
```shell
|
||||
ls
|
||||
```
|
||||
看到有了sshd_config 和 sshd_config.d即可
|
||||
看到有了sshd_config 和 sshd_config.d即可
|
||||
编辑sshd_config文件
|
||||
```shell
|
||||
vim sshd_config
|
||||
@@ -77,11 +77,11 @@ PasswordAuthentication no #禁用密码
|
||||
```
|
||||
按 Esc 退出编辑模式,输入 :wq 保存并退出
|
||||
##### 重启SSH-SERVER服务
|
||||
一般使用
|
||||
一般使用(老版)
|
||||
```shell
|
||||
systemctl restart sshd
|
||||
```
|
||||
不行就试试
|
||||
不行就试试(新版)
|
||||
```shell
|
||||
service ssh restart
|
||||
```
|
||||
@@ -94,7 +94,7 @@ ssh -i ~/.ssh/test root@192.168.21.5
|
||||
```
|
||||
输出 Enter passphrase for key 提示输入私钥密码(输入的内容不会显示),之前没设置就直接按 Enter ;不出意外就可以连接上了
|
||||
### 编辑config文件进行简便连接
|
||||
**注意:** 只用使用Windows的终端才能简便连接,使用mobaxterm等ssh软件这个配置是没用的
|
||||
**注意:** 只用使用Windows的终端才能简便连接,<mark style="background: #ADCCFFA6;">使用mobaxterm等ssh软件这个配置是没用的</mark>
|
||||
在Windows客户端中,进入 ~\.ssh 文件夹
|
||||
|
||||
```shell
|
||||
@@ -111,7 +111,7 @@ Host test
|
||||
IdentityFile ~/.ssh/test
|
||||
User root
|
||||
```
|
||||
如果端口不是22,则需要加上端口,如ssh使用222端口
|
||||
如果端口不是22,则需要加上端口,如使用222端口
|
||||
```shell
|
||||
Host test
|
||||
HostName 192.168.21.5
|
||||
@@ -119,7 +119,7 @@ Host test
|
||||
Port 222
|
||||
User root
|
||||
```
|
||||
保存
|
||||
保存
|
||||
然后在PowerShell终端中就可以进行简便连接如
|
||||
```shell
|
||||
ssh test
|
||||
|
||||
Reference in New Issue
Block a user