Skip to content

Commit

Permalink
Move eyre code into a folder (#107)
Browse files Browse the repository at this point in the history
  • Loading branch information
pksunkara authored Oct 3, 2023
1 parent 044e2ae commit a443fd4
Show file tree
Hide file tree
Showing 39 changed files with 99 additions and 98 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/target
**/*.rs.bk
Cargo.lock
/.pijul/
77 changes: 1 addition & 76 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[workspace]
members = [
"."
"eyre"
]

[workspace.package]
Expand All @@ -14,78 +14,3 @@ rust-version = "1.65.0"
[workspace.dependencies]
indenter = "0.3.0"
once_cell = "1.18.0"

[package]
name = "eyre"
version = "0.6.8"
authors = ["David Tolnay <dtolnay@gmail.com>", "Jane Lusby <jlusby42@gmail.com>"]
description = "Flexible concrete Error Reporting type built on std::error::Error with customizable Reports"
documentation = "https://docs.rs/eyre"
categories = ["rust-patterns"]

edition = { workspace = true }
license = { workspace = true }
repository = { workspace = true }
readme = { workspace = true }
rust-version = { workspace = true }

[features]
default = ["auto-install", "track-caller"]
auto-install = []
track-caller = []

[dependencies]
indenter = { workspace = true }
once_cell = { workspace = true }
pyo3 = { version = "0.13", optional = true, default-features = false }

[dev-dependencies]
futures = { version = "0.3", default-features = false }
rustversion = "1.0"
thiserror = "1.0"
trybuild = { version = "1.0.19", features = ["diff"] }
backtrace = "0.3.46"
anyhow = "1.0.28"
syn = { version = "2.0", features = ["full"] }
pyo3 = { version = "0.13", default-features = false, features = ["auto-initialize"] }

[package.metadata.docs.rs]
targets = ["x86_64-unknown-linux-gnu"]
rustdoc-args = ["--cfg", "doc_cfg"]

[package.metadata.release]
dev-version = false

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "Unreleased"
replace = "{{version}}"

[[package.metadata.release.pre-release-replacements]]
file = "src/lib.rs"
search = "#!\\[doc\\(html_root_url.*"
replace = "#![doc(html_root_url = \"https://docs.rs/{{crate_name}}/{{version}}\")]"
exactly = 1

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "\\.\\.\\.HEAD"
replace = "...{{tag_name}}"
exactly = 1

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "ReleaseDate"
replace = "{{date}}"

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "<!-- next-header -->"
replace = "<!-- next-header -->\n\n## [Unreleased] - ReleaseDate"
exactly = 1

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "<!-- next-url -->"
replace = "<!-- next-url -->\n[Unreleased]: https://github.com/yaahc/{{crate_name}}/compare/{{tag_name}}...HEAD"
exactly = 1
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ eyre
[![Rust Documentation](https://img.shields.io/badge/api-rustdoc-blue.svg)](https://docs.rs/eyre)
[![Discord chat][discord-badge]][discord-url]

[actions-badge]: https://github.com/yaahc/eyre/workflows/Continuous%20integration/badge.svg
[actions-url]: https://github.com/yaahc/eyre/actions?query=workflow%3A%22Continuous+integration%22
[actions-badge]: https://github.com/eyre-rs/eyre/workflows/Continuous%20integration/badge.svg
[actions-url]: https://github.com/eyre-rs/eyre/actions?query=workflow%3A%22Continuous+integration%22
[discord-badge]: https://img.shields.io/discord/960645145018110012?label=eyre%20community%20discord
[discord-url]: https://discord.gg/z94RqmUTKB

Expand Down Expand Up @@ -252,14 +252,14 @@ implements `context` for options which you can import to make existing
[`anyhow::Context`]: https://docs.rs/anyhow/*/anyhow/trait.Context.html
[`anyhow`]: https://github.com/dtolnay/anyhow
[`tracing_error::SpanTrace`]: https://docs.rs/tracing-error/*/tracing_error/struct.SpanTrace.html
[`stable-eyre`]: https://github.com/yaahc/stable-eyre
[`color-eyre`]: https://github.com/yaahc/color-eyre
[`stable-eyre`]: https://github.com/eyre-rs/stable-eyre
[`color-eyre`]: https://github.com/eyre-rs/color-eyre
[`jane-eyre`]: https://github.com/yaahc/jane-eyre
[`simple-eyre`]: https://github.com/yaahc/simple-eyre
[`color-spantrace`]: https://github.com/yaahc/color-spantrace
[`simple-eyre`]: https://github.com/eyre-rs/simple-eyre
[`color-spantrace`]: https://github.com/eyre-rs/color-spantrace
[`color-backtrace`]: https://github.com/athre0z/color-backtrace

[^1]: example and explanation of breakage https://github.com/yaahc/eyre/issues/30#issuecomment-647650361
[^1]: example and explanation of breakage https://github.com/eyre-rs/eyre/issues/30#issuecomment-647650361

#### License

Expand Down
18 changes: 9 additions & 9 deletions CHANGELOG.md → eyre/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0


<!-- next-url -->
[Unreleased]: https://github.com/yaahc/eyre/compare/v0.6.8...HEAD
[0.6.8]: https://github.com/yaahc/eyre/compare/v0.6.7...v0.6.8
[0.6.7]: https://github.com/yaahc/eyre/compare/v0.6.6...v0.6.7
[0.6.6]: https://github.com/yaahc/eyre/compare/v0.6.5...v0.6.6
[0.6.5]: https://github.com/yaahc/eyre/compare/v0.6.4...v0.6.5
[0.6.4]: https://github.com/yaahc/eyre/compare/v0.6.3...v0.6.4
[0.6.3]: https://github.com/yaahc/eyre/compare/v0.6.2...v0.6.3
[0.6.2]: https://github.com/yaahc/eyre/compare/v0.6.1...v0.6.2
[0.6.1]: https://github.com/yaahc/eyre/releases/tag/v0.6.1
[Unreleased]: https://github.com/eyre-rs/eyre/compare/v0.6.8...HEAD
[0.6.8]: https://github.com/eyre-rs/eyre/compare/v0.6.7...v0.6.8
[0.6.7]: https://github.com/eyre-rs/eyre/compare/v0.6.6...v0.6.7
[0.6.6]: https://github.com/eyre-rs/eyre/compare/v0.6.5...v0.6.6
[0.6.5]: https://github.com/eyre-rs/eyre/compare/v0.6.4...v0.6.5
[0.6.4]: https://github.com/eyre-rs/eyre/compare/v0.6.3...v0.6.4
[0.6.3]: https://github.com/eyre-rs/eyre/compare/v0.6.2...v0.6.3
[0.6.2]: https://github.com/eyre-rs/eyre/compare/v0.6.1...v0.6.2
[0.6.1]: https://github.com/eyre-rs/eyre/releases/tag/v0.6.1
74 changes: 74 additions & 0 deletions eyre/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
[package]
name = "eyre"
version = "0.6.8"
authors = ["David Tolnay <dtolnay@gmail.com>", "Jane Lusby <jlusby42@gmail.com>"]
description = "Flexible concrete Error Reporting type built on std::error::Error with customizable Reports"
documentation = "https://docs.rs/eyre"
categories = ["rust-patterns"]

edition = { workspace = true }
license = { workspace = true }
repository = { workspace = true }
readme = { workspace = true }
rust-version = { workspace = true }

[features]
default = ["auto-install", "track-caller"]
auto-install = []
track-caller = []

[dependencies]
indenter = { workspace = true }
once_cell = { workspace = true }
pyo3 = { version = "0.13", optional = true, default-features = false }

[dev-dependencies]
futures = { version = "0.3", default-features = false }
rustversion = "1.0"
thiserror = "1.0"
trybuild = { version = "1.0.19", features = ["diff"] }
backtrace = "0.3.46"
anyhow = "1.0.28"
syn = { version = "2.0", features = ["full"] }
pyo3 = { version = "0.13", default-features = false, features = ["auto-initialize"] }

[package.metadata.docs.rs]
targets = ["x86_64-unknown-linux-gnu"]
rustdoc-args = ["--cfg", "doc_cfg"]

[package.metadata.release]
dev-version = false

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "Unreleased"
replace = "{{version}}"

[[package.metadata.release.pre-release-replacements]]
file = "src/lib.rs"
search = "#!\\[doc\\(html_root_url.*"
replace = "#![doc(html_root_url = \"https://docs.rs/{{crate_name}}/{{version}}\")]"
exactly = 1

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "\\.\\.\\.HEAD"
replace = "...{{tag_name}}"
exactly = 1

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "ReleaseDate"
replace = "{{date}}"

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "<!-- next-header -->"
replace = "<!-- next-header -->\n\n## [Unreleased] - ReleaseDate"
exactly = 1

[[package.metadata.release.pre-release-replacements]]
file = "CHANGELOG.md"
search = "<!-- next-url -->"
replace = "<!-- next-url -->\n[Unreleased]: https://github.com/eyre-rs/{{crate_name}}/compare/{{tag_name}}...HEAD"
exactly = 1
1 change: 1 addition & 0 deletions eyre/LICENSE-APACHE
1 change: 1 addition & 0 deletions eyre/LICENSE-MIT
1 change: 1 addition & 0 deletions eyre/README.md
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
10 changes: 5 additions & 5 deletions src/lib.rs → eyre/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -314,19 +314,19 @@
//! implements `context` for options which you can import to make existing
//! `.context` calls compile.
//!
//! [^1]: example and explanation of breakage https://github.com/yaahc/eyre/issues/30#issuecomment-647650361
//! [^1]: example and explanation of breakage https://github.com/eyre-rs/eyre/issues/30#issuecomment-647650361
//!
//! [Report]: https://docs.rs/eyre/*/eyre/struct.Report.html
//! [`eyre::EyreHandler`]: https://docs.rs/eyre/*/eyre/trait.EyreHandler.html
//! [`eyre::WrapErr`]: https://docs.rs/eyre/*/eyre/trait.WrapErr.html
//! [`anyhow::Context`]: https://docs.rs/anyhow/*/anyhow/trait.Context.html
//! [`anyhow`]: https://github.com/dtolnay/anyhow
//! [`tracing_error::SpanTrace`]: https://docs.rs/tracing-error/*/tracing_error/struct.SpanTrace.html
//! [`stable-eyre`]: https://github.com/yaahc/stable-eyre
//! [`color-eyre`]: https://github.com/yaahc/color-eyre
//! [`stable-eyre`]: https://github.com/eyre-rs/stable-eyre
//! [`color-eyre`]: https://github.com/eyre-rs/color-eyre
//! [`jane-eyre`]: https://github.com/yaahc/jane-eyre
//! [`simple-eyre`]: https://github.com/yaahc/simple-eyre
//! [`color-spantrace`]: https://github.com/yaahc/color-spantrace
//! [`simple-eyre`]: https://github.com/eyre-rs/simple-eyre
//! [`color-spantrace`]: https://github.com/eyre-rs/color-spantrace
//! [`color-backtrace`]: https://github.com/athre0z/color-backtrace
#![doc(html_root_url = "https://docs.rs/eyre/0.6.8")]
#![warn(

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (stable)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (stable, --features auto-install)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (stable, --features pyo3)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (beta, --features track-caller)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (beta, --features auto-install)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (stable, --no-default-features)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (beta, --all-features)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (stable, --all-features)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (beta, --features pyo3)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (beta)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (beta, --no-default-features)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (nightly, --features auto-install)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (nightly, --features pyo3)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (nightly, --features track-caller)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (nightly)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (nightly, --all-features)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (nightly, --no-default-features)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (stable, --features track-caller)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Miri

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (ubuntu-latest)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (macOS-latest)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (windows-latest)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (--features auto-install)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (--features track-caller)

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite

unknown lint: `rustdoc::missing_doc_code_examples`

Check warning on line 332 in eyre/src/lib.rs

View workflow job for this annotation

GitHub Actions / Test Suite (--no-default-features)

unknown lint: `rustdoc::missing_doc_code_examples`
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit a443fd4

Please sign in to comment.