Skip to content

Commit 29d08fb

Browse files
committed
fix: style
1 parent 0fa70bd commit 29d08fb

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,6 @@ repos:
2222
name: rust-fmt
2323
description: Check if all files follow the rust-fmt style
2424
# https://github.com/pre-commit-ci/issues/issues/121
25-
entry: rustfmt --check --color always
25+
entry: cargo fmt -- --check --color always
2626
language: rust
2727
pass_filenames: false

src/lib.rs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
use std::path::Path;
2-
use pyo3::prelude::*;
3-
use infer::{get, Type, MatcherType, get_from_path};
1+
use infer::{get, get_from_path, MatcherType, Type};
42
use pyo3::create_exception;
53
use pyo3::exceptions::PyValueError;
6-
use pyo3::types::{PyString, PyBytes};
4+
use pyo3::prelude::*;
5+
use pyo3::types::{PyBytes, PyString};
6+
use std::path::Path;
77

88
create_exception!(_magic_rs, CantMatchTypeError, PyValueError, "Cant match type error");
99

@@ -55,7 +55,6 @@ impl PyMagic {
5555
}
5656
}
5757

58-
5958
#[pyfunction]
6059
#[pyo3(signature = (buf))]
6160
fn from_bytes(_py: Python, buf: &PyBytes) -> PyResult<PyMagic> {

0 commit comments

Comments
 (0)