Skip to content

Commit

Permalink
Improve docs.rs output of icrate
Browse files Browse the repository at this point in the history
  • Loading branch information
madsmtm committed Dec 8, 2022
1 parent 47cd390 commit 1417dd6
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ jobs:
# Use --no-fail-fast, except with dinghy
TESTARGS: ${{ matrix.dinghy && ' ' || '--no-fail-fast' }} ${{ matrix.test-args }}
SOME_FEATURES: ${{ matrix.features || 'malloc,block,exception,Foundation' }}
FEATURES: ${{ matrix.features || 'malloc,block,exception,Foundation,catch-all,verify,uuid' }}
FEATURES: ${{ matrix.features || 'malloc,block,exception,unstable-all-frameworks,catch-all,verify,uuid' }}
UNSTABLE_FEATURES: ${{ matrix.unstable-features || 'unstable-autoreleasesafe,unstable-c-unwind' }}
CMD: cargo

Expand Down
7 changes: 4 additions & 3 deletions crates/icrate/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ uuid = { version = "1.1.2", optional = true, default-features = false }

[package.metadata.docs.rs]
default-target = "x86_64-apple-darwin"
all-features = true
features = ["block", "objective-c", "uuid", "unstable-all-frameworks", "unstable-docsrs"]

targets = [
# MacOS
Expand Down Expand Up @@ -81,7 +81,7 @@ gnustep-2-1 = ["gnustep-2-0", "objc2?/gnustep-2-1", "block2?/gnustep-2-1"]
objective-c = ["objc2"]

# Expose features that requires creating blocks.
blocks = ["objc2?/block", "block2"]
block = ["objc2?/block", "block2"]

# For better documentation on docs.rs
unstable-docsrs = []
Expand All @@ -91,4 +91,5 @@ unstable-docsrs = []
AppKit = ["Foundation", "CoreData"]
AuthenticationServices = ["Foundation"]
CoreData = ["Foundation"]
Foundation = ["objective-c", "blocks"]
Foundation = ["objective-c", "block"]
unstable-all-frameworks = ["AppKit", "AuthenticationServices", "CoreData", "Foundation"]
2 changes: 1 addition & 1 deletion crates/icrate/src/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ pub(crate) use objc2::runtime::{Bool, Class, Object, Sel};
#[cfg(feature = "objective-c")]
pub(crate) use objc2::{__inner_extern_class, extern_class, extern_methods, ClassType, Message};

#[cfg(feature = "blocks")]
#[cfg(feature = "block")]
pub(crate) use block2::Block;

// TODO
Expand Down
1 change: 1 addition & 0 deletions crates/icrate/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#![no_std]
#![cfg_attr(feature = "unstable-docsrs", feature(doc_auto_cfg))]
#![warn(elided_lifetimes_in_paths)]
#![deny(non_ascii_idents)]
#![warn(unreachable_pub)]
Expand Down

0 comments on commit 1417dd6

Please sign in to comment.