From d6a29db59f86ab5d8ca37e10829a30d1182d6326 Mon Sep 17 00:00:00 2001 From: Hunter Trujillo Date: Thu, 13 Jul 2023 17:11:35 -0600 Subject: [PATCH] Add LIB_ID_RGB to build.rs. --- Cargo.lock | 4 ++-- Cargo.toml | 2 +- build.rs | 8 +++++++- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 9145a0e7..bcd5ca48 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2264,9 +2264,9 @@ checksum = "b4b27ab7be369122c218afc2079489cdcb4b517c0a3fc386ff11e1fedfcc2b35" [[package]] name = "payjoin" -version = "0.7.0" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5770c48c69af29fc8fa9f9ccddd9aee7daf2616ba196651913939671fdcf1f" +checksum = "e076c820f8780985db6a2b1f6c0914350becc79aa3e071872bcd4bc17e7e0f06" dependencies = [ "base64 0.13.1", "bip21", diff --git a/Cargo.toml b/Cargo.toml index af720843..15eff489 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -60,7 +60,7 @@ miniscript_crate = { package = "miniscript", version = "9.0.1", features = [ ] } nostr-sdk = "0.22.0" once_cell = "1.17.1" -payjoin = { version = "0.7.0", features = ["sender"] } +payjoin = { version = "0.8.0", features = ["send"] } percent-encoding = "2.2.0" postcard = { version = "1.0.4", features = ["alloc"] } pretty_env_logger = "0.5.0" diff --git a/build.rs b/build.rs index 1ee3aab3..4978ad7f 100644 --- a/build.rs +++ b/build.rs @@ -3,7 +3,7 @@ use std::{collections::BTreeMap, fs}; use anyhow::Result; use rgbstd::{ interface::{LIB_ID_RGB20, LIB_ID_RGB21, LIB_ID_RGB25}, - stl::{LIB_ID_RGB_CONTRACT, LIB_ID_RGB_STD}, + stl::{LIB_ID_RGB, LIB_ID_RGB_CONTRACT, LIB_ID_RGB_STD}, }; use serde::{Deserialize, Serialize}; @@ -12,6 +12,7 @@ type IdVersionMap = BTreeMap; #[allow(non_snake_case)] #[derive(Deserialize, Serialize)] struct LibIds { + LIB_ID_RGB: IdVersionMap, LIB_ID_RGB20: IdVersionMap, LIB_ID_RGB21: IdVersionMap, LIB_ID_RGB25: IdVersionMap, @@ -29,6 +30,11 @@ fn main() -> Result<()> { let lib_ids_file = fs::read_to_string(LIB_IDS_FILE)?; let mut lib_ids: LibIds = toml::from_str(&lib_ids_file)?; + lib_ids + .LIB_ID_RGB + .entry(LIB_ID_RGB.to_owned()) + .or_insert(BMC_VERSION.to_owned()); + lib_ids .LIB_ID_RGB20 .entry(LIB_ID_RGB20.to_owned())