Skip to content

[New Port]: pre-commit #1225

Open
Open

Description

@RedZapdos123

Port Description:

I would like to port pre-commit to z/OS for the zopen community.

pre-commit is a widely used framework for managing and running pre-commit hooks across Git repositories. Making it available on z/OS would help developers use the same repository quality workflows on z/OS that they use on other platforms.

Upstream Repository URL:

https://github.com/pre-commit/pre-commit

Additional Information (Optional):

pre-commit is listed in the zopen porting wishlist:
https://github.com/orgs/zopencommunity/discussions/1019

Activity

  1. IgorTodorovskiIBM commented on Oct 22, 2026

    @IgorTodorovskiIBM
    Member

    /plan

  2. github-actions commented on Oct 22, 2026

    @github-actions

    ✅ zopen issue planner completed successfully!

    Generated by zopen issue planner

  3. github-actions commented on Oct 22, 2026

    @github-actions

    📋 Porting plan

    pre-commit is a Python-based framework for managing pre-commit hooks. The upstream project is mature and widely used. The port is straightforward since all dependencies (check_python, libyaml) are already in zopen, and a dedicated port repository exists: zopencommunity/pre-commitport.

    Build system: Python
    Dependencies (zopen): check_python libyaml
    Not yet in zopen: None
    Start from: pyyamlport/buildenv — Python, shares both dependencies

    Steps

    1. zopen-generate with Python template and check_python, libyaml as dependencies → verify: buildenv uses underscores, not hyphens
    2. Adapt upstream setup.py/pyproject.toml for z/OS if needed
    3. Build and test with z/OS Python (check_python)
    4. Add z/OS-specific patches only after a successful build
    5. Add coreutils if make install fails due to system install
    6. Document any z/OS-specific changes

    Watch out for:

    • Use check_python in ZOPEN_STABLE_DEPS
    • Only use underscores in buildenv variable names
    • Reference dependencies as ${<DEP>_HOME}
    • Guard z/OS changes with #ifdef __MVS__
    • Patch only after confirming a working build

    Automated plan by zopen-issue-plan · maintainers decide next steps · re-run with /plan

    Generated by zopen issue planner · copilot · gpt41 · 5.46 AIC · ⌖ 7.24 AIC · ⊞ 15.3K · ◷
    Comment /plan to run again

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions