Skip to main content

多分支 worktree 管理工具

Project description

yyt

多分支 worktree 管理工具(支持 krepo-nggit)。

安装

pip install yyt

使用

  • 创建 worktree:
yyt add <path> <branch>

这会在 ~/<path>/wpsmain~/<path>/wpsweb 下分别创建或切换到 <branch>

  • 列出 worktree:
yyt list
  • 移除 worktree:
yyt remove <path>

这会移除 ~/<path>/wpsmain~/<path>/wpsweb 的 worktree,并删除整个 <path> 目录。

  • 配置管理:
yyt set work_dir=~/workspace  # 设置工作目录
yyt config                    # 显示当前配置
  • 修改配置和生成构建脚本(仅限 Linux):
yyt modify                    # 修改 wpsweb/server/Makefile 和生成 build_server.sh
yyt modify --force            # 强制在非 Linux 系统上运行(不推荐)

这会自动查找 wpsweb 目录,并执行以下操作:

  1. 修改 server/Makefile
    • 去掉 -Wl,-s 参数
    • -O2 修改为 -g
  2. 生成 build_server.sh
    • 清空文件内容并写入构建脚本
    • 动态替换路径变量(基于当前执行路径)
    • 自动设置执行权限

注意: modify 命令仅在 Linux 系统上支持,因为它需要修改 Makefile 和生成 shell 脚本。

依赖

  • 需要本机已安装并在 PATH 中可用:krepo-nggit
  • 配置文件位置:~/.yyt.json

许可

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

yyt-0.1.6.tar.gz (7.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

yyt-0.1.6-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file yyt-0.1.6.tar.gz.

File metadata

  • Download URL: yyt-0.1.6.tar.gz
  • Upload date:
  • Size: 7.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for yyt-0.1.6.tar.gz
Algorithm Hash digest
SHA256 cd2899c889fa9aa6753b1193975bae0344d75574842239a0b8a967101b80bbca
MD5 5dbb2fd456fd2df7770d9612ecefb152
BLAKE2b-256 03f689157e40fb4c761115461b123976aecef763b30e8eea677daed91dab6c30

See more details on using hashes here.

File details

Details for the file yyt-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: yyt-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 8.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for yyt-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 7d4245ce35b04c6c133015c7e6d04d2eec25ab3d2c70aab73ba235a58ee7b810
MD5 35652f224582c56d98aa78762bbe30c4
BLAKE2b-256 cc5598e6def6f5c76aa72227dba0b7591dff9f0e090c97010abbf493e5d7e91b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page