about summary refs log tree commit diff
path: root/overlays/base/patches
diff options
context:
space:
mode:
Diffstat (limited to 'overlays/base/patches')
-rw-r--r--overlays/base/patches/git-crypt-worktrees.patch25
1 files changed, 25 insertions, 0 deletions
diff --git a/overlays/base/patches/git-crypt-worktrees.patch b/overlays/base/patches/git-crypt-worktrees.patch
new file mode 100644
index 0000000..908dad8
--- /dev/null
+++ b/overlays/base/patches/git-crypt-worktrees.patch
@@ -0,0 +1,25 @@
+diff --git a/commands.cpp b/commands.cpp
+index 81c401d..f825d7b 100644
+--- a/commands.cpp
++++ b/commands.cpp
+@@ -243,17 +243,17 @@ static std::string get_internal_state_path ()
+ 	std::vector<std::string>	command;
+ 	command.push_back("git");
+ 	command.push_back("rev-parse");
+-	command.push_back("--git-dir");
++	command.push_back("--git-path");
++	command.push_back("common/git-crypt");
+ 
+ 	std::stringstream		output;
+ 
+ 	if (!successful_exit(exec_command(command, output))) {
+-		throw Error("'git rev-parse --git-dir' failed - is this a Git repository?");
++		throw Error("'git rev-parse --git-path common/git-crypt' failed - is this a Git repository?");
+ 	}
+ 
+ 	std::string			path;
+ 	std::getline(output, path);
+-	path += "/git-crypt";
+ 
+ 	return path;
+ }