mirror of
https://github.com/tauri-apps/tauri.git
synced 2026-04-01 10:01:07 +02:00
* update .gitignore * remove cargo.lock * line to rebuild on a change to the dist folder. * add expect
This commit is contained in:
committed by
GitHub
parent
7ac442e3f6
commit
9625c0fdf6
@@ -4,13 +4,15 @@ extern crate tauri_includedir_codegen;
|
||||
pub fn main() {
|
||||
#[cfg(not(feature = "dev-server"))]
|
||||
{
|
||||
println!(
|
||||
"cargo:rerun-if-changed={}",
|
||||
std::env::var("TAURI_DIST_DIR").expect("Unable to read dist directory")
|
||||
);
|
||||
match std::env::var("TAURI_DIST_DIR") {
|
||||
Ok(dist_path) => {
|
||||
let inlined_assets = match std::env::var("TAURI_INLINED_ASSETS") {
|
||||
Ok(assets) => {
|
||||
assets.split("|").map(|s| s.to_string()).collect()
|
||||
}
|
||||
Err(_) => Vec::new()
|
||||
Ok(assets) => assets.split("|").map(|s| s.to_string()).collect(),
|
||||
Err(_) => Vec::new(),
|
||||
};
|
||||
// include assets
|
||||
tauri_includedir_codegen::start("ASSETS")
|
||||
|
||||
Reference in New Issue
Block a user