Skip to content

Commit 514ccbe

Browse files
authored
Merge pull request #830 from RayWangQvQ/feature/829
[#829] Migrate form dotnet 6.0 to dotnet 8.0
2 parents e22a738 + 1a30103 commit 514ccbe

28 files changed

Lines changed: 112 additions & 111 deletions

File tree

.github/workflows/publish-release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
- name: Setup .NET Core
2222
uses: actions/setup-dotnet@v3
2323
with:
24-
dotnet-version: '6.0.x'
24+
dotnet-version: '8.0.x'
2525

2626
- name: Publish and Zip Release
2727
run: |
@@ -47,7 +47,7 @@ jobs:
4747
files: './src/Ray.BiliBiliTool.Console/bin/Publish/*.zip'
4848
token: ${{ secrets.GITHUB_TOKEN }}
4949
name: "BiliBiliToolPro-V${{ steps.release_notes.outputs.version }}"
50-
tag_name: ${{ github.event.inputs.version }}
50+
tag_name: ${{ steps.release_notes.outputs.version }}
5151
body: '${{ steps.release_notes.outputs.content }}'
5252
discussion_category_name: Announcements
5353
generate_release_notes: true

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
## 2.2.0
2+
- Migrate from dotnet 6.0 to dotnet 8.0
23
- Add Bruno to document the APIs
34
## 2.1.3
45
- Code refactory

Dockerfile

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
#See https://aka.ms/containerfastmode to understand how Visual Studio uses this Dockerfile to build your images for faster debugging.
22

3-
FROM mcr.microsoft.com/dotnet/runtime:6.0 AS base
3+
FROM mcr.microsoft.com/dotnet/runtime:8.0 AS base
44
WORKDIR /app
55

6-
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build
6+
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
77
WORKDIR /code
88
COPY ["src/Ray.BiliBiliTool.Console/Ray.BiliBiliTool.Console.csproj", "src/Ray.BiliBiliTool.Console/"]
99
COPY ["src/Ray.BiliBiliTool.DomainService/Ray.BiliBiliTool.DomainService.csproj", "src/Ray.BiliBiliTool.DomainService/"]
@@ -25,11 +25,9 @@ WORKDIR /app
2525
ENV TIME_ZONE=Asia/Shanghai
2626
COPY --from=publish /app/publish .
2727
COPY ./docker/scripts/* ./docker/crontab /app/scripts/
28+
RUN apt-get update
2829
RUN ln -fs /usr/share/zoneinfo/$TIME_ZONE /etc/localtime \
2930
&& echo $TIME_ZONE > /etc/timezone \
30-
&& cp /etc/apt/sources.list /etc/apt/sources.list.bak \
31-
&& sed -i 's/deb.debian.org/mirrors.163.com/g' /etc/apt/sources.list \
32-
&& sed -i 's/security.debian.org/mirrors.163.com/g' /etc/apt/sources.list \
3331
&& apt-get clean \
3432
&& apt-get update \
3533
&& apt-get install -y cron tzdata tofrodos \

Ray.BiliBiliTool.sln

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
4242
common.props = common.props
4343
Dockerfile = Dockerfile
4444
LICENSE = LICENSE
45-
publish.bat = publish.bat
4645
README.md = README.md
4746
EndProjectSection
4847
EndProject
@@ -66,7 +65,6 @@ EndProject
6665
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "docker", "docker", "{A93210FD-27B6-40E4-B08D-391F96CA2754}"
6766
ProjectSection(SolutionItems) = preProject
6867
docker\crontab = docker\crontab
69-
docker\entry.sh = docker\entry.sh
7068
docker\README.md = docker\README.md
7169
EndProjectSection
7270
EndProject
@@ -124,7 +122,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BiliAgentTest", "test\BiliA
124122
EndProject
125123
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "build", "build", "{75A9CC5C-DF92-4D72-A14C-625AA902855B}"
126124
ProjectSection(SolutionItems) = preProject
127-
docker\build\buildAndPushImage_multiArch.cmd = docker\build\buildAndPushImage_multiArch.cmd
128125
docker\build\buildImage.cmd = docker\build\buildImage.cmd
129126
docker\build\buildImage_amd64.cmd = docker\build\buildImage_amd64.cmd
130127
docker\build\buildImage_arm64.cmd = docker\build\buildImage_arm64.cmd

docker/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -156,9 +156,9 @@ docker run --rm \
156156

157157
## 7. 其他
158158

159-
代码编译和发布环境: mcr.microsoft.com/dotnet/sdk:6.0
159+
代码编译和发布环境: mcr.microsoft.com/dotnet/sdk:8.0
160160

161-
代码运行环境: mcr.microsoft.com/dotnet/runtime:6.0
161+
代码运行环境: mcr.microsoft.com/dotnet/runtime:8.0
162162

163163
apt-get 包源用的国内网易的
164164

docker/build/buildImage.cmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
REM start to build
44
echo Start to build docker image
55
@echo on
6-
docker build --tag zai7lou/bilibili_tool_pro:0.2.2 --tag zai7lou/bilibili_tool_pro:latest ../..
6+
docker build --tag zai7lou/bilibili_tool_pro:latest ../..
77
@echo off
88
pause

docker/build/buildImage_amd64.cmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@ REM https://www.docker.com/blog/multi-arch-build-and-images-the-simple-way/
55
REM https://segmentfault.com/a/1190000021166703
66
echo Start to build docker image with amd64-arch
77
@echo on
8-
docker buildx build --tag zai7lou/bilibili_tool_pro:0.0.5 --output "type=image,push=false" --platform linux/amd64 ../..
8+
docker buildx build --tag zai7lou/bilibili_tool_pro:latest --output "type=image,push=false" --platform linux/amd64 ../..
99
@echo off
1010
pause

docker/sample/docker-compose.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
version: '3.9'
21
services:
32
bilibili_tool:
43
image: ghcr.io/raywangqvq/bilibili_tool_pro

docs/questions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ curl -sSL https://ghproxy.com/https://raw.githubusercontent.com/RayWangQvQ/BiliB
214214
Windows:
215215
```
216216
# Run a separate PowerShell process because the script calls exit, so it will end the current PowerShell session.
217-
&powershell -NoProfile -ExecutionPolicy unrestricted -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; &([scriptblock]::Create((Invoke-WebRequest -UseBasicParsing 'https://dot.net/v1/dotnet-install.ps1'))) --channel 6.0 --no-cdn --verbose"
217+
&powershell -NoProfile -ExecutionPolicy unrestricted -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; &([scriptblock]::Create((Invoke-WebRequest -UseBasicParsing 'https://dot.net/v1/dotnet-install.ps1'))) --channel 8.0 --no-cdn --verbose"
218218
```
219219

220220
其他问题请见[官方文档](https://learn.microsoft.com/zh-cn/dotnet/core/tools/dotnet-install-script)

docs/runInLocal.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<!-- TOC depthFrom:2 -->
44

5-
- [1. 任意系统,但已安装`.NET 6.0`](#1-任意系统但已安装net-60)
5+
- [1. 任意系统,但已安装`.NET 8.0`](#1-任意系统但已安装net-80)
66
- [2. Win](#2-win)
77
- [3. Linux:](#3-linux)
88
- [4. macOS](#4-macos)
@@ -16,9 +16,9 @@
1616

1717
对于不是开发者的朋友,可以通过下载 [BiliBiliTool/release](https://github.com/RayWangQvQ/BiliBiliToolPro/releases) 到本地或任意服务器运行。
1818

19-
## 1. 任意系统,但已安装`.NET 6.0`
19+
## 1. 任意系统,但已安装`.NET 8.0`
2020

21-
任何操作系统,不管是Win还是Linux还是mac,只要已安装了`.NET 6.0` 环境,均可通过下载`net-dependent.zip`运行。
21+
任何操作系统,不管是Win还是Linux还是mac,只要已安装了`.NET 8.0` 环境,均可通过下载`net-dependent.zip`运行。
2222

2323
下载解压后,进入应用目录,执行`dotnet ./Ray.BiliBiliTool.Console.dll --runTasks=Login`
2424

@@ -28,7 +28,7 @@
2828

2929
![运行图示](imgs/run-exe.png)
3030

31-
P.S.这里的运行环境指的是 `.NET Runtime 6.0.0` ,安装方法可详见 [常见问题](questions.md) 中的 **本地或服务器如何安装.net环境**
31+
P.S.这里的运行环境指的是 `.NET Runtime 8.0.0` ,安装方法可详见 [常见问题](questions.md) 中的 **本地或服务器如何安装.net环境**
3232

3333
## 2. Win
3434

0 commit comments

Comments
 (0)