From e0fe3ffd7d9a73d13e7ec84d9b334ad34e8aba30 Mon Sep 17 00:00:00 2001 From: Yuya Nishihara Date: Mon, 14 Nov 2022 10:27:55 +0900 Subject: [PATCH] simple_op_store: create temporary Thrift store in .jj/repo directory Otherwise rename() would fail if /tmp is on different device. --- lib/src/simple_op_store.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/src/simple_op_store.rs b/lib/src/simple_op_store.rs index ccfa0daee..98f61ae16 100644 --- a/lib/src/simple_op_store.rs +++ b/lib/src/simple_op_store.rs @@ -66,7 +66,7 @@ fn upgrade_to_thrift(store_path: PathBuf) -> std::io::Result<()> { let proto_store = ProtoOpStore::load(store_path.clone()); let tmp_store_dir = tempfile::Builder::new() .prefix("jj-op-store-upgrade-") - .tempdir() + .tempdir_in(store_path.parent().unwrap()) .unwrap(); let tmp_store_path = tmp_store_dir.path().to_path_buf();