From d42e6c77b26bd6f47a59ad18158a79e6bddb30d1 Mon Sep 17 00:00:00 2001 From: Martin von Zweigbergk Date: Sat, 15 May 2021 09:16:31 -0700 Subject: [PATCH] project: rename project from Jujube to Jujutsu "Jujutsu" is probably much more familiar and relatable to most people. Also, I'm still not sure how "jujube" is supposed to be pronounced :P --- Cargo.lock | 6 +-- Cargo.toml | 8 ++-- README.md | 19 +++++----- lib/Cargo.toml | 6 +-- lib/benches/diff_bench.rs | 2 +- lib/src/git.rs | 2 +- lib/src/repo.rs | 2 +- lib/tests/test_bad_locking.rs | 4 +- lib/tests/test_commit_builder.rs | 10 ++--- lib/tests/test_commit_concurrent.rs | 4 +- lib/tests/test_diff_summary.rs | 6 +-- lib/tests/test_evolution.rs | 14 +++---- lib/tests/test_git.rs | 26 ++++++------- lib/tests/test_index.rs | 16 ++++---- lib/tests/test_init.rs | 4 +- lib/tests/test_load_repo.rs | 4 +- lib/tests/test_merge_trees.rs | 8 ++-- lib/tests/test_mut_repo.rs | 12 +++--- lib/tests/test_operations.rs | 8 ++-- lib/tests/test_revset.rs | 12 +++--- lib/tests/test_revset_graph_iterator.rs | 8 ++-- lib/tests/test_view.rs | 4 +- lib/tests/test_working_copy.rs | 14 +++---- lib/tests/test_working_copy_concurrent.rs | 12 +++--- src/commands.rs | 46 +++++++++++------------ src/diff_edit.rs | 16 ++++---- src/main.rs | 6 +-- src/styler.rs | 2 +- src/template_parser.rs | 6 +-- src/templater.rs | 6 +-- src/testutils.rs | 2 +- src/ui.rs | 6 +-- tests/smoke_test.rs | 2 +- tests/test_init_command.rs | 2 +- 34 files changed, 153 insertions(+), 152 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 39c72e03a..f04a56df3 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -541,7 +541,7 @@ dependencies = [ ] [[package]] -name = "jujube" +name = "jujutsu" version = "0.1.1" dependencies = [ "blake2", @@ -554,7 +554,7 @@ dependencies = [ "git2", "hex", "indoc", - "jujube-lib", + "jujutsu-lib", "pest", "pest_derive", "protobuf", @@ -569,7 +569,7 @@ dependencies = [ ] [[package]] -name = "jujube-lib" +name = "jujutsu-lib" version = "0.1.1" dependencies = [ "backoff", diff --git a/Cargo.toml b/Cargo.toml index 88e1f7379..2ee18d9ef 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,13 +1,13 @@ [package] -name = "jujube" +name = "jujutsu" version = "0.1.1" authors = ["Martin von Zweigbergk "] edition = "2018" license = "Apache-2.0" -description = "Jujube (an experimental VCS)" +description = "Jujutsu (an experimental VCS)" homepage = "https://github.com/martinvonz/jj" repository = "https://github.com/martinvonz/jj" -documentation = "https://docs.rs/jujube" +documentation = "https://docs.rs/jujutsu" readme = "README.md" keywords = ["VCS", "DVCS", "SCM", "Git", "Mercurial"] categories = ["command-line-utilities", "development-tools"] @@ -30,7 +30,7 @@ dirs = "3.0.1" git2 = "0.13.14" hex = "0.4.2" indoc = "1.0.3" -jujube-lib = { version = "=0.1.1", path = "lib"} +jujutsu-lib = { version = "=0.1.1", path = "lib"} pest = "2.1.3" pest_derive = "2.1.0" protobuf = { version = "2.22.1", features = ["with-bytes"] } diff --git a/README.md b/README.md index 89ede6d1a..aa9b9e31a 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Jujube +# Jujutsu ## Disclaimer @@ -20,8 +20,9 @@ blobs. However, the blobs are actually split into three types: normal files, symlinks (Unicode paths), and conflicts (more about that later). The command-line tool is called `jj` for now because it's easy to type and easy -to replace (rare in English). The project is called "Jujube" (a fruit) because -that's the first word I could think of that matched "jj". +to replace (rare in English). The project is called "Jujutsu" because it matches +"jj" (I initially called it "Jujube", but changed since jujutsu is more +well-known). ## Features @@ -34,7 +35,7 @@ readers who are already familiar with other VCSs. The tool currently has two backends. One is called "local store" and is very simple and inefficient. The other backend uses a Git repo as storage. The commits are stored as regular Git commits. Commits can be read from and written -to an existing Git repo. This makes it possible to create a Jujube repo and use +to an existing Git repo. This makes it possible to create a Jujutsu repo and use it as an alternative interface for a Git repo (it will be backed by the Git repo just like additional Git worktrees are). @@ -58,7 +59,7 @@ running. ### Supports Evolution -Jujube copies the Evolution feature from Mercurial. It keeps track of when a +Jujutsu copies the Evolution feature from Mercurial. It keeps track of when a commit gets rewritten. A commit has a list of predecessors in addition to the usual list of parents. This lets the tool figure out where to rebase descendant commits to when a commit has been rewritten (amended, rebased, etc.). See @@ -123,14 +124,14 @@ yet.) The criss-cross merge case becomes simpler. In Git, the virtual ancestor may have conflicts and you may get nested conflict markers in the working copy. In -Jujube, the result is a merge with multiple parts, which may even get simplified +Jujutsu, the result is a merge with multiple parts, which may even get simplified to not be recursive. The in-tree conflicts make it natural and easy to define the contents of a merge commit to be the difference compared to the merged parents (the so-called "evil" -part of the merge), so that's what Jujube does. Rebasing merge commits therefore -works as you would expect (Git and Mercurial both handle rebasing of merge -commits poorly). It's even possible to change the number of parents while +part of the merge), so that's what Jujutsu does. Rebasing merge commits +therefore works as you would expect (Git and Mercurial both handle rebasing of +merge commits poorly). It's even possible to change the number of parents while rebasing, so if A is non-merge commit, you can make it a merge commit with `jj rebase -r A -d B -d C`. `jj diff -r ` will show you the diff compared to the merged parents. diff --git a/lib/Cargo.toml b/lib/Cargo.toml index bf6bb7b1c..b45d4998d 100644 --- a/lib/Cargo.toml +++ b/lib/Cargo.toml @@ -1,13 +1,13 @@ [package] -name = "jujube-lib" +name = "jujutsu-lib" version = "0.1.1" authors = ["Martin von Zweigbergk "] edition = "2018" license = "Apache-2.0" -description = "Library for Jujube (an experimental VCS)" +description = "Library for Jujutsu (an experimental VCS)" homepage = "https://github.com/martinvonz/jj" repository = "https://github.com/martinvonz/jj" -documentation = "https://docs.rs/jujube" +documentation = "https://docs.rs/jujutsu" readme = "../README.md" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/lib/benches/diff_bench.rs b/lib/benches/diff_bench.rs index 8bc0b7812..09c82f36a 100644 --- a/lib/benches/diff_bench.rs +++ b/lib/benches/diff_bench.rs @@ -2,7 +2,7 @@ extern crate test; -use jujube_lib::diff; +use jujutsu_lib::diff; use test::Bencher; fn unchanged_lines(count: usize) -> (String, String) { diff --git a/lib/src/git.rs b/lib/src/git.rs index 3cfcdc4db..2a2a31653 100644 --- a/lib/src/git.rs +++ b/lib/src/git.rs @@ -24,7 +24,7 @@ pub enum GitImportError { InternalGitError(#[from] git2::Error), } -// Reflect changes made in the underlying Git repo in the Jujube repo. +// Reflect changes made in the underlying Git repo in the Jujutsu repo. pub fn import_refs( mut_repo: &mut MutableRepo, git_repo: &git2::Repository, diff --git a/lib/src/repo.rs b/lib/src/repo.rs index 75f43f4d1..d547f18df 100644 --- a/lib/src/repo.rs +++ b/lib/src/repo.rs @@ -133,7 +133,7 @@ impl Debug for ReadonlyRepo { #[derive(Error, Debug, PartialEq)] pub enum RepoLoadError { - #[error("There is no Jujube repo in {0}")] + #[error("There is no Jujutsu repo in {0}")] NoRepoHere(PathBuf), } diff --git a/lib/tests/test_bad_locking.rs b/lib/tests/test_bad_locking.rs index 9c246fe2e..0ffe331d6 100644 --- a/lib/tests/test_bad_locking.rs +++ b/lib/tests/test_bad_locking.rs @@ -14,8 +14,8 @@ use std::path::Path; -use jujube_lib::repo::ReadonlyRepo; -use jujube_lib::testutils; +use jujutsu_lib::repo::ReadonlyRepo; +use jujutsu_lib::testutils; use tempfile::TempDir; use test_case::test_case; diff --git a/lib/tests/test_commit_builder.rs b/lib/tests/test_commit_builder.rs index fd52a480f..8e66c3335 100644 --- a/lib/tests/test_commit_builder.rs +++ b/lib/tests/test_commit_builder.rs @@ -12,11 +12,11 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube_lib::commit_builder::CommitBuilder; -use jujube_lib::repo_path::FileRepoPath; -use jujube_lib::settings::UserSettings; -use jujube_lib::testutils; -use jujube_lib::tree::DiffSummary; +use jujutsu_lib::commit_builder::CommitBuilder; +use jujutsu_lib::repo_path::FileRepoPath; +use jujutsu_lib::settings::UserSettings; +use jujutsu_lib::testutils; +use jujutsu_lib::tree::DiffSummary; use test_case::test_case; #[test_case(false ; "local store")] diff --git a/lib/tests/test_commit_concurrent.rs b/lib/tests/test_commit_concurrent.rs index aa1c801e5..fcc1c43e9 100644 --- a/lib/tests/test_commit_concurrent.rs +++ b/lib/tests/test_commit_concurrent.rs @@ -15,8 +15,8 @@ use std::cmp::max; use std::thread; -use jujube_lib::repo::ReadonlyRepo; -use jujube_lib::{dag_walk, testutils}; +use jujutsu_lib::repo::ReadonlyRepo; +use jujutsu_lib::{dag_walk, testutils}; use test_case::test_case; fn count_non_merge_operations(repo: &ReadonlyRepo) -> usize { diff --git a/lib/tests/test_diff_summary.rs b/lib/tests/test_diff_summary.rs index a97434509..cb54b4d04 100644 --- a/lib/tests/test_diff_summary.rs +++ b/lib/tests/test_diff_summary.rs @@ -12,9 +12,9 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube_lib::repo_path::FileRepoPath; -use jujube_lib::testutils; -use jujube_lib::tree::DiffSummary; +use jujutsu_lib::repo_path::FileRepoPath; +use jujutsu_lib::testutils; +use jujutsu_lib::tree::DiffSummary; use test_case::test_case; #[test_case(false ; "local store")] diff --git a/lib/tests/test_evolution.rs b/lib/tests/test_evolution.rs index 19c3404ab..9c8ad83c4 100644 --- a/lib/tests/test_evolution.rs +++ b/lib/tests/test_evolution.rs @@ -14,15 +14,15 @@ #![feature(assert_matches)] -use jujube_lib::commit::Commit; -use jujube_lib::commit_builder::CommitBuilder; -use jujube_lib::evolution::{ +use jujutsu_lib::commit::Commit; +use jujutsu_lib::commit_builder::CommitBuilder; +use jujutsu_lib::evolution::{ DivergenceResolution, DivergenceResolver, OrphanResolution, OrphanResolver, }; -use jujube_lib::repo::ReadonlyRepo; -use jujube_lib::repo_path::FileRepoPath; -use jujube_lib::settings::UserSettings; -use jujube_lib::testutils; +use jujutsu_lib::repo::ReadonlyRepo; +use jujutsu_lib::repo_path::FileRepoPath; +use jujutsu_lib::settings::UserSettings; +use jujutsu_lib::testutils; use test_case::test_case; #[must_use] diff --git a/lib/tests/test_git.rs b/lib/tests/test_git.rs index 20a5ebe3e..6a7599228 100644 --- a/lib/tests/test_git.rs +++ b/lib/tests/test_git.rs @@ -17,12 +17,12 @@ use std::path::PathBuf; use std::sync::Arc; use git2::Oid; -use jujube_lib::commit::Commit; -use jujube_lib::git::{GitFetchError, GitPushError}; -use jujube_lib::repo::ReadonlyRepo; -use jujube_lib::settings::UserSettings; -use jujube_lib::store::CommitId; -use jujube_lib::{git, testutils}; +use jujutsu_lib::commit::Commit; +use jujutsu_lib::git::{GitFetchError, GitPushError}; +use jujutsu_lib::repo::ReadonlyRepo; +use jujutsu_lib::settings::UserSettings; +use jujutsu_lib::store::CommitId; +use jujutsu_lib::{git, testutils}; use maplit::hashset; use tempfile::TempDir; @@ -69,7 +69,7 @@ fn test_import_refs() { let mut tx = repo.start_transaction("test"); let mut_repo = tx.mut_repo(); let heads_before: HashSet<_> = repo.view().heads().clone(); - jujube_lib::git::import_refs(mut_repo, &git_repo).unwrap_or_default(); + jujutsu_lib::git::import_refs(mut_repo, &git_repo).unwrap_or_default(); let view = mut_repo.view(); let expected_heads: HashSet<_> = heads_before .union(&hashset!( @@ -118,7 +118,7 @@ fn test_import_refs_reimport() { let heads_before = repo.view().heads().clone(); let mut tx = repo.start_transaction("test"); - jujube_lib::git::import_refs(tx.mut_repo(), &git_repo).unwrap_or_default(); + jujutsu_lib::git::import_refs(tx.mut_repo(), &git_repo).unwrap_or_default(); tx.commit(); // Delete feature1 and rewrite feature2 @@ -129,7 +129,7 @@ fn test_import_refs_reimport() { repo = repo.reload().unwrap(); let mut tx = repo.start_transaction("test"); let mut_repo = tx.mut_repo(); - jujube_lib::git::import_refs(mut_repo, &git_repo).unwrap_or_default(); + jujutsu_lib::git::import_refs(mut_repo, &git_repo).unwrap_or_default(); let view = mut_repo.view(); // TODO: commit3 and commit4 should probably be removed @@ -201,7 +201,7 @@ fn test_import_refs_merge() { git_ref(&git_repo, "refs/heads/forward-remove", commit1.id()); git_ref(&git_repo, "refs/heads/remove-forward", commit1.id()); let mut tx = repo.start_transaction("initial import"); - jujube_lib::git::import_refs(tx.mut_repo(), &git_repo).unwrap_or_default(); + jujutsu_lib::git::import_refs(tx.mut_repo(), &git_repo).unwrap_or_default(); tx.commit(); repo = repo.reload().unwrap(); @@ -214,7 +214,7 @@ fn test_import_refs_merge() { delete_git_ref(&git_repo, "refs/heads/remove-forward"); git_ref(&git_repo, "refs/heads/add-add", commit3.id()); let mut tx1 = repo.start_transaction("concurrent import 1"); - jujube_lib::git::import_refs(tx1.mut_repo(), &git_repo).unwrap_or_default(); + jujutsu_lib::git::import_refs(tx1.mut_repo(), &git_repo).unwrap_or_default(); tx1.commit(); // The other concurrent operation: @@ -226,7 +226,7 @@ fn test_import_refs_merge() { git_ref(&git_repo, "refs/heads/remove-forward", commit2.id()); git_ref(&git_repo, "refs/heads/add-add", commit4.id()); let mut tx2 = repo.start_transaction("concurrent import 2"); - jujube_lib::git::import_refs(tx2.mut_repo(), &git_repo).unwrap_or_default(); + jujutsu_lib::git::import_refs(tx2.mut_repo(), &git_repo).unwrap_or_default(); tx2.commit(); // Reload the repo, causing the operations to be merged. @@ -283,7 +283,7 @@ fn test_import_refs_empty_git_repo() { let heads_before = repo.view().heads().clone(); let mut tx = repo.start_transaction("test"); let mut_repo = tx.mut_repo(); - jujube_lib::git::import_refs(mut_repo, &git_repo).unwrap_or_default(); + jujutsu_lib::git::import_refs(mut_repo, &git_repo).unwrap_or_default(); assert_eq!(*mut_repo.view().heads(), heads_before); assert_eq!(mut_repo.view().git_refs().len(), 0); tx.discard(); diff --git a/lib/tests/test_index.rs b/lib/tests/test_index.rs index 5c4fce37c..cabcc3578 100644 --- a/lib/tests/test_index.rs +++ b/lib/tests/test_index.rs @@ -14,14 +14,14 @@ use std::sync::Arc; -use jujube_lib::commit::Commit; -use jujube_lib::commit_builder::CommitBuilder; -use jujube_lib::index::IndexRef; -use jujube_lib::repo::ReadonlyRepo; -use jujube_lib::settings::UserSettings; -use jujube_lib::store::CommitId; -use jujube_lib::testutils; -use jujube_lib::testutils::{create_random_commit, CommitGraphBuilder}; +use jujutsu_lib::commit::Commit; +use jujutsu_lib::commit_builder::CommitBuilder; +use jujutsu_lib::index::IndexRef; +use jujutsu_lib::repo::ReadonlyRepo; +use jujutsu_lib::settings::UserSettings; +use jujutsu_lib::store::CommitId; +use jujutsu_lib::testutils; +use jujutsu_lib::testutils::{create_random_commit, CommitGraphBuilder}; use test_case::test_case; #[must_use] diff --git a/lib/tests/test_init.rs b/lib/tests/test_init.rs index bed7a7b62..5cd807834 100644 --- a/lib/tests/test_init.rs +++ b/lib/tests/test_init.rs @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube_lib::repo::ReadonlyRepo; -use jujube_lib::testutils; +use jujutsu_lib::repo::ReadonlyRepo; +use jujutsu_lib::testutils; #[test] fn test_init_local() { diff --git a/lib/tests/test_load_repo.rs b/lib/tests/test_load_repo.rs index 68c97528d..acdce5674 100644 --- a/lib/tests/test_load_repo.rs +++ b/lib/tests/test_load_repo.rs @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube_lib::repo::{ReadonlyRepo, RepoLoadError, RepoLoader}; -use jujube_lib::testutils; +use jujutsu_lib::repo::{ReadonlyRepo, RepoLoadError, RepoLoader}; +use jujutsu_lib::testutils; use test_case::test_case; #[test] diff --git a/lib/tests/test_merge_trees.rs b/lib/tests/test_merge_trees.rs index a89fd5d82..766977d21 100644 --- a/lib/tests/test_merge_trees.rs +++ b/lib/tests/test_merge_trees.rs @@ -12,10 +12,10 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube_lib::repo_path::{DirRepoPath, FileRepoPath, RepoPath}; -use jujube_lib::store::{ConflictPart, TreeValue}; -use jujube_lib::tree::Tree; -use jujube_lib::{testutils, trees}; +use jujutsu_lib::repo_path::{DirRepoPath, FileRepoPath, RepoPath}; +use jujutsu_lib::store::{ConflictPart, TreeValue}; +use jujutsu_lib::tree::Tree; +use jujutsu_lib::{testutils, trees}; use test_case::test_case; #[test_case(false ; "local store")] diff --git a/lib/tests/test_mut_repo.rs b/lib/tests/test_mut_repo.rs index ea43109d5..7d264e882 100644 --- a/lib/tests/test_mut_repo.rs +++ b/lib/tests/test_mut_repo.rs @@ -14,12 +14,12 @@ use std::sync::Arc; -use jujube_lib::commit_builder::CommitBuilder; -use jujube_lib::repo_path::FileRepoPath; -use jujube_lib::store::{Conflict, ConflictId, ConflictPart, TreeValue}; -use jujube_lib::store_wrapper::StoreWrapper; -use jujube_lib::testutils; -use jujube_lib::testutils::CommitGraphBuilder; +use jujutsu_lib::commit_builder::CommitBuilder; +use jujutsu_lib::repo_path::FileRepoPath; +use jujutsu_lib::store::{Conflict, ConflictId, ConflictPart, TreeValue}; +use jujutsu_lib::store_wrapper::StoreWrapper; +use jujutsu_lib::testutils; +use jujutsu_lib::testutils::CommitGraphBuilder; use test_case::test_case; // TODO Many of the tests here are not run with Git because they end up creating diff --git a/lib/tests/test_operations.rs b/lib/tests/test_operations.rs index 672e39e0f..067fb1476 100644 --- a/lib/tests/test_operations.rs +++ b/lib/tests/test_operations.rs @@ -14,10 +14,10 @@ use std::path::Path; -use jujube_lib::commit_builder::CommitBuilder; -use jujube_lib::repo::RepoRef; -use jujube_lib::store::CommitId; -use jujube_lib::testutils; +use jujutsu_lib::commit_builder::CommitBuilder; +use jujutsu_lib::repo::RepoRef; +use jujutsu_lib::store::CommitId; +use jujutsu_lib::testutils; use test_case::test_case; fn list_dir(dir: &Path) -> Vec { diff --git a/lib/tests/test_revset.rs b/lib/tests/test_revset.rs index 8d641e15b..a26ccad89 100644 --- a/lib/tests/test_revset.rs +++ b/lib/tests/test_revset.rs @@ -12,12 +12,12 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube_lib::commit_builder::CommitBuilder; -use jujube_lib::repo::RepoRef; -use jujube_lib::revset::{evaluate_expression, parse, resolve_symbol, RevsetError}; -use jujube_lib::store::{CommitId, MillisSinceEpoch, Signature, Timestamp}; -use jujube_lib::testutils; -use jujube_lib::testutils::CommitGraphBuilder; +use jujutsu_lib::commit_builder::CommitBuilder; +use jujutsu_lib::repo::RepoRef; +use jujutsu_lib::revset::{evaluate_expression, parse, resolve_symbol, RevsetError}; +use jujutsu_lib::store::{CommitId, MillisSinceEpoch, Signature, Timestamp}; +use jujutsu_lib::testutils; +use jujutsu_lib::testutils::CommitGraphBuilder; use test_case::test_case; #[test_case(false ; "local store")] diff --git a/lib/tests/test_revset_graph_iterator.rs b/lib/tests/test_revset_graph_iterator.rs index c22b52e9c..9f4d8613c 100644 --- a/lib/tests/test_revset_graph_iterator.rs +++ b/lib/tests/test_revset_graph_iterator.rs @@ -12,10 +12,10 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube_lib::revset::revset_for_commits; -use jujube_lib::revset_graph_iterator::RevsetGraphEdge; -use jujube_lib::testutils; -use jujube_lib::testutils::CommitGraphBuilder; +use jujutsu_lib::revset::revset_for_commits; +use jujutsu_lib::revset_graph_iterator::RevsetGraphEdge; +use jujutsu_lib::testutils; +use jujutsu_lib::testutils::CommitGraphBuilder; use maplit::hashset; use test_case::test_case; diff --git a/lib/tests/test_view.rs b/lib/tests/test_view.rs index 5d0554941..40f6a9998 100644 --- a/lib/tests/test_view.rs +++ b/lib/tests/test_view.rs @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube_lib::testutils; -use jujube_lib::testutils::CommitGraphBuilder; +use jujutsu_lib::testutils; +use jujutsu_lib::testutils::CommitGraphBuilder; use maplit::hashset; use test_case::test_case; diff --git a/lib/tests/test_working_copy.rs b/lib/tests/test_working_copy.rs index 3a3e288f4..3b0be4bec 100644 --- a/lib/tests/test_working_copy.rs +++ b/lib/tests/test_working_copy.rs @@ -18,13 +18,13 @@ use std::io::{Read, Write}; use std::os::unix::fs::PermissionsExt; use std::sync::Arc; -use jujube_lib::commit_builder::CommitBuilder; -use jujube_lib::repo::ReadonlyRepo; -use jujube_lib::repo_path::{FileRepoPath, RepoPath}; -use jujube_lib::settings::UserSettings; -use jujube_lib::store::TreeValue; -use jujube_lib::testutils; -use jujube_lib::tree_builder::TreeBuilder; +use jujutsu_lib::commit_builder::CommitBuilder; +use jujutsu_lib::repo::ReadonlyRepo; +use jujutsu_lib::repo_path::{FileRepoPath, RepoPath}; +use jujutsu_lib::settings::UserSettings; +use jujutsu_lib::store::TreeValue; +use jujutsu_lib::testutils; +use jujutsu_lib::tree_builder::TreeBuilder; use test_case::test_case; #[test_case(false ; "local store")] diff --git a/lib/tests/test_working_copy_concurrent.rs b/lib/tests/test_working_copy_concurrent.rs index 7f62e1ddf..211c94515 100644 --- a/lib/tests/test_working_copy_concurrent.rs +++ b/lib/tests/test_working_copy_concurrent.rs @@ -16,12 +16,12 @@ use std::cmp::max; use std::collections::HashSet; use std::thread; -use jujube_lib::commit_builder::CommitBuilder; -use jujube_lib::repo::ReadonlyRepo; -use jujube_lib::repo_path::FileRepoPath; -use jujube_lib::store::CommitId; -use jujube_lib::testutils; -use jujube_lib::working_copy::CheckoutError; +use jujutsu_lib::commit_builder::CommitBuilder; +use jujutsu_lib::repo::ReadonlyRepo; +use jujutsu_lib::repo_path::FileRepoPath; +use jujutsu_lib::store::CommitId; +use jujutsu_lib::testutils; +use jujutsu_lib::working_copy::CheckoutError; use test_case::test_case; #[test_case(false ; "local store")] diff --git a/src/commands.rs b/src/commands.rs index 31c844396..3ce369072 100644 --- a/src/commands.rs +++ b/src/commands.rs @@ -28,30 +28,30 @@ use std::{fs, io}; use clap::{crate_version, App, Arg, ArgMatches, SubCommand}; use criterion::Criterion; -use jujube_lib::commit::Commit; -use jujube_lib::commit_builder::CommitBuilder; -use jujube_lib::dag_walk::topo_order_reverse; -use jujube_lib::evolution::{ +use jujutsu_lib::commit::Commit; +use jujutsu_lib::commit_builder::CommitBuilder; +use jujutsu_lib::dag_walk::topo_order_reverse; +use jujutsu_lib::evolution::{ DivergenceResolution, DivergenceResolver, OrphanResolution, OrphanResolver, }; -use jujube_lib::files::DiffLine; -use jujube_lib::git::GitFetchError; -use jujube_lib::index::HexPrefix; -use jujube_lib::op_store::{OpStore, OpStoreError, OperationId}; -use jujube_lib::operation::Operation; -use jujube_lib::repo::{MutableRepo, ReadonlyRepo, RepoLoadError, RepoLoader}; -use jujube_lib::repo_path::RepoPath; -use jujube_lib::revset::{RevsetError, RevsetParseError}; -use jujube_lib::revset_graph_iterator::RevsetGraphEdgeType; -use jujube_lib::rewrite::{back_out_commit, merge_commit_trees, rebase_commit}; -use jujube_lib::settings::UserSettings; -use jujube_lib::store::{StoreError, Timestamp, TreeValue}; -use jujube_lib::store_wrapper::StoreWrapper; -use jujube_lib::transaction::Transaction; -use jujube_lib::tree::Tree; -use jujube_lib::trees::Diff; -use jujube_lib::working_copy::{CheckoutStats, WorkingCopy}; -use jujube_lib::{conflicts, files, git, revset}; +use jujutsu_lib::files::DiffLine; +use jujutsu_lib::git::GitFetchError; +use jujutsu_lib::index::HexPrefix; +use jujutsu_lib::op_store::{OpStore, OpStoreError, OperationId}; +use jujutsu_lib::operation::Operation; +use jujutsu_lib::repo::{MutableRepo, ReadonlyRepo, RepoLoadError, RepoLoader}; +use jujutsu_lib::repo_path::RepoPath; +use jujutsu_lib::revset::{RevsetError, RevsetParseError}; +use jujutsu_lib::revset_graph_iterator::RevsetGraphEdgeType; +use jujutsu_lib::rewrite::{back_out_commit, merge_commit_trees, rebase_commit}; +use jujutsu_lib::settings::UserSettings; +use jujutsu_lib::store::{StoreError, Timestamp, TreeValue}; +use jujutsu_lib::store_wrapper::StoreWrapper; +use jujutsu_lib::transaction::Transaction; +use jujutsu_lib::tree::Tree; +use jujutsu_lib::trees::Diff; +use jujutsu_lib::working_copy::{CheckoutStats, WorkingCopy}; +use jujutsu_lib::{conflicts, files, git, revset}; use pest::Parser; use self::chrono::{FixedOffset, TimeZone, Utc}; @@ -699,7 +699,7 @@ fn get_app<'a, 'b>() -> App<'a, 'b> { ) .subcommand(SubCommand::with_name("index").about("Show commit index stats")) .subcommand(SubCommand::with_name("reindex").about("Rebuild commit index")); - App::new("Jujube") + App::new("Jujutsu") .global_setting(clap::AppSettings::ColoredHelp) .setting(clap::AppSettings::SubcommandRequiredElseHelp) .version(crate_version!()) diff --git a/src/diff_edit.rs b/src/diff_edit.rs index c5f9d9015..cc9379691 100644 --- a/src/diff_edit.rs +++ b/src/diff_edit.rs @@ -16,13 +16,13 @@ use std::path::{Path, PathBuf}; use std::process::Command; use std::sync::Arc; -use jujube_lib::repo_path::{DirRepoPath, RepoPath}; -use jujube_lib::store::{StoreError, TreeId, TreeValue}; -use jujube_lib::store_wrapper::StoreWrapper; -use jujube_lib::tree::Tree; -use jujube_lib::tree_builder::TreeBuilder; -use jujube_lib::trees::merge_trees; -use jujube_lib::working_copy::{CheckoutError, TreeState}; +use jujutsu_lib::repo_path::{DirRepoPath, RepoPath}; +use jujutsu_lib::store::{StoreError, TreeId, TreeValue}; +use jujutsu_lib::store_wrapper::StoreWrapper; +use jujutsu_lib::tree::Tree; +use jujutsu_lib::tree_builder::TreeBuilder; +use jujutsu_lib::trees::merge_trees; +use jujutsu_lib::working_copy::{CheckoutError, TreeState}; use tempfile::tempdir; use thiserror::Error; @@ -58,7 +58,7 @@ fn add_to_tree( TreeValue::Conflict(conflict_id) => { let conflict = store.read_conflict(conflict_id)?; let materialized_value = - jujube_lib::conflicts::conflict_to_materialized_value(store, repo_path, &conflict); + jujutsu_lib::conflicts::conflict_to_materialized_value(store, repo_path, &conflict); tree_builder.set(repo_path.clone(), materialized_value); } _ => { diff --git a/src/main.rs b/src/main.rs index 6788d3684..3a0717c3b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -12,9 +12,9 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube::commands::dispatch; -use jujube::ui::Ui; -use jujube_lib::settings::UserSettings; +use jujutsu::commands::dispatch; +use jujutsu::ui::Ui; +use jujutsu_lib::settings::UserSettings; fn main() { // TODO: We need to do some argument parsing here, at least for things like diff --git a/src/styler.rs b/src/styler.rs index 175e1b3d8..76a0c2aea 100644 --- a/src/styler.rs +++ b/src/styler.rs @@ -16,7 +16,7 @@ use std::collections::HashMap; use std::io; use std::io::{Error, Read, Write}; -use jujube_lib::settings::UserSettings; +use jujutsu_lib::settings::UserSettings; // Lets the caller label strings and translates the labels to colors pub trait Styler: Write { diff --git a/src/template_parser.rs b/src/template_parser.rs index 6b727ddaf..9d31ce2f8 100644 --- a/src/template_parser.rs +++ b/src/template_parser.rs @@ -15,9 +15,9 @@ extern crate pest; use chrono::{FixedOffset, TimeZone, Utc}; -use jujube_lib::commit::Commit; -use jujube_lib::repo::RepoRef; -use jujube_lib::store::{CommitId, Signature}; +use jujutsu_lib::commit::Commit; +use jujutsu_lib::repo::RepoRef; +use jujutsu_lib::store::{CommitId, Signature}; use pest::iterators::{Pair, Pairs}; use pest::Parser; diff --git a/src/templater.rs b/src/templater.rs index 4e62c0fc5..859d4735c 100644 --- a/src/templater.rs +++ b/src/templater.rs @@ -16,9 +16,9 @@ use std::borrow::BorrowMut; use std::io; use std::ops::Add; -use jujube_lib::commit::Commit; -use jujube_lib::repo::RepoRef; -use jujube_lib::store::{CommitId, Signature}; +use jujutsu_lib::commit::Commit; +use jujutsu_lib::repo::RepoRef; +use jujutsu_lib::store::{CommitId, Signature}; use crate::styler::Styler; diff --git a/src/testutils.rs b/src/testutils.rs index db6a381be..c5d54621e 100644 --- a/src/testutils.rs +++ b/src/testutils.rs @@ -15,7 +15,7 @@ use std::io::Cursor; use std::path::{Path, PathBuf}; -use jujube_lib::testutils::{new_user_home, user_settings}; +use jujutsu_lib::testutils::{new_user_home, user_settings}; use crate::commands; use crate::ui::Ui; diff --git a/src/ui.rs b/src/ui.rs index 2a32034f7..c18fc2166 100644 --- a/src/ui.rs +++ b/src/ui.rs @@ -17,9 +17,9 @@ use std::path::{Path, PathBuf}; use std::sync::{Mutex, MutexGuard}; use std::{fmt, io}; -use jujube_lib::commit::Commit; -use jujube_lib::repo::RepoRef; -use jujube_lib::settings::UserSettings; +use jujutsu_lib::commit::Commit; +use jujutsu_lib::repo::RepoRef; +use jujutsu_lib::settings::UserSettings; use crate::styler::{ColorStyler, PlainTextStyler, Styler}; use crate::templater::TemplateFormatter; diff --git a/tests/smoke_test.rs b/tests/smoke_test.rs index a49abf359..97e8e3bde 100644 --- a/tests/smoke_test.rs +++ b/tests/smoke_test.rs @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube::testutils; +use jujutsu::testutils; use regex::Regex; #[test] diff --git a/tests/test_init_command.rs b/tests/test_init_command.rs index ec77cd251..60919b5fb 100644 --- a/tests/test_init_command.rs +++ b/tests/test_init_command.rs @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -use jujube::testutils; +use jujutsu::testutils; #[test] fn test_init_git_internal() {