From 115e98005006aeea87d31be0d00eda389339f58a Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Mon, 16 May 2022 14:18:35 -0700 Subject: [PATCH] Add a main.rs to generate the compressed representation --- .gitignore | 4 ++++ generate/Cargo.toml | 5 +++++ generate/src/main.rs | 15 +++++++++++++++ 3 files changed, 24 insertions(+) create mode 100644 .gitignore create mode 100644 generate/Cargo.toml create mode 100644 generate/src/main.rs diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..2d73ed9 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +/target +/Cargo.lock +/UCD +/UCD.zip diff --git a/generate/Cargo.toml b/generate/Cargo.toml new file mode 100644 index 0000000..6027557 --- /dev/null +++ b/generate/Cargo.toml @@ -0,0 +1,5 @@ +[package] +name = "unicode-ident-generate" +version = "0.0.0" +edition = "2021" +publish = false diff --git a/generate/src/main.rs b/generate/src/main.rs new file mode 100644 index 0000000..48f6e07 --- /dev/null +++ b/generate/src/main.rs @@ -0,0 +1,15 @@ +// To regenerate tables, run the following in the repo root: +// +// $ cargo install ucd-generate +// $ curl -LO https://www.unicode.org/Public/zipped/14.0.0/UCD.zip +// $ unzip UCD.zip -d UCD +// $ ucd-generate property-bool UCD --include XID_Start,XID_Continue > generate/src/ucd.rs +// $ cargo run --manifest-path generate/Cargo.toml + +#[rustfmt::skip] +#[allow(dead_code)] +mod ucd; + +fn main() { + /* TODO */ +}