init
rewrite of cdb_ui in dioxus rust. goal is to integrate into a single rust codebase
This commit is contained in:
commit
b3a96ed3e3
37 changed files with 9927 additions and 0 deletions
27
build.rs
Normal file
27
build.rs
Normal file
|
@ -0,0 +1,27 @@
|
|||
use std::env;
|
||||
use std::path::Path;
|
||||
use std::process::Command;
|
||||
|
||||
fn main() {
|
||||
let out_dir = env::var("OUT_DIR").unwrap();
|
||||
|
||||
let input = "tailwind.css";
|
||||
let output = "assets/tailwind.css";
|
||||
|
||||
if !Path::new(input).exists() {
|
||||
panic!("Input CSS file not found: {input}");
|
||||
}
|
||||
|
||||
// Run the Tailwind CLI
|
||||
let status = Command::new("tailwindcss")
|
||||
.args(&["-i", input, "-o", output, "--minify"])
|
||||
.status()
|
||||
.expect("Failed to run Tailwind CLI. Is it installed?");
|
||||
|
||||
if !status.success() {
|
||||
panic!("Tailwind build failed with exit code: {}", status);
|
||||
}
|
||||
|
||||
println!("cargo:rerun-if-changed={input}");
|
||||
println!("cargo:rerun-if-changed=tailwind.config.js");
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue