pub const JJ_COMMAND: &str = "jj";
pub mod commands {
pub const LOG: &str = "log";
pub const STATUS: &str = "status";
pub const SHOW: &str = "show";
pub const DESCRIBE: &str = "describe";
pub const NEW: &str = "new";
pub const EDIT: &str = "edit";
pub const COMMIT: &str = "commit";
pub const UNDO: &str = "undo";
pub const SQUASH: &str = "squash";
pub const ABANDON: &str = "abandon";
pub const SPLIT: &str = "split";
pub const OP: &str = "op";
pub const OP_LOG: &str = "log";
pub const OP_RESTORE: &str = "restore";
pub const BOOKMARK: &str = "bookmark";
pub const BOOKMARK_CREATE: &str = "create";
pub const BOOKMARK_SET: &str = "set";
pub const BOOKMARK_DELETE: &str = "delete";
pub const BOOKMARK_LIST: &str = "list";
pub const BOOKMARK_TRACK: &str = "track";
pub const BOOKMARK_UNTRACK: &str = "untrack";
pub const BOOKMARK_RENAME: &str = "rename";
pub const BOOKMARK_FORGET: &str = "forget";
pub const BOOKMARK_MOVE: &str = "move";
pub const NEXT: &str = "next";
pub const PREV: &str = "prev";
pub const REBASE: &str = "rebase";
pub const ABSORB: &str = "absorb";
pub const FILE: &str = "file";
pub const FILE_ANNOTATE: &str = "annotate";
pub const RESOLVE: &str = "resolve";
pub const GIT: &str = "git";
pub const GIT_FETCH: &str = "fetch";
pub const GIT_PUSH: &str = "push";
pub const DUPLICATE: &str = "duplicate";
pub const DIFFEDIT: &str = "diffedit";
pub const RESTORE: &str = "restore";
pub const EVOLOG: &str = "evolog";
pub const DIFF: &str = "diff";
pub const REVERT: &str = "revert";
pub const SIMPLIFY_PARENTS: &str = "simplify-parents";
pub const PARALLELIZE: &str = "parallelize";
pub const FIX: &str = "fix";
pub const GIT_REMOTE: &str = "remote";
pub const GIT_REMOTE_LIST: &str = "list";
pub const TAG: &str = "tag";
pub const TAG_LIST: &str = "list";
pub const TAG_SET: &str = "set";
pub const TAG_DELETE: &str = "delete";
}
pub mod resolve_flags {
pub const LIST: &str = "--list";
pub const TOOL: &str = "--tool";
}
pub mod flags {
pub const NO_COLOR: &str = "--color=never";
pub const NO_GRAPH: &str = "--no-graph";
pub const TEMPLATE: &str = "-T";
pub const REVISION: &str = "-r";
pub const REPO_PATH: &str = "-R";
pub const BOOKMARK_FLAG: &str = "--bookmark";
pub const ALLOW_NEW: &str = "--allow-new";
pub const ALL_REMOTES: &str = "--all-remotes";
pub const NAMED: &str = "--named";
pub const SOURCE: &str = "-s";
pub const INSERT_AFTER: &str = "-A";
pub const INSERT_BEFORE: &str = "-B";
pub const DRY_RUN: &str = "--dry-run";
pub const FROM: &str = "--from";
pub const TO: &str = "--to";
pub const EDIT_FLAG: &str = "--edit";
pub const EDITOR_FLAG: &str = "--editor";
pub const LIMIT: &str = "--limit";
pub const REVERSED: &str = "--reversed";
pub const CHANGE: &str = "--change";
pub const REMOTE: &str = "--remote";
pub const ALLOW_BACKWARDS: &str = "--allow-backwards";
pub const ALL: &str = "--all";
pub const TRACKED: &str = "--tracked";
pub const DELETED: &str = "--deleted";
pub const ONTO: &str = "--onto";
pub const REVISIONS: &str = "--revisions";
pub const GIT_FORMAT: &str = "--git";
pub const STAT: &str = "--stat";
pub const ALLOW_PRIVATE: &str = "--allow-private";
pub const ALLOW_EMPTY_DESC: &str = "--allow-empty-description";
pub const BRANCH: &str = "--branch";
pub const BRANCH_SHORT: &str = "-b";
pub const SKIP_EMPTIED: &str = "--skip-emptied";
pub const SIMPLIFY_PARENTS: &str = "--simplify-parents";
}
pub const DEFAULT_LOG_LIMIT: &str = "200";
pub mod special {
pub const ROOT_CHANGE_ID: &str = "zzzzzzzz";
}
pub mod errors {
pub const NOT_A_REPO: &str = "There is no jj repo";
}
pub use special::ROOT_CHANGE_ID;
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn test_root_change_id_is_all_z() {
assert!(ROOT_CHANGE_ID.chars().all(|c| c == 'z'));
}
#[test]
fn test_root_change_id_length() {
assert_eq!(ROOT_CHANGE_ID.len(), 8);
}
#[test]
fn test_jj_command_name() {
assert_eq!(JJ_COMMAND, "jj");
}
#[test]
fn test_no_color_flag_format() {
assert!(flags::NO_COLOR.starts_with("--color="));
}
}