mirror of
https://github.com/FliegendeWurst/ripgrep-all.git
synced 2024-11-08 14:00:37 +00:00
Run clippy
This commit is contained in:
parent
fdd4efe12e
commit
ab500733aa
@ -134,7 +134,7 @@ impl WritingFileAdapter for FFmpegAdapter {
|
||||
return Err(format_err!("ffprobe failed: {:?}", exit));
|
||||
}
|
||||
}
|
||||
if subtitle_streams.len() > 0 {
|
||||
if !subtitle_streams.is_empty() {
|
||||
for probe_stream in subtitle_streams.iter() {
|
||||
// extract subtitles
|
||||
let mut cmd = Command::new("ffmpeg");
|
||||
@ -143,7 +143,7 @@ impl WritingFileAdapter for FFmpegAdapter {
|
||||
.arg("-i")
|
||||
.arg(&inp_fname)
|
||||
.arg("-map")
|
||||
.arg(format!("0:{}", probe_stream.index.to_string())) // 0 for first input
|
||||
.arg(format!("0:{}", probe_stream.index)) // 0 for first input
|
||||
.arg("-f")
|
||||
.arg("webvtt")
|
||||
.arg("-");
|
||||
|
@ -138,7 +138,7 @@ mod test {
|
||||
|
||||
#[tokio::test]
|
||||
async fn simple() -> Result<()> {
|
||||
let adapter: Box<dyn FileAdapter> = Box::new(SqliteAdapter::default());
|
||||
let adapter: Box<dyn FileAdapter> = Box::<SqliteAdapter>::default();
|
||||
let fname = test_data_dir().join("hello.sqlite3");
|
||||
let (a, d) = simple_fs_adapt_info(&fname).await?;
|
||||
let res = adapter.adapt(a, &d).await?;
|
||||
|
@ -181,7 +181,7 @@ mod test {
|
||||
#[tokio::test]
|
||||
async fn test_read_write() -> anyhow::Result<()> {
|
||||
let path = tempfile::tempdir()?;
|
||||
let db = open_cache_db(&path.path().join("foo.sqlite3")).await?;
|
||||
let _db = open_cache_db(&path.path().join("foo.sqlite3")).await?;
|
||||
// db.set();
|
||||
Ok(())
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user