Promote the src/tools crate to the top-level workspace.
The 'src' and 'tests' top-level directories now contain tools sources and integration tests for any of the library crates.
This commit is contained in:
24
Cargo.toml
24
Cargo.toml
@@ -1,3 +1,23 @@
|
|||||||
# Phantom workspace manifest for all Cretonne crates.
|
[package]
|
||||||
|
name = "cretonne-tools"
|
||||||
|
authors = ["The Cretonne Project Developers"]
|
||||||
|
version = "0.0.0"
|
||||||
|
description = "Binaries for testing the Cretonne library"
|
||||||
|
license = "Apache-2.0"
|
||||||
|
documentation = "https://cretonne.readthedocs.io/"
|
||||||
|
repository = "https://github.com/stoklund/cretonne"
|
||||||
|
publish = false
|
||||||
|
|
||||||
|
[[bin]]
|
||||||
|
name = "cton-util"
|
||||||
|
path = "src/cton-util.rs"
|
||||||
|
|
||||||
|
[dependencies]
|
||||||
|
cretonne = { path = "lib/cretonne" }
|
||||||
|
cretonne-reader = { path = "lib/reader" }
|
||||||
|
filecheck = { path = "lib/filecheck" }
|
||||||
|
docopt = "0.6.86"
|
||||||
|
rustc-serialize = "0.3.19"
|
||||||
|
num_cpus = "1.1.0"
|
||||||
|
|
||||||
[workspace]
|
[workspace]
|
||||||
members = ["src/tools"]
|
|
||||||
|
|||||||
@@ -1,18 +0,0 @@
|
|||||||
[package]
|
|
||||||
authors = ["The Cretonne Project Developers"]
|
|
||||||
name = "cretonne-tools"
|
|
||||||
version = "0.0.0"
|
|
||||||
description = "Binaries for testing the Cretonne library"
|
|
||||||
publish = false
|
|
||||||
|
|
||||||
[[bin]]
|
|
||||||
name = "cton-util"
|
|
||||||
path = "main.rs"
|
|
||||||
|
|
||||||
[dependencies]
|
|
||||||
cretonne = { path = "../../lib/cretonne" }
|
|
||||||
cretonne-reader = { path = "../../lib/reader" }
|
|
||||||
filecheck = { path = "../../lib/filecheck" }
|
|
||||||
docopt = "0.6.80"
|
|
||||||
rustc-serialize = "0.3.19"
|
|
||||||
num_cpus = "1.1.0"
|
|
||||||
@@ -34,14 +34,14 @@ RUSTFMT_VERSION="0.6.2"
|
|||||||
|
|
||||||
if cargo install --list | grep -q "^rustfmt v$RUSTFMT_VERSION"; then
|
if cargo install --list | grep -q "^rustfmt v$RUSTFMT_VERSION"; then
|
||||||
banner "Rust formatting"
|
banner "Rust formatting"
|
||||||
$topdir/src/format-all.sh --write-mode=diff
|
$topdir/format-all.sh --write-mode=diff
|
||||||
else
|
else
|
||||||
echo "Please install rustfmt v$RUSTFMT_VERSION to verify formatting."
|
echo "Please install rustfmt v$RUSTFMT_VERSION to verify formatting."
|
||||||
echo "If a newer version of rustfmt is available, update this script."
|
echo "If a newer version of rustfmt is available, update this script."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
PKGS="cretonne cretonne-reader cretonne-tools filecheck"
|
PKGS="cretonne cretonne-reader cretonne-tools filecheck"
|
||||||
cd "$topdir/src/tools"
|
cd "$topdir"
|
||||||
for PKG in $PKGS
|
for PKG in $PKGS
|
||||||
do
|
do
|
||||||
banner "Rust $PKG unit tests"
|
banner "Rust $PKG unit tests"
|
||||||
@@ -49,7 +49,7 @@ do
|
|||||||
done
|
done
|
||||||
|
|
||||||
# Build cton-util for parser testing.
|
# Build cton-util for parser testing.
|
||||||
cd "$topdir/src/tools"
|
cd "$topdir"
|
||||||
banner "Rust documentation"
|
banner "Rust documentation"
|
||||||
echo "open $topdir/target/doc/cretonne/index.html"
|
echo "open $topdir/target/doc/cretonne/index.html"
|
||||||
cargo doc
|
cargo doc
|
||||||
|
|||||||
Reference in New Issue
Block a user