additional variables for hooks, especially the path of the mounted partition
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 48/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 领域
- backend
调研方向
Start by tracing how Timeshift invokes hook scripts and sets the existing TS_SNAPSHOT_PATH variable, then check how the mounted root path, snapshot mode, and live system state are detected. The issue does not name source files or tests, so locate those entry points in the repository first. Done means hook scripts can read variables for the mounted partition path, BTRFS or rsync mode, and live system status.
由索引模型根据 Issue 内容生成。
描述
Is your feature request related to a problem? Please describe.
thanks to #381 i'm working on scripts to also include resp. restore separate boot and efi partitions. it works quite well for now, but i want to extend them to also work on live systems and also cover the rsync mode and not just BTRFS. - basically that i don't have to think about the particular setup every time; just place the scripts in the hook folders and run Timeshift unless it is really an out of the box setup.
to make that work correctly, i need the path to the by Timeshift mounted root partition... in the BTRFS mode i can use the variable ${TS_SNAPSHOT_PATH} and go 3 levels up, but in the rsync mode this doesn't work because the snapshots are stored somewhere else entirely. 😒
Describe the solution you'd like
a solution to make it work easily would be an additional variable "TS_PARTITION_PATH" or the like with the path of the by Timeshift mounted partition.
...and while we are at it, it would also be quite convenient to have a variable indicating if Timeshift is working in BTRFS or rsync mode (e.g. "TS_MODE") and if it is running on a live system (e.g. "TS_LIVE_SYSTEM").
Describe alternatives you've considered
- i'm not sure what would be the best method of getting the correct(!) PID to guess the right path; because https://github.com/teejee2008/timeshift/issues/922#issuecomment-1220780174 confirms, that just searching for a
timshiftprocess wouldn't work reliable... but no matter how, it seems somewhat rickety to me. - for the Timeshift mode i parse '/etc/timeshift/timeshift.json' for now but a variable would avoid the dependence on
jqand make things easier. - for now i'm thinking about some checks if Timeshift is working on a live system, but if Timeshift itself is aware of that (is it? 🤔), it would be the best to get the information directly from Timeshift without fiddling around separately.
- 主要语言
- Vala
- 星标
- 4.3k
- 派生
- 162
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
linuxmint/timeshift 的其他 Issue
-
Delete snapshots: number mismatch可能已有人在做 @EthanNoble 于 6 天前认领。 未关闭
难度 1/5 1 小时以内 新手友好度 72/100
-
难度 1/5 1-3 小时 新手友好度 78/100
-
难度 1/5 1 小时以内 新手友好度 68/100
-
难度 3/5 1-2 天 新手友好度 45/100
-
难度 3/5 半天 新手友好度 55/100
查看 linuxmint/timeshift 的全部 Issue
相似的 Issue
-
api beginner story
难度 2/5 1-3 小时 新手友好度 78/100
NCSU-App-Development-Club/ios_fall_26#86 ·
维护者通常 4 天内回复
-
难度 2/5 1-3 小时 新手友好度 75/100
digital-go-jp/abr-geocoder#457 ·
维护者通常 3 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 78/100
pearu/agent-sandbox#422 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
OpenPrinting/cups#1826 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 1 天内回复