首先连接wifi:
解决apt的问题:
一直报错:
GPG error: http://ftp.ports.debian.org/debian-ports sid InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY E852514F5DF312F6
说明内置的密钥到期了,需要手工更新下密钥;下面是两种下载密钥的方式:
将密钥拷贝(使用scp或者lrzsz工具)到LicheeRV板上,执行:
sudo dpkg -i debian-ports-archive-keyring_2022.02.15_all.deb
即可更新密钥,然后可以正常进行apt更新:sudo apt-get update
执行完成后结果如下:
sipeed@sipeed:~$ sudo dpkg -i debian-ports-archive-keyring_2022.02.15_all.deb
Selecting previously unselected package debian-ports-archive-keyring.
(Reading database ... 91489 files and directories currently installed.)
Preparing to unpack debian-ports-archive-keyring_2022.02.15_all.deb ...
Unpacking debian-ports-archive-keyring (2022.02.15) ...
Setting up debian-ports-archive-keyring (2022.02.15) ... get update update
Get:1 https://mirrors.aliyun.com/debian-ports sid InRelease [65.1 kB]
Get:2 https://mirrors.aliyun.com/debian-ports unreleased InRelease [46.4 kB]
Get:3 https://mirrors.aliyun.com/debian-ports sid/main riscv64 Packages [23.5 MB]
21% [3 Packages 1,195 kB/23.5 MB 5%] 17.8 kB/s 20min 48s[ 4867.558841] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
24% [3 Packages 2,096 kB/23.5 MB 9%] 17.8 kB/s 19min 58s[ 4869.689087] [BH_WRN] miss interrupt!
26% [3 Packages 2,539 kB/23.5 MB 11%] 17.8 kB/s 19min 33s[ 4870.152929] [TXRX_WRN] status=6, retry=14, lastRate=0x4007
26% [3 Packages 2,686 kB/23.5 MB 11%] 17.8 kB/s 19min 25s[ 4870.428397] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
29% [3 Packages 3,473 kB/23.5 MB 15%] 468 kB/s 42s[ 4871.931347] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
30% [3 Packages 3,817 kB/23.5 MB 16%] 468 kB/s 42s[ 4873.129093] [BH_WRN] miss interrupt!
33% [3 Packages 4,587 kB/23.5 MB 20%] 468 kB/s 40s[ 4874.217574] [TXRX_WRN] status=6, retry=14, lastRate=0x4007
36% [3 Packages 5,668 kB/23.5 MB 24%] 468 kB/s 38s[ 4876.042134] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
37% [3 Packages 5,766 kB/23.5 MB 25%] 468 kB/s 37s[ 4876.413753] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
[ 4876.485150] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
[ 4876.553019] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
37% [3 Packages 5,816 kB/23.5 MB 25%] 479 kB/s 36s[ 4877.213222] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
38% [3 Packages 6,160 kB/23.5 MB 26%] 479 kB/s 36s[ 4877.531359] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
39% [3 Packages 6,602 kB/23.5 MB 28%] 479 kB/s 35s[ 4878.305458] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
41% [3 Packages 6,930 kB/23.5 MB 30%] 479 kB/s 34s[ 4879.020000] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
42% [3 Packages 7,307 kB/23.5 MB 31%] 479 kB/s 33s[ 4879.585592] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
43% [3 Packages 7,552 kB/23.5 MB 32%] 479 kB/s 33s[ 4879.962494] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
[ 4880.011190] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
[ 4880.128339] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
[ 4880.138877] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
45% [3 Packages 8,257 kB/23.5 MB 35%] 479 kB/s 31s[ 4881.949125] [BH_WRN] miss interrupt!
46% [3 Packages 8,683 kB/23.5 MB 37%] 479 kB/s 30s[ 4882.522923] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
[ 4882.538399] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
[ 4882.587343] [TXRX_WRN] status=6, retry=14, lastRate=0x4009
51% [3 Packages 9,977 kB/23.5 MB 43%] 515 kB/s 26s[ 4884.588439] sunxi-mmc 4021000.sdmmc: smc 1 p1 err, cmd 53, RD DCE !!
[ 4884.595623] sunxi-mmc 4021000.sdmmc: *****retry:start*****
[ 4884.601837] sunxi-mmc 4021000.sdmmc: REG_DRV_DL: 0x00030000
[ 4884.608052] sunxi-mmc 4021000.sdmmc: REG_SD_NTSR: 0x81710110
[ 4884.614392] sunxi-mmc 4021000.sdmmc: REG_NTDL_HS400: 0x20000010
[ 4884.621059] sunxi-mmc 4021000.sdmmc: *****retry:re-send cmd*****
[ 4884.627764] 1,end
67% [3 Packages 14.7 MB/23.5 MB 63%] 727 kB/s 12s[ 4890.629148] [BH_WRN] miss interrupt!
Get:4 https://mirrors.aliyun.com/debian-ports unreleased/main riscv64 Packages [12.2 kB]
97% [3 Packages store 0 B][ 4909.969226] [BH_WRN] miss interrupt!
Fetched 23.5 MB in 1min 15s (312 kB/s)
Reading package lists... Done
安装nginx:
sudo apt-get install nginx
完成后如下:
可以修改默认配置,端口号或者本地文档的存储位置,因为这里是演示就不再详细赘述:
接着配置好以后我们来安装hexo,通过hexo实现对本地markdown文章渲染成html。我们工作的过程是先在windos下生成对应服务端然后再转移到lichee上。
安装 Git(此下需要在windos下进行)
-
Windows:下载并安装 git.
-
Mac:使用 Homebrew, MacPorts 或者下载 安装程序。
-
Linux (Ubuntu, Debian):sudo apt-get install git-core
-
Linux (Fedora, Red Hat, CentOS):sudo yum install git-core
安装 Node.js
Node.js 为大多数平台提供了官方的 安装程序。对于中国大陆地区用户,可以前往 淘宝 Node.js 镜像 下载。
其它的安装方法:
安装 Hexo
所有必备的应用程序安装完成后,即可使用 npm 安装 Hexo。
$ npm install -g hexo-cli
进阶安装和使用
对于熟悉 npm 的进阶用户,可以仅局部安装 hexo
包。
$ npm install hexo
安装以后,可以使用以下两种方式执行 Hexo:
-
npx hexo <command>
-
将 Hexo 所在的目录下的 node_modules
添加到环境变量之中即可直接使用 hexo <command>
:
echo 'PATH="$PATH:./node_modules/.bin"' >> ~/.profile
然后安装完成以后是这样的:
Microsoft Windows [版本 10.0.19044.1645]
(c) Microsoft Corporation。保留所有权利。
C:\Users\13427>npm install -g hexo-cli
added 59 packages in 6s
npm notice
npm notice New minor version of npm available! 8.7.0 -> 8.8.0
npm notice Changelog: https://github.com/npm/cli/releases/tag/v8.8.0
npm notice Run npm install -g npm@8.8.0 to update!
npm notice
C:\Users\13427>hexo
Usage: hexo <command>
Commands:
help Get help on a command.
init Create a new Hexo folder.
version Display version information.
Global Options:
--config Specify config file instead of using _config.yml
--cwd Specify the CWD
--debug Display all verbose messages in the terminal
--draft Display draft posts
--safe Disable all plugins and scripts
--silent Hide output on console
For more help, you can use 'hexo help [command]' for the detailed information
or you can check the docs: http://hexo.io/docs/
选择一个目录来让hexo生成:
使用:
hexo init demo
生成目录成功如下:
到此准备环境就搭建完成了!