Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions fixtures/fastas/multiple.fa
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
>1
GGGG
>2
CCCC
1 change: 1 addition & 0 deletions src/annotations/gff.rs
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ mod tests {
15,
25,
fasta_update_path.to_str().unwrap(),
false,
);

let temp_dir = tempdir().expect("Couldn't get handle to temp directory");
Expand Down
1 change: 1 addition & 0 deletions src/exports/fasta.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ mod tests {
2,
5,
fasta_update_path.to_str().unwrap(),
false,
);

let tmp_dir = tempfile::tempdir().unwrap().into_path();
Expand Down
4 changes: 4 additions & 0 deletions src/graph_operators.rs
Original file line number Diff line number Diff line change
Expand Up @@ -687,6 +687,7 @@ mod tests {
3,
5,
fasta_update_path.to_str().unwrap(),
false,
);

let _ = update_with_fasta(
Expand All @@ -699,6 +700,7 @@ mod tests {
15,
20,
fasta_update_path.to_str().unwrap(),
false,
);

let original_block_groups = Sample::get_block_groups(conn, collection, None);
Expand Down Expand Up @@ -802,6 +804,7 @@ mod tests {
3,
5,
fasta_update_path.to_str().unwrap(),
false,
);

let _ = update_with_fasta(
Expand All @@ -814,6 +817,7 @@ mod tests {
15,
20,
fasta_update_path.to_str().unwrap(),
false,
);

let original_block_groups = Sample::get_block_groups(conn, collection, None);
Expand Down
15 changes: 11 additions & 4 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,9 @@ enum Commands {
/// The end coordinate for the region to add the library to
#[arg(short, long)]
end: Option<i64>,
/// For fasta updates, do not update the sample's reference path if there is a single fasta entry
#[arg(long, action)]
no_reference_path_update: bool,
/// If a new entity is found, create it as a normal import
#[arg(long, action, alias = "cm")]
create_missing: bool,
Expand Down Expand Up @@ -690,6 +693,7 @@ fn main() {
region_name,
start,
end,
no_reference_path_update,
coordinate_frame,
create_missing,
gfa,
Expand Down Expand Up @@ -721,11 +725,14 @@ fn main() {
&operation_conn,
name,
sample.clone().as_deref(),
&new_sample.clone().unwrap(),
&region_name.clone().unwrap(),
start.unwrap(),
end.unwrap(),
&new_sample
.clone()
.expect("new-sample flag must be provided."),
&region_name.clone().expect("region-name must be provided."),
start.expect("start flag must be provided."),
end.expect("end flag must be provided."),
fasta_path,
*no_reference_path_update,
)
.unwrap();
} else if let Some(vcf_path) = vcf {
Expand Down
Loading