Skip to content

Commit

Permalink
Merge pull request #69 from ghuls/fix_specifying_start_coordinate
Browse files Browse the repository at this point in the history
Fix specifying start coordinate of bigbedtobed and bigwigtobedgraph.
  • Loading branch information
jackh726 authored Jan 8, 2025
2 parents 0ea12f5 + 519e7f0 commit 992e052
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bigtools/src/utils/cli/bigbedtobed.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ pub fn bigbedtobed(args: BigBedToBedArgs) -> Result<(), Box<dyn Error>> {
let bigbed = BigBedRead::open_file(&bigbedpath)?;
let bed = File::create(bedpath)?;

if args.start.is_some() || args.end.is_some() & args.chrom.is_none() {
if (args.start.is_some() || args.end.is_some()) && args.chrom.is_none() {
eprintln!("Cannot specify --start or --end without specifying --chrom.");
return Ok(());
}
Expand Down
2 changes: 1 addition & 1 deletion bigtools/src/utils/cli/bigwigtobedgraph.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ pub fn bigwigtobedgraph(args: BigWigToBedGraphArgs) -> Result<(), Box<dyn Error>
let bigwig = BigWigRead::open_file(&bigwigpath)?;
let bedgraph = File::create(bedgraphpath)?;

if args.start.is_some() || args.end.is_some() & args.chrom.is_none() {
if (args.start.is_some() || args.end.is_some()) && args.chrom.is_none() {
eprintln!("Cannot specify --start or --end without specifying --chrom.");
return Ok(());
}
Expand Down

0 comments on commit 992e052

Please sign in to comment.