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

Commands can't be called from pile checkout on > 1.0 #104

Closed
lucasdemarchi opened this issue Dec 3, 2022 · 0 comments · Fixed by #105
Closed

Commands can't be called from pile checkout on > 1.0 #104

lucasdemarchi opened this issue Dec 3, 2022 · 0 comments · Fixed by #105

Comments

@lucasdemarchi
Copy link
Contributor

Since the move to consider the pile checkout always relative to the main checkout, we can't call commands from inside the the patches/ directory (or pile checkout if you will). That is because all the commands will simply append "/{pile.dir}" and then fail with a backtrace.

I was looking at a quick fix, but it became worse due to the addition of worktree config. The result from git config --get-regexp 'pile\..*' may be incorrect as the worktree config is always from the "result-branch" checkout and the checkout for the pile branch will simply return the values for the local config, not worktree.

Fix is a bit more involved, but seems possible: we need to check the worktree list output and figure out if we are in the pile checkout or result-branch checkout. Prior to even creating a Config object.

lucasdemarchi added a commit that referenced this issue Dec 6, 2022
pile.dir is always relative to a result-dir: use that information so
git-pile tries to fallback in case commands are called from within the
pile checkout.

Fix: #104
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
lucasdemarchi added a commit that referenced this issue Dec 7, 2022
pile.dir is always relative to a result-dir: use that information so
git-pile tries to fallback in case commands are called from within the
pile checkout.

Fix: #104
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
lucasdemarchi added a commit that referenced this issue Dec 7, 2022
pile.dir is always relative to a result-dir: use that information so
git-pile tries to fallback in case commands are called from within the
pile checkout.

Fix: #104
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
lucasdemarchi added a commit that referenced this issue Dec 7, 2022
pile.dir is always relative to a result-dir: use that information so
git-pile tries to fallback in case commands are called from within the
pile checkout.

Fix: #104
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
lucasdemarchi added a commit that referenced this issue Dec 7, 2022
pile.dir is always relative to a result-dir: use that information so
git-pile tries to fallback in case commands are called from within the
pile checkout.

Fix: #104
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
lucasdemarchi added a commit that referenced this issue Dec 8, 2022
pile.dir is always relative to a result-dir: use that information so
git-pile tries to fallback in case commands are called from within the
pile checkout.

Fix: #104
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
lucasdemarchi added a commit that referenced this issue Dec 8, 2022
pile.dir is always relative to a result-dir: use that information so
git-pile tries to fallback in case commands are called from within the
pile checkout.

Fix: #104
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant