diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index dc5f2885..11c2db3f 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -51,7 +51,7 @@ jobs: - name: Run cargo check run: | cargo clean - ./convert-to-heed3.sh + bash convert-to-heed3.sh cargo check -p heed3 check_all_features: @@ -104,7 +104,7 @@ jobs: - name: Run cargo test run: | cargo clean - ./convert-to-heed3.sh + bash convert-to-heed3.sh cargo check --all-features -p heed3 examples: @@ -155,7 +155,7 @@ jobs: - name: Run the examples run: | cargo clean - ./convert-to-heed3.sh + bash convert-to-heed3.sh cargo run --example 2>&1 | grep -E '^ '| xargs -n1 cargo run --example fmt: diff --git a/convert-to-heed3.sh b/convert-to-heed3.sh index 16d7b720..99e56fa7 100755 --- a/convert-to-heed3.sh +++ b/convert-to-heed3.sh @@ -1,3 +1,5 @@ +#!/usr/bin/env bash + # This script is meant to setup the heed3 crate. # @@ -10,7 +12,12 @@ set -e # It basically copy the heed3/Cargo.toml file into # the heed folder... -cp heed3/Cargo.toml heed/Cargo.toml +if [[ "$OSTYPE" == "cygwin" || "$OSTYPE" == "msys" ]]; then + echo 'I did it on Windows' + cp heed3\\Cargo.toml heed\\Cargo.toml +else + cp heed3/Cargo.toml heed/Cargo.toml +fi # ...and replaces the `heed::` string by the `heed3::` one. for file in $(find heed/src -type f -name "*.rs"); do