display log files diffs
[?]
May 8, 2025, 9:34 AM
JE44NYHM4QORCRKOF33QM42EDT7SBCPTULWGT6IVDL3D5LUHQXLACDependencies
- [2]
6YZAVBWUInitial commit - [3]
IQDCHWCPload a pijul repo - [4]
SWWE2R6Mdisplay basic repo stuff - [5]
WT3GA27Padd cursor with selection - [6]
DVKSPF7Rtrack selected file path together with an index - [7]
EC3TVL4Xadd untracked files - [8]
KT5UYXGKfix selection after adding file, add changed file diffs - [9]
S2NVIFXRallow to enter record msg - [10]
W7IUT3ZVstart recording impl - [11]
YBJRDOTCmake all repo actions async - [12]
A5YBC77Vrecord! - [13]
D7A7MSIHallow to defer or abandon record, add buttons - [14]
4WO3ZJM2show untracked files' contents - [15]
W4LFX7IHgroup diffs by file name - [16]
AMPZ2BXKshow changed files diffs (only Edit atm) - [17]
NRCUG4R2load changed files src when selected - [18]
Y5ATDI2Hconvert changed file diffs and load src only if any needs it - [19]
MJDGPSHGWIP contents diff - [20]
ZVI4AWERwoot contents_diff - [21]
QMAUTRB6refactor diff - [22]
OQ6HSAWHshow record log - [23]
WI2BVQ6Jrm client lib crate - [24]
NWJD6VM6mv libflowers libflorescence - [25]
AHWWRC73navigate log entries - [26]
UJPRF6DAfix log changes selection - [27]
TEI5NQ3Sadd log files selection - [28]
DCSUCH6Radd undecoded diff view, improve decoded view style - [29]
UUB7SHLRmore re-use in diffs - [30]
PTFDJ567add untracked files encoding - [31]
V55EAIWQadd src file LRU cache - [32]
UCBNZULEmake changed files paths optional (no path for root) - [33]
UB2ITZJSrefresh changed files on FS changes
Change contents
- edit in crates/libflorescence/src/repo.rs at line 138
},GetLogFileDiff {id: LogFileId, - edit in crates/libflorescence/src/repo.rs at line 152
LogFileDiff {id: LogFileId,diffs: ChangedFile,}, - edit in crates/libflorescence/src/repo.rs at line 169
#[derive(Debug, Clone, Hash, PartialEq, Eq)]pub struct LogFileId {pub change_hash: pijul::Hash,pub path: String,} - edit in crates/libflorescence/src/repo.rs at line 247
}).await.unwrap();}MsgIn::GetLogFileDiff { id } => {let LogFileId { change_hash, path } = id.clone();let diffs: ChangedFile;(state, diffs) = spawn_blocking(move || {let change =state.repo.changes.get_change(&change_hash).unwrap();let mut changed_files =changed_files(&change, &state.repo.changes);let diffs = changed_files.remove(&path).unwrap();(state, diffs) - edit in crates/libflorescence/src/repo.rs at line 264
let _ = msg_out_tx.send(MsgOut::LogFileDiff { id, diffs }); - replacement in crates/libflorescence/src/repo.rs at line 750
let (_, (h, _mrk)) = pr.unwrap();let cid = pijul::GraphTxnT::get_internal(&txn, h).unwrap().unwrap();let (_, (hash, _mrk)) = pr.unwrap();let cid = pijul::GraphTxnT::get_internal(&txn, hash).unwrap().unwrap(); - replacement in crates/libflorescence/src/repo.rs at line 772
let entry = mk_log_entry(repo, pijul::Hash::from(h));let entry = mk_log_entry(repo, pijul::Hash::from(hash)); - replacement in crates/libflorescence/src/repo.rs at line 786
fn mk_log_entry(repo: &pijul::Repository, h: pijul::Hash) -> LogEntry {let header = repo.changes.get_header(&h.into()).unwrap();let files = repo.changes.get_changes(&h).unwrap();fn mk_log_entry(repo: &pijul::Repository, hash: pijul::Hash) -> LogEntry {let header = repo.changes.get_header(&hash).unwrap();let files = repo.changes.get_changes(&hash).unwrap(); - replacement in crates/libflorescence/src/repo.rs at line 795
hash: h,hash, - edit in crates/inflorescence/src/main.rs at line 208[13.163]→[3.1403:1405](∅→∅),[9.177]→[3.1403:1405](∅→∅),[5.652]→[3.1403:1405](∅→∅),[4.5100]→[3.1403:1405](∅→∅),[3.1403]→[3.1403:1405](∅→∅),[3.1405]→[2.2980:3039](∅→∅),[2.2980]→[2.2980:3039](∅→∅)
}fn theme(_state: &State) -> Theme {Theme::TokyoNight - replacement in crates/inflorescence/src/main.rs at line 288
let entry = repo.log.iter().nth(ix).unwrap();let entry = repo.log.get(ix).unwrap(); - edit in crates/inflorescence/src/main.rs at line 293
message: entry.message.clone(), - replacement in crates/inflorescence/src/main.rs at line 298
let log_file_selection = |log_entry: &repo::LogEntry,file_ix: usize,log_ix: usize,hash: pijul::Hash|-> cursor::Selection {let path = log_entry.file_paths.iter().nth(file_ix).unwrap().clone();let log_file_selection =|log_entry: &repo::LogEntry,file_ix: usize,hash: pijul::Hash|-> (cursor::LogChangeFileSelection, Task<Message>) {let path = log_entry.file_paths.get(file_ix).unwrap().clone();// Request to get the difflet id = repo::LogFileId {change_hash: hash,path: path.clone(),};let task =Task::done(Message::ToRepo(repo::MsgIn::GetLogFileDiff { id })); - replacement in crates/inflorescence/src/main.rs at line 313
cursor::Selection::LogChange {ix: log_ix,hash,file: Some(cursor::LogChangeFileSelection { ix: file_ix, path }),}};(cursor::LogChangeFileSelection {ix: file_ix,path,diff: None,},task,)}; - replacement in crates/inflorescence/src/main.rs at line 343
state.cursor.selection = match state.cursor.selection.as_ref() {let (selection, task) = match state.cursor.selection.take() { - replacement in crates/inflorescence/src/main.rs at line 349
let new_selection =let selection = - replacement in crates/inflorescence/src/main.rs at line 351
== *ix== ix - replacement in crates/inflorescence/src/main.rs at line 382
Some(new_selection)(Some(selection), Task::none()) - replacement in crates/inflorescence/src/main.rs at line 389
let new_selection = if repo.changed_files.len().saturating_sub(1)== *ix{if !repo.log.is_empty() {let ix = 0;log_selection(repo, ix)} else if !repo.untracked_files.is_empty() {let ix = 0;untracked_file_selection(repo,ix,&mut state.diffs_cache,&state.src_file_load_tx,)let selection =if repo.changed_files.len().saturating_sub(1) == ix{if !repo.log.is_empty() {let ix = 0;log_selection(repo, ix)} else if !repo.untracked_files.is_empty() {let ix = 0;untracked_file_selection(repo,ix,&mut state.diffs_cache,&state.src_file_load_tx,)} else {let ix = 0;changed_file_selection(repo,ix,&mut state.diffs_cache,&state.src_file_load_tx,)} - replacement in crates/inflorescence/src/main.rs at line 413
let ix = 0;let ix = ix + 1; - replacement in crates/inflorescence/src/main.rs at line 420
}} else {let ix = ix + 1;changed_file_selection(repo,ix,&mut state.diffs_cache,&state.src_file_load_tx,)};Some(new_selection)};(Some(selection), Task::none()) - edit in crates/inflorescence/src/main.rs at line 426
message, - replacement in crates/inflorescence/src/main.rs at line 429
let new_selection = match file {let (selection, task) = match file { - edit in crates/inflorescence/src/main.rs at line 433
diff: _, - replacement in crates/inflorescence/src/main.rs at line 435
let log_entry =repo.log.iter().nth(*log_ix).unwrap();let log_entry = repo.log.get(log_ix).unwrap(); - replacement in crates/inflorescence/src/main.rs at line 441
== *file_ix== file_ix - edit in crates/inflorescence/src/main.rs at line 447
let (file, task) = log_file_selection(log_entry, file_ix, hash,); - replacement in crates/inflorescence/src/main.rs at line 452
log_file_selection(log_entry, file_ix, *log_ix, *hash,(cursor::Selection::LogChange {ix: log_ix,hash,message,file: Some(file),},task, - replacement in crates/inflorescence/src/main.rs at line 463[25.4714]→[27.1553:1634](∅→∅),[27.1634]→[25.4791:4865](∅→∅),[25.4791]→[25.4791:4865](∅→∅),[25.4865]→[20.6476:6528](∅→∅),[20.6476]→[20.6476:6528](∅→∅),[20.6528]→[25.4866:4932](∅→∅),[25.4932]→[20.6592:6869](∅→∅),[20.6592]→[20.6592:6869](∅→∅),[20.6869]→[25.4933:5012](∅→∅),[25.5012]→[20.6914:6966](∅→∅),[20.6914]→[20.6914:6966](∅→∅),[20.6966]→[25.5013:5077](∅→∅),[25.5077]→[20.7032:7309](∅→∅),[20.7032]→[20.7032:7309](∅→∅)
if repo.log.len().saturating_sub(1) == *log_ix {if !repo.untracked_files.is_empty() {let ix = 0;untracked_file_selection(repo,ix,&mut state.diffs_cache,&state.src_file_load_tx,)} else if !repo.changed_files.is_empty() {let ix = 0;changed_file_selection(repo,ix,&mut state.diffs_cache,&state.src_file_load_tx,)let selection =if repo.log.len().saturating_sub(1)== log_ix{if !repo.untracked_files.is_empty() {let ix = 0;untracked_file_selection(repo,ix,&mut state.diffs_cache,&state.src_file_load_tx,)} else if !repo.changed_files.is_empty(){let ix = 0;changed_file_selection(repo,ix,&mut state.diffs_cache,&state.src_file_load_tx,)} else {let ix = 0;log_selection(repo, ix)} - replacement in crates/inflorescence/src/main.rs at line 489
let ix = 0;let ix = log_ix + 1; - replacement in crates/inflorescence/src/main.rs at line 491[25.5239]→[20.7309:7347](∅→∅),[20.7309]→[20.7309:7347](∅→∅),[14.3591]→[11.7632:7673](∅→∅),[20.7347]→[11.7632:7673](∅→∅),[11.7632]→[11.7632:7673](∅→∅),[11.7673]→[27.1635:1692](∅→∅),[27.1692]→[25.5240:5300](∅→∅),[20.7401]→[25.5240:5300](∅→∅),[17.1078]→[11.7790:7824](∅→∅),[25.5300]→[11.7790:7824](∅→∅),[20.8242]→[11.7790:7824](∅→∅),[11.7790]→[11.7790:7824](∅→∅)
}} else {let ix = log_ix + 1;log_selection(repo, ix)}};(selection, Task::none()) - replacement in crates/inflorescence/src/main.rs at line 495
Some(new_selection)(Some(selection), task) - replacement in crates/inflorescence/src/main.rs at line 498
if !repo.untracked_files.is_empty() {let selection = if !repo.untracked_files.is_empty() { - replacement in crates/inflorescence/src/main.rs at line 519[6.573]→[5.1547:1573](∅→∅),[14.4515]→[5.1547:1573](∅→∅),[7.5553]→[5.1547:1573](∅→∅),[8.5826]→[5.1547:1573](∅→∅),[25.6251]→[5.1547:1573](∅→∅),[11.8991]→[5.1547:1573](∅→∅),[5.1547]→[5.1547:1573](∅→∅)
}};(selection, Task::none()) - edit in crates/inflorescence/src/main.rs at line 523
state.cursor.selection = selection;task} else {Task::none() - edit in crates/inflorescence/src/main.rs at line 528
Task::none() - replacement in crates/inflorescence/src/main.rs at line 531
state.cursor.selection = match state.cursor.selection.as_ref() {let (selection, task) = match state.cursor.selection.take() { - replacement in crates/inflorescence/src/main.rs at line 537
let new_selection = if 0 == *ix {let selection = if 0 == ix { - replacement in crates/inflorescence/src/main.rs at line 567
Some(new_selection)(Some(selection), Task::none()) - replacement in crates/inflorescence/src/main.rs at line 574
let new_selection = if 0 == *ix {let selection = if 0 == ix { - replacement in crates/inflorescence/src/main.rs at line 604
Some(new_selection)(Some(selection), Task::none()) - edit in crates/inflorescence/src/main.rs at line 609
message, - replacement in crates/inflorescence/src/main.rs at line 612
let new_selection = match file {let (selection, task) = match file { - edit in crates/inflorescence/src/main.rs at line 616
diff: _, - replacement in crates/inflorescence/src/main.rs at line 618
let log_entry =repo.log.iter().nth(*log_ix).unwrap();let log_entry = repo.log.get(log_ix).unwrap(); - replacement in crates/inflorescence/src/main.rs at line 620
let file_ix = if 0 == *file_ix {let file_ix = if 0 == file_ix { - replacement in crates/inflorescence/src/main.rs at line 626
log_file_selection(log_entry, file_ix, *log_ix, *hash,let (file, task) = log_file_selection(log_entry, file_ix, hash,);(cursor::Selection::LogChange {ix: log_ix,hash,message,file: Some(file),},task, - replacement in crates/inflorescence/src/main.rs at line 640
if 0 == *log_ix {let selection = if 0 == log_ix { - replacement in crates/inflorescence/src/main.rs at line 664
}};(selection, Task::none()) - replacement in crates/inflorescence/src/main.rs at line 668
Some(new_selection)(Some(selection), task) - replacement in crates/inflorescence/src/main.rs at line 671
if !repo.log.is_empty() {let selection = if !repo.log.is_empty() { - replacement in crates/inflorescence/src/main.rs at line 692[6.1020]→[5.2471:2497](∅→∅),[17.3104]→[5.2471:2497](∅→∅),[8.6340]→[5.2471:2497](∅→∅),[7.7355]→[5.2471:2497](∅→∅),[25.9614]→[5.2471:2497](∅→∅),[11.11190]→[5.2471:2497](∅→∅),[5.2471]→[5.2471:2497](∅→∅)
}};(selection, Task::none()) - edit in crates/inflorescence/src/main.rs at line 696
state.cursor.selection = selection;task} else {Task::none() - edit in crates/inflorescence/src/main.rs at line 702
Task::none() - replacement in crates/inflorescence/src/main.rs at line 705
// The outter `Option` is for whether the selection should change, the inner is what it should change to if solet new_selection: Option<Option<cursor::Selection>> =match state.cursor.selection.as_ref() {Some(cursor::Selection::LogChange {ix,hash,file,}) => Some(Some(if file.is_none() {let log_entry = repo.log.iter().nth(*ix).unwrap();let file = if let Some(path) =let (selection, task): (Option<cursor::Selection>,Task<Message>,) = match state.cursor.selection.take() {Some(cursor::Selection::LogChange {ix,hash,message,file,}) => {if file.is_none() {let log_entry = repo.log.get(ix).unwrap();let (file, task) = if let Some(path) = - replacement in crates/inflorescence/src/main.rs at line 720
Some(cursor::LogChangeFileSelection {ix: 0,// Request to get the difflet id = repo::LogFileId {change_hash: hash, - replacement in crates/inflorescence/src/main.rs at line 724
})};let task = Task::done(Message::ToRepo(repo::MsgIn::GetLogFileDiff { id },));(Some(cursor::LogChangeFileSelection {ix: 0,path: path.clone(),diff: None,}),task,) - replacement in crates/inflorescence/src/main.rs at line 738
None(None, Task::none()) - replacement in crates/inflorescence/src/main.rs at line 740
cursor::Selection::LogChange {ix: *ix,hash: *hash,file,}(Some(cursor::Selection::LogChange {ix,hash,message,file,}),task,) - replacement in crates/inflorescence/src/main.rs at line 750
cursor::Selection::LogChange {ix: *ix,hash: *hash,file: None,}})),Some(cursor::Selection::UntrackedFile { .. })| Some(cursor::Selection::ChangedFile { .. })| None => None,};if let Some(selection) = new_selection {state.cursor.selection = selection;}(Some(cursor::Selection::LogChange {ix,hash,message,file: None,}),Task::none(),)}}selection @ (Some(cursor::Selection::UntrackedFile {..})| Some(cursor::Selection::ChangedFile {..})| None) => (selection, Task::none()),};state.cursor.selection = selection;task} else {Task::none() - edit in crates/inflorescence/src/main.rs at line 774
Task::none() - replacement in crates/inflorescence/src/main.rs at line 776
let selection = match select {let (selection, task) = match select { - replacement in crates/inflorescence/src/main.rs at line 786[17.3308]→[27.4745:4805](∅→∅),[27.4805]→[20.9822:9880](∅→∅),[20.9822]→[20.9822:9880](∅→∅),[20.9880]→[21.458:513](∅→∅),[21.513]→[27.4806:4829](∅→∅)
Some(cursor::Selection::UntrackedFile {ix,path,diffs: diff::State::default(),})(Some(cursor::Selection::UntrackedFile {ix,path,diffs: diff::State::default(),}),Task::none(),) - replacement in crates/inflorescence/src/main.rs at line 812[20.10739]→[27.4830:4888](∅→∅),[27.4888]→[20.10792:10850](∅→∅),[20.10792]→[20.10792:10850](∅→∅),[20.10850]→[21.514:569](∅→∅),[21.569]→[27.4889:4912](∅→∅)
Some(cursor::Selection::ChangedFile {ix,path,diffs: diff::State::default(),})(Some(cursor::Selection::ChangedFile {ix,path,diffs: diff::State::default(),}),Task::none(),) - replacement in crates/inflorescence/src/main.rs at line 821
cursor::Select::LogChange { ix, hash } => {cursor::Select::LogChange { ix, hash, message } => ( - edit in crates/inflorescence/src/main.rs at line 825
message, - replacement in crates/inflorescence/src/main.rs at line 827
})}cursor::Select::LogChangeFile { ix, path } => {let file = cursor::LogChangeFileSelection { ix, path };if let Some(cursor::Selection::LogChange {ix,hash,file: _,}) = state.cursor.selection{}),Task::none(),),cursor::Select::LogChangeFile { ix: file_ix, path } => {match state.cursor.selection.take() { - replacement in crates/inflorescence/src/main.rs at line 833
ix,ix: change_ix, - replacement in crates/inflorescence/src/main.rs at line 835
file: Some(file),})} else {Nonemessage,file: _,}) => {// Request to get the difflet id = repo::LogFileId {change_hash: hash,path: path.clone(),};let task = Task::done(Message::ToRepo(repo::MsgIn::GetLogFileDiff { id },));let file = cursor::LogChangeFileSelection {ix: file_ix,path,diff: None,};(Some(cursor::Selection::LogChange {ix: change_ix,hash,message,file: Some(file),}),task,)}selection => (selection, Task::none()), - replacement in crates/inflorescence/src/main.rs at line 867
Task::none()task - replacement in crates/inflorescence/src/main.rs at line 1161
if let Some(selection) = state.cursor.selection.as_ref() {if let Some(selection) = state.cursor.selection.take() { - replacement in crates/inflorescence/src/main.rs at line 1164
state.cursor.selection = match selection {let (selection, task) = match selection { - replacement in crates/inflorescence/src/main.rs at line 1179
repo.untracked_fileslet selection = repo.untracked_files - replacement in crates/inflorescence/src/main.rs at line 1183
.find(|(_ix, file_path)| *file_path == path).map(|(ix, path)| {.find(|(_ix, file_path)| *file_path == &path).map(|(ix, _path)| { - replacement in crates/inflorescence/src/main.rs at line 1187
path: path.clone(),path, - replacement in crates/inflorescence/src/main.rs at line 1190
})});(selection, Task::none()) - replacement in crates/inflorescence/src/main.rs at line 1198
if let Some(diffs) = repo.changed_files.get(path) {if let Some(diffs) = repo.changed_files.get(&path) { - replacement in crates/inflorescence/src/main.rs at line 1211
repo.changed_fileslet selection = repo.changed_files - replacement in crates/inflorescence/src/main.rs at line 1216
file_path == &path*file_path == &path - replacement in crates/inflorescence/src/main.rs at line 1224
})});(selection, Task::none()) - replacement in crates/inflorescence/src/main.rs at line 1227
cursor::Selection::LogChange { ix: _, hash, file } => repo.log.iter().enumerate().find(|(_ix, entry)| &entry.hash == hash).map(|(ix, entry)| {let file = file.as_ref().and_then(|file| {cursor::Selection::LogChange {ix: _,hash,message,file,} => {let (selection, task) = match repo.log.iter().enumerate().find(|(_ix, entry)| entry.hash == hash){Some((ix, entry)) => {let file_and_task = file.and_then(|file| { - replacement in crates/inflorescence/src/main.rs at line 1247
cursor::LogChangeFileSelection {// Request to get the difflet id = repo::LogFileId {change_hash: hash,path: path.clone(),};let task = Task::done(Message::ToRepo(repo::MsgIn::GetLogFileDiff { id }));(cursor::LogChangeFileSelection { - replacement in crates/inflorescence/src/main.rs at line 1257
}diff: None,}, task) - replacement in crates/inflorescence/src/main.rs at line 1261
cursor::Selection::LogChange {ix,hash: entry.hash,file,let (file, task) = match file_and_task {Some((file, task)) => (Some(file), task),None => (None, Task::none()),};(Some(cursor::Selection::LogChange {ix,hash: entry.hash,message,file,}),task,) - replacement in crates/inflorescence/src/main.rs at line 1275
}),None => (None, Task::none()),};(selection, task)} - edit in crates/inflorescence/src/main.rs at line 1281
state.cursor.selection = selection;task} else {Task::none() - replacement in crates/inflorescence/src/main.rs at line 1287
}repo::MsgOut::LogFileDiff { id, diffs } => {if let Some(cursor::Selection::LogChange {ix: _,hash: selected_hash,message: _,file:Some(cursor::LogChangeFileSelection {ix: _,path: selected_path,diff,}),}) = state.cursor.selection.as_mut(){let repo::LogFileId { change_hash, path } = id;if *selected_hash == change_hash && *selected_path == path {// NOTE: using unknown encoding as we don't yet have the// filelet file = diff::init_file(diff::FileContent::UnknownEncoding,Some(&diffs),);*diff = Some((diff::State::default(), file));}} - edit in crates/inflorescence/src/main.rs at line 1410
}fn theme(_state: &State) -> Theme {Theme::TokyoNight - replacement in crates/inflorescence/src/main.rs at line 1427
let untracked_files =el(column(repo.untracked_files.iter().enumerate().map(let untracked_files = || {el(column(repo.untracked_files.iter().enumerate().map( - replacement in crates/inflorescence/src/main.rs at line 1441
)));)))}; - replacement in crates/inflorescence/src/main.rs at line 1444
let changed_files =el(column(repo.changed_files.iter().enumerate().map(let changed_files = || {el(column(repo.changed_files.iter().enumerate().map( - replacement in crates/inflorescence/src/main.rs at line 1459
)));)))}; - replacement in crates/inflorescence/src/main.rs at line 1462
let log = el(column(repo.log.iter().enumerate().map(let log = || {el(column(repo.log.iter().enumerate().map( - replacement in crates/inflorescence/src/main.rs at line 1469
let mut short_hash = hash.to_base32();short_hash.truncate(8);let short_hash = display_short_hash(hash); - replacement in crates/inflorescence/src/main.rs at line 1476
cursor::Select::LogChange { ix, hash: *hash },cursor::Select::LogChange { ix, hash: *hash, message: message.clone() }, - replacement in crates/inflorescence/src/main.rs at line 1483
)));)))}; - replacement in crates/inflorescence/src/main.rs at line 1523
None | Some(FileDiff::Loading) => el(text("loading...")),None | Some(FileDiff::Loading) => {el(text("Loading diff..."))} - replacement in crates/inflorescence/src/main.rs at line 1528
view_diff_header(format!("{path} diff:")),view_diff_header(format!("Untracked file {path} contents:")), - replacement in crates/inflorescence/src/main.rs at line 1532
]))]).spacing(SPACING)) - replacement in crates/inflorescence/src/main.rs at line 1553
None | Some(FileDiff::Loading) => el(text("loading...")),None | Some(FileDiff::Loading) => {el(text("Loading diff..."))} - replacement in crates/inflorescence/src/main.rs at line 1558
view_diff_header(format!("{path} diff:")),view_diff_header(format!("Changed file {path} diff:")), - replacement in crates/inflorescence/src/main.rs at line 1560
]))]).spacing(SPACING)) - replacement in crates/inflorescence/src/main.rs at line 1563
Some(cursor::Selection::LogChange { ix, hash, file }) => {let entry =state.repo.as_ref().unwrap().log.iter().nth(*ix).unwrap();Some(cursor::Selection::LogChange {ix,hash,message,file,}) => {let entry = state.repo.as_ref().unwrap().log.get(*ix).unwrap(); - replacement in crates/inflorescence/src/main.rs at line 1571
let mut short_hash = hash.to_base32();short_hash.truncate(8);let short_hash = display_short_hash(hash); - replacement in crates/inflorescence/src/main.rs at line 1574
let is_selected = matches!(file, Some(cursor::LogChangeFileSelection{ix: _, path: selected_path}) if selected_path == path);let is_selected = matches!(file, Some(cursor::LogChangeFileSelection{ path: selected_path, .. }) if selected_path == path); - replacement in crates/inflorescence/src/main.rs at line 1580
view_diff_header(format!("{} changed files:", short_hash)),view_diff_header(format!("{short_hash} message:")),el(text(message)),view_diff_header("Changed files:".to_string()), - replacement in crates/inflorescence/src/main.rs at line 1584
]))]).spacing(SPACING)) - replacement in crates/inflorescence/src/main.rs at line 1590
el(row([el(column([let left_view = match state.cursor.selection.as_ref() {Some(cursor::Selection::LogChange {ix: _,hash,message: _,file: Some(cursor::LogChangeFileSelection { ix: _, path, diff }),}) => el(column([view_diff_header(format!("{path} changes in {}:",display_short_hash(hash))),match diff {Some((state, file)) => {diff::view(state, file).map(|action| todo!())}None => el(text("Loading diff..")),},]).width(Length::FillPortion(1)).spacing(SPACING)),Some(cursor::Selection::UntrackedFile { .. })| Some(cursor::Selection::ChangedFile { .. })| Some(cursor::Selection::LogChange { .. })| None => el(column([ - replacement in crates/inflorescence/src/main.rs at line 1615
el(column([el(text("Untracked files:")), untracked_files])),el(column([el(text("Changed files:")), changed_files])),el(column([el(text("Recent changes:")), log])),el(column([el(text("Untracked files:")), untracked_files()])),el(column([el(text("Changed files:")), changed_files()])),el(column([el(text("Recent changes:")), log()])), - replacement in crates/inflorescence/src/main.rs at line 1621
el(column([record_msg_editor, selection_details]).width(Length::FillPortion(1))),]).spacing(SPACING))};let right_view = el(column([record_msg_editor, selection_details]).width(Length::FillPortion(1)));el(row([left_view, right_view]).spacing(SPACING)) - edit in crates/inflorescence/src/main.rs at line 1667
}fn display_short_hash(hash: &pijul::Hash) -> String {let mut short_hash = hash.to_base32();short_hash.truncate(8);short_hash - replacement in crates/inflorescence/src/diff.rs at line 7
use iced::{Background, Color, Element, Font, Length};use iced::{alignment, Background, Color, Element, Font, Length}; - replacement in crates/inflorescence/src/diff.rs at line 479
el(column(diffs))el(column(diffs).spacing(10)) - replacement in crates/inflorescence/src/diff.rs at line 609
text(txt).font(Font::MONOSPACE)text(txt).font(Font::MONOSPACE).wrapping(text::Wrapping::WordOrGlyph).align_y(alignment::Vertical::Top) - replacement in crates/inflorescence/src/diff.rs at line 617[28.6509]→[28.6509:6567](∅→∅),[28.6567]→[29.2836:2898](∅→∅),[29.2898]→[28.6629:6789](∅→∅),[28.6629]→[28.6629:6789](∅→∅)
let txt = format!("{:width$} ", num, width = digits);mono_text(txt).font(Font::MONOSPACE).style(move |theme| {let palette = theme.extended_palette();text::Style {color: Some(palette.background.base.text.scale_alpha(0.61)),}})let txt = format!("{num:digits$} ");mono_text(txt).font(Font::MONOSPACE).style(move |theme| {let palette = theme.extended_palette();text::Style {color: Some(palette.background.base.text.scale_alpha(0.61)),}}).align_y(alignment::Vertical::Top) - edit in crates/inflorescence/src/cursor.rs at line 25
message: String, - edit in crates/inflorescence/src/cursor.rs at line 34
/// Loaded asyncpub diff: Option<(diff::State, diff::File)>, - replacement in crates/inflorescence/src/cursor.rs at line 40[20.19157]→[7.1599:1646](∅→∅),[5.158]→[7.1599:1646](∅→∅),[7.1646]→[15.3146:3191](∅→∅),[15.3191]→[26.748:796](∅→∅),[26.796]→[27.6251:6298](∅→∅)
UntrackedFile { ix: usize, path: String },ChangedFile { ix: usize, path: String },LogChange { ix: usize, hash: pijul::Hash },LogChangeFile { ix: usize, path: String },UntrackedFile {ix: usize,path: String,},ChangedFile {ix: usize,path: String,},LogChange {ix: usize,hash: pijul::Hash,message: String,},LogChangeFile {ix: usize,path: String,},