Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support workdir venv #1548

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Support workdir venv #1548

wants to merge 2 commits into from

Commits on Nov 21, 2024

  1. Support custom venv directory

    When using CI, we want to use a fresh venv for every build so bad venv
    created by one job does not break the next job, or bad change in a PR is
    not hidden by good venv created by a previous job.
    
    When using local development, you may want to have venv per ramen source
    directory. One case is using git worktree to have multiple ramen trees.
    With this change you can create a venv per ramen worktree.
    
    Example usage:
    
        hack/make-venv .venv/ramen
    
    Since this is the expected usage, add this path to gitignore, so using
    `git clean dxf` does not remove the directory.
    
    Signed-off-by: Nir Soffer <[email protected]>
    nirs committed Nov 21, 2024
    Configuration menu
    Copy the full SHA
    77c3ab5 View commit details
    Browse the repository at this point in the history
  2. Use per build venv

    Create venv inside the ramen checkout directory to have fresh venv for
    every build.
    
    Since drenv is not installed on the runner, we need to enter the venv in
    any step script. I hope we can find a way to enter the venv once for the
    entire job, but this is good enough for now.
    
    Signed-off-by: Nir Soffer <[email protected]>
    nirs committed Nov 21, 2024
    Configuration menu
    Copy the full SHA
    e46e9a4 View commit details
    Browse the repository at this point in the history