mirror of
https://github.com/AppFlowy-IO/AppFlowy.git
synced 2025-04-24 22:57:12 -04:00
chore: refactor tauri gen files path
This commit is contained in:
parent
0100305af0
commit
d2db49efab
2 changed files with 2 additions and 4 deletions
|
@ -101,8 +101,7 @@ fn generate_ts_protobuf_files(
|
||||||
protoc_bin_path: &Path,
|
protoc_bin_path: &Path,
|
||||||
) {
|
) {
|
||||||
let root = std::env::var("CARGO_MAKE_WORKING_DIRECTORY").unwrap_or("../../".to_string());
|
let root = std::env::var("CARGO_MAKE_WORKING_DIRECTORY").unwrap_or("../../".to_string());
|
||||||
let tauri_protobuf_path =
|
let tauri_protobuf_path = std::env::var("TAURI_PROTOBUF_PATH").unwrap_or("appflowy_tauri/src/protobuf".to_string());
|
||||||
std::env::var("CARGO_MAKE_WORKING_DIRECTORY").unwrap_or("appflowy_tauri/src/protobuf".to_string());
|
|
||||||
|
|
||||||
let mut output = PathBuf::new();
|
let mut output = PathBuf::new();
|
||||||
output.push(root);
|
output.push(root);
|
||||||
|
|
|
@ -14,8 +14,7 @@ use walkdir::WalkDir;
|
||||||
|
|
||||||
pub fn gen(crate_name: &str) {
|
pub fn gen(crate_name: &str) {
|
||||||
let root = std::env::var("CARGO_MAKE_WORKING_DIRECTORY").unwrap_or("../../".to_string());
|
let root = std::env::var("CARGO_MAKE_WORKING_DIRECTORY").unwrap_or("../../".to_string());
|
||||||
let tauri_protobuf_path =
|
let tauri_protobuf_path = std::env::var("TAURI_PROTOBUF_PATH").unwrap_or("appflowy_tauri/src/protobuf".to_string());
|
||||||
std::env::var("CARGO_MAKE_WORKING_DIRECTORY").unwrap_or("appflowy_tauri/src/protobuf".to_string());
|
|
||||||
|
|
||||||
let crate_path = std::fs::canonicalize(".").unwrap().as_path().display().to_string();
|
let crate_path = std::fs::canonicalize(".").unwrap().as_path().display().to_string();
|
||||||
let event_crates = parse_ts_event_files(vec![crate_path]);
|
let event_crates = parse_ts_event_files(vec![crate_path]);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue