Skip to content

Commit

Permalink
Bump version to 0.7.1
Browse files Browse the repository at this point in the history
  • Loading branch information
chipsenkbeil committed Feb 16, 2024
1 parent 70cdb16 commit de66108
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 7 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,12 @@ jobs:
profile: minimal
toolchain: ${{ matrix.rust }}
target: ${{ matrix.target }}
- run: cargo test ${{ matrix.flags }} --target ${{ matrix.target }}
if: matrix.target != 0 && matrix.target != 'wasm32-unknown-unknown'
- run: cargo build ${{ matrix.flags }} --target ${{ matrix.target }}
if: matrix.target != 0 && matrix.target == 'wasm32-unknown-unknown'
- run: cargo test ${{ matrix.flags }}
if: matrix.target == 0
examples:
name: "Run examples using Rust ${{ matrix.rust }} (${{ matrix.os }})"
runs-on: ${{ matrix.os }}
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [0.7.1] - 2024-02-15

* Support `wasm` family for compilation

## [0.7.0] - 2023-11-04

* Support `no_std` environments, when `default-features = false` is set for the crate
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "typed-path"
description = "Provides typed variants of Path and PathBuf for Unix and Windows"
version = "0.7.0"
version = "0.7.1"
edition = "2021"
authors = ["Chip Senkbeil <[email protected]>"]
categories = ["development-tools", "filesystem", "os"]
Expand Down
2 changes: 1 addition & 1 deletion src/common/non_utf8/path.rs
Original file line number Diff line number Diff line change
Expand Up @@ -629,7 +629,7 @@ where
/// let path = cwd.join(Path::new("a/b/../c/./d"));
/// assert_eq!(path.absolutize().unwrap(), cwd.join(Path::new("a/c/d")));
/// ```
#[cfg(feature = "std")]
#[cfg(all(feature = "std", not(target_family = "wasm")))]
pub fn absolutize(&self) -> std::io::Result<PathBuf<T>> {
if self.is_absolute() {
Ok(self.normalize())
Expand Down
2 changes: 1 addition & 1 deletion src/common/utf8/path.rs
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,7 @@ where
/// let path = cwd.join(Utf8Path::new("a/b/../c/./d"));
/// assert_eq!(path.absolutize().unwrap(), cwd.join(Utf8Path::new("a/c/d")));
/// ```
#[cfg(feature = "std")]
#[cfg(all(feature = "std", not(target_family = "wasm")))]
pub fn absolutize(&self) -> std::io::Result<Utf8PathBuf<T>> {
if self.is_absolute() {
Ok(self.normalize())
Expand Down
4 changes: 3 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@ mod no_std_compat {
#[macro_use]
mod common;
mod convert;
#[cfg(not(target_family = "wasm"))]
mod native;
mod typed;
mod unix;
#[cfg(feature = "std")]
#[cfg(all(feature = "std", not(target_family = "wasm")))]
pub mod utils;
mod windows;

Expand All @@ -34,6 +35,7 @@ mod private {

pub use common::*;
pub use convert::*;
#[cfg(not(target_family = "wasm"))]
pub use native::*;
pub use typed::*;
pub use unix::*;
Expand Down
2 changes: 1 addition & 1 deletion src/typed/non_utf8/path.rs
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,7 @@ impl<'a> TypedPath<'a> {
/// let path = cwd.join("a/b/../c/./d");
/// assert_eq!(path.absolutize().unwrap(), cwd.join("a/c/d"));
/// ```
#[cfg(feature = "std")]
#[cfg(all(feature = "std", not(target_family = "wasm")))]
pub fn absolutize(&self) -> io::Result<TypedPathBuf> {
Ok(match self {
Self::Unix(path) => TypedPathBuf::Unix(path.absolutize()?),
Expand Down
2 changes: 1 addition & 1 deletion src/typed/utf8/path.rs
Original file line number Diff line number Diff line change
Expand Up @@ -490,7 +490,7 @@ impl<'a> Utf8TypedPath<'a> {
/// let path = cwd.join("a/b/../c/./d");
/// assert_eq!(path.absolutize().unwrap(), cwd.join("a/c/d"));
/// ```
#[cfg(feature = "std")]
#[cfg(all(feature = "std", not(target_family = "wasm")))]
pub fn absolutize(&self) -> std::io::Result<Utf8TypedPathBuf> {
Ok(match self {
Self::Unix(path) => Utf8TypedPathBuf::Unix(path.absolutize()?),
Expand Down
2 changes: 1 addition & 1 deletion src/typed/utf8/pathbuf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -710,7 +710,7 @@ impl Utf8TypedPathBuf {
/// let path = cwd.join("a/b/../c/./d");
/// assert_eq!(path.absolutize().unwrap(), cwd.join("a/c/d"));
/// ```
#[cfg(feature = "std")]
#[cfg(all(feature = "std", not(target_family = "wasm")))]
pub fn absolutize(&self) -> std::io::Result<Utf8TypedPathBuf> {
self.to_path().absolutize()
}
Expand Down

0 comments on commit de66108

Please sign in to comment.