Skip to content

Commit 78e5a3d

Browse files
committed
Auto-generated summary:
Commit Date: File changes: auto_commit.sh | 9 ++++++++- pyproject.toml | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-)
1 parent 53317e7 commit 78e5a3d

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

auto_commit.sh

+8-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,14 @@
11
#!/bin/bash
2+
# 获取当前时间戳
3+
timestamp=$(date +"%Y%m%d%H%M%S")
4+
5+
# 更新 pyproject.toml 中的 version
6+
sed -i '' -e "s/version = \".*\"/version = \"$timestamp\"/" pyproject.toml
7+
8+
echo "Version updated to: $timestamp"
29

310
# 获取提交日期
4-
last_commit_date=$(date)
11+
last_commit_date=$(timestamp)
512
# 获取最近的文件变动
613
file_changes=$(git diff --stat)
714
# 生成 commit 消息

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "pdf_regenerator"
3-
version = "0.0.202403081729"
3+
version = "20240308181159"
44
authors = [{name="Talbot3",email="[email protected]"}]
55
description = "PDF Regenerator是一款开源辅助阅读工具,可帮助重新生成 有辅助信息的PDF 文件。"
66
readme = "README.md"

0 commit comments

Comments
 (0)