feat: udpates
This commit is contained in:
@@ -4,7 +4,7 @@ use rust_util::{opt_result, simple_error, XResult};
|
||||
|
||||
use crate::spec::TinyEncryptMeta;
|
||||
|
||||
pub fn write_tiny_encrypt_meta<W: Write>(w: &mut W, meta: &TinyEncryptMeta) -> XResult<usize> {
|
||||
pub fn _write_tiny_encrypt_meta<W: Write>(w: &mut W, meta: &TinyEncryptMeta) -> XResult<usize> {
|
||||
let meta_json = opt_result!( serde_json::to_string(meta), "Meta to JSON failed: {}");
|
||||
let meta_json_bytes = meta_json.as_bytes();
|
||||
let meta_json_bytes_len = meta_json_bytes.len();
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
pub const TINY_ENCRYPT_VERSION: &'static str = "1.0";
|
||||
// pub const TINY_ENCRYPT_VERSION: &'static str = "1.0";
|
||||
|
||||
// pub const ENVELOP_TYPE_KMS: &'static str = "kms";
|
||||
// pub const ENVELOP_TYPE_PGP: &'static str = "pgp";
|
||||
|
||||
@@ -46,7 +46,7 @@ pub fn read_number(hint: &str, from: usize, to: usize) -> usize {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn get_user_agent() -> String {
|
||||
pub fn _get_user_agent() -> String {
|
||||
format!("TinyEncrypt-rs v{}@{}", env!("CARGO_PKG_VERSION"),
|
||||
if cfg!(target_os = "macos") {
|
||||
"MacOS"
|
||||
|
||||
Reference in New Issue
Block a user