From 00e88bceaa1a1c35d9c3019f65f3e20459fafe33 Mon Sep 17 00:00:00 2001 From: Will Smith Date: Mon, 20 Nov 2023 10:16:21 -0800 Subject: [PATCH] prepare macro crate for publishing to crates.io --- macro/Cargo.toml | 7 +++++++ macro/README.md | 18 +++++++++++++++--- 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/macro/Cargo.toml b/macro/Cargo.toml index 4d0f0d1..e96a90b 100644 --- a/macro/Cargo.toml +++ b/macro/Cargo.toml @@ -2,6 +2,13 @@ name = "gazelle" version = "0.1.0" edition = "2021" +license = "Apache-2.0" +description = "Helper macros for the gazelle_rust build file generator" +homepage = "https://github.com/Calsign/gazelle_rust/tree/main/macro" +repository = "https://github.com/Calsign/gazelle_rust" +keywords = ["bazel", "gazelle_rust"] +categories = ["development-tools"] +exclude = ["BUILD.bazel", "src/BUILD.bazel", "tests/BUILD.bazel"] [lib] name = "gazelle" diff --git a/macro/README.md b/macro/README.md index ab514a4..1e496e3 100644 --- a/macro/README.md +++ b/macro/README.md @@ -1,5 +1,13 @@ +gazelle\_rust is a gazelle language plugin for Rust; automatic dependency management for projects +built with Bazel. -This is a tiny proc_macro crate that provides attribute macros for gazelle. The macros return their +References: + - [gazelle\_rust](https://github.com/Calsign/gazelle_rust) + - [Gazelle](https://github.com/bazelbuild/bazel-gazelle) + - [rules\_rust](https://github.com/bazelbuild/rules_rust) + - [Bazel](https://bazel.build/) + +This is a tiny proc\_macro crate that provides attribute macros for gazelle. The macros return their inputs unchanged, and exist only to pass information to gazelle. The attributes are also referred to as "directives". @@ -7,5 +15,9 @@ An alternative would be for gazelle to parse special comments. Using the attribu ways: it allows more direct control over which items should be affected by a particular directive, and it's easier to integrate into the existing syn-based parser. -This crate has a cargo-compatible directory structure so that in the future it can be published on -crates.io to support projects that build with both bazel and cargo. +This crate has a cargo-compatible directory because it is also published to crates.io to support +projects that build both with bazel and cargo. + +Since crates.io has a global namespace, this is the one and only "gazelle" package. Please reach out +to me if you're working on an alternative gazelle plugin for Rust, I'm happy to make changes as long +as backwards-compatibility is maintained.