Skip to content

Commit

Permalink
Add some feature
Browse files Browse the repository at this point in the history
  • Loading branch information
Peter554 committed Jan 5, 2025
1 parent 32f8a6a commit f41a63d
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
4 changes: 4 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,7 @@ lazy_static = "1.5.0"
[dev-dependencies]
parameterized = "2.0.0"
pretty_assertions = "1.4.1"

[features]
default = []
somefeature = []
4 changes: 2 additions & 2 deletions Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ version: '3'
tasks:
test:
cmds:
- cargo test
- cargo test --all-features

clippy.check:
cmds:
- cargo clippy --all-targets -- -D warnings
- cargo clippy --all-features --all-targets -- -D warnings

clippy.fix:
cmds:
Expand Down
4 changes: 4 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,7 @@ pub mod prelude {
pub use crate::IntoPypath;
pub use crate::PackageItemIterator;
}

/// Some feature
#[cfg(feature = "somefeature")]
pub mod somefeature;
2 changes: 2 additions & 0 deletions src/somefeature.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/// Foo
pub fn foo() {}

0 comments on commit f41a63d

Please sign in to comment.