Skip to content

Commit

Permalink
Merge pull request #287 from gwbres/docrs
Browse files Browse the repository at this point in the history
Introduce docrs
  • Loading branch information
ChristopherRabotin authored Aug 13, 2024
2 parents d876a10 + 6ab58d7 commit 834c11b
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 5 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,13 @@ jobs:
run: sh dev-env-setup.sh && cd .. # Return to root

- name: Test debug
if: secrets.LAGRANGE_BSP != ''
env:
LAGRANGE_BSP: ${{ secrets.LAGRANGE_BSP }}
run: cargo test --workspace --exclude anise-gui --exclude anise-py

- name: Test release
if: secrets.LAGRANGE_BSP != ''
env:
LAGRANGE_BSP: ${{ secrets.LAGRANGE_BSP }}
run: cargo test --release --workspace --exclude anise-gui --exclude anise-py
Expand Down Expand Up @@ -131,6 +133,7 @@ jobs:
run: RUST_BACKTRACE=1 cargo test validate_hermite_type13_ --features spkezr_validation --release --workspace --exclude anise-gui --exclude anise-py -- --nocapture --include-ignored --test-threads 1

- name: Rust-SPICE Lagrange validation
if: secrets.LAGRANGE_BSP != ''
env:
LAGRANGE_BSP: ${{ secrets.LAGRANGE_BSP }}
run: RUST_BACKTRACE=1 cargo test validate_lagrange_type9_with_varying_segment_sizes --features spkezr_validation --release --workspace --exclude anise-gui --exclude anise-py -- --nocapture --include-ignored --test-threads 1
Expand Down Expand Up @@ -205,7 +208,7 @@ jobs:
cargo llvm-cov test --no-report validate_jplde_de440s_no_aberration --features spkezr_validation -- --nocapture --ignored
cargo llvm-cov test --no-report validate_jplde_de440s_aberration_lt --features spkezr_validation -- --nocapture --ignored
cargo llvm-cov test --no-report validate_hermite_type13_from_gmat --features spkezr_validation -- --nocapture --ignored
cargo llvm-cov test --no-report validate_lagrange_type9_with_varying_segment_sizes --features spkezr_validation -- --nocapture --ignored
[ -n "$LAGRANGE_BSP" ] && cargo llvm-cov test --no-report validate_lagrange_type9_with_varying_segment_sizes --features spkezr_validation -- --nocapture --ignored
cargo llvm-cov test --no-report ut_embed --features embed_ephem
cargo llvm-cov report --lcov > ../lcov.txt
Expand Down
5 changes: 2 additions & 3 deletions anise/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,8 @@ repository = { workspace = true }
description = "Core of the ANISE library"

[package.metadata.docs.rs]
features = [
"metaload",
]
all-features = true
rustdoc-ars = ["--cfg", "docrs", "--generate-link-to-definition"]

[dependencies]
lexical-core = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion anise/src/almanac/embed.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ struct AstroData;
impl Almanac {
/// Provides planetary ephemerides from 2024-01-01 until 2035-01-01. Also provides planetary constants data (from the PCK11 kernel).
///
/// Until https://github.com/nyx-space/anise/issues/269, this will provide 100 yeras of data
/// Until https://github.com/nyx-space/anise/issues/269, this will provide 100 years of data
pub fn until_2035() -> AlmanacResult<Self> {
// Regularly refer to https://github.com/nyx-space/anise/blob/master/data/ci_config.dhall for the latest CRC, although it should not change between minor versions!
let pck11 = AstroData::get("pck11.pca").ok_or(AlmanacError::GenericError {
Expand Down
1 change: 1 addition & 0 deletions anise/src/almanac/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ pub mod metaload;
mod python;

#[cfg(feature = "embed_ephem")]
#[cfg_attr(docrs, doc(cfg(feature = "embed_ephem")))]
mod embed;

#[cfg(feature = "python")]
Expand Down
1 change: 1 addition & 0 deletions anise/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#![doc = include_str!("../README.md")]
#![cfg_attr(docsrs, feature(doc_cfg))]
/*
* ANISE Toolkit
* Copyright (C) 2021-onward Christopher Rabotin <[email protected]> et al. (cf. AUTHORS.md)
Expand Down

0 comments on commit 834c11b

Please sign in to comment.