Skip to content

Commit 3707d59

Browse files
committed
Fix build issue rust-shell-script#12
Deprecated declarative macros and use proc_macros by default.
1 parent 88eaa79 commit 3707d59

File tree

4 files changed

+16
-8
lines changed

4 files changed

+16
-8
lines changed

Cargo.toml

+2-4
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,10 @@ documentation = "https://docs.rs/cmd_lib"
88
keywords = ["shell", "scripts", "commandline", "subprocess", "pipeline"]
99
categories = ["command-line-interface", "command-line-utilities"]
1010
readme = "README.md"
11-
version = "0.8.3"
11+
version = "0.8.4"
1212
authors = ["rust-shell-script <[email protected]>"]
1313
edition = "2018"
1414

1515
[dependencies]
16-
cmd_lib_macros = { version = "0.1", path = "crates/macros" }
17-
# For nightly:
18-
# cmd_lib_macros = { version = "0.1", path = "crates/proc_macros" }
1916
cmd_lib_core = { version = "0.1", path = "crates/cmd_lib_core" }
17+
cmd_lib_macros = { version = "0.1", path = "crates/proc_macros" }

crates/cmd_lib_core/Cargo.toml

+5-4
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
[package]
22
name = "cmd_lib_core"
3+
description = "Common rust commandline macros and utils, to write shell script like tasks easily"
4+
license = "MIT OR Apache-2.0"
5+
homepage = "https://github.com/rust-shell-script/rust_cmd_lib"
6+
repository = "https://github.com/rust-shell-script/rust_cmd_lib"
7+
keywords = ["shell", "scripts", "commandline", "subprocess", "pipeline"]
38
version = "0.1.0"
49
authors = ["Tao Guo <[email protected]>"]
510
edition = "2018"
6-
7-
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
8-
9-
[dependencies]

crates/macros/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
These declarative macros are deprecated for two major reasons:
2+
- source_text! macro is using include_str!, which will include all the
3+
original source file into the final binary
4+
- Using CARGO_MANIFEST_DIR environment variable is fragile, see issue #12

crates/proc_macros/Cargo.toml

+5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
[package]
22
name = "cmd_lib_macros"
3+
description = "Common rust commandline macros and utils, to write shell script like tasks easily"
4+
license = "MIT OR Apache-2.0"
5+
homepage = "https://github.com/rust-shell-script/rust_cmd_lib"
6+
repository = "https://github.com/rust-shell-script/rust_cmd_lib"
7+
keywords = ["shell", "scripts", "commandline", "subprocess", "pipeline"]
38
version = "0.1.0"
49
authors = ["Tao Guo <[email protected]>"]
510
edition = "2018"

0 commit comments

Comments
 (0)