Skip to content

Commit b694af8

Browse files
authored
chore: improve build (#3861)
* chore: improve cargo build time * chore: install dprint to workspace root
1 parent efbd846 commit b694af8

File tree

6 files changed

+134
-3
lines changed

6 files changed

+134
-3
lines changed

.zed/settings.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
{
22
"file_scan_exclusions": [],
33
"formatter": "language_server",
4+
"languages": {
5+
"JavaScript": {
6+
"formatter": "prettier"
7+
},
8+
"TypeScript": {
9+
"formatter": "prettier"
10+
}
11+
},
412
"lsp": {
513
"rust-analyzer": {
614
"initialization_options": {

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/data/build.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ use owhisper_interface::{SpeakerIdentity, Word2};
22

33
fn run(name: &str) {
44
let raw_path = format!("src/{}/raw.json", name);
5+
println!("cargo:rerun-if-changed={}", raw_path);
56
let raw_content = std::fs::read_to_string(&raw_path).unwrap();
67

78
let raw: serde_json::Value = serde_json::from_str(&raw_content).unwrap();
@@ -30,6 +31,8 @@ fn run(name: &str) {
3031
}
3132

3233
fn main() {
34+
println!("cargo:rerun-if-changed=build.rs");
35+
3336
run("english_3");
3437
run("english_4");
3538
run("english_5");

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,14 @@
22
"scripts": {
33
"fmt:check": "echo 'TODO'",
44
"fmt": "dprint fmt",
5-
"lint": "pnpm exec oxlint --type-aware || pnpm exec eslint"
5+
"lint": "oxlint --type-aware || eslint"
66
},
77
"devDependencies": {
88
"@dotenvx/dotenvx": "^1.52.0",
99
"@prettier/plugin-oxc": "^0.1.3",
1010
"@tanstack/eslint-plugin-query": "^5.91.4",
1111
"@trivago/prettier-plugin-sort-imports": "^6.0.2",
12+
"dprint": "^0.51.1",
1213
"eslint": "^9.39.2",
1314
"oxfmt": "^0.18.0",
1415
"oxlint": "^1.46.0",

plugins/misc/build.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,10 @@ const COMMANDS: &[&str] = &[
1313
];
1414

1515
fn main() {
16-
let gitcl = vergen_gix::GixBuilder::all_git().unwrap();
16+
let gitcl = vergen_gix::GixBuilder::default()
17+
.sha(false)
18+
.build()
19+
.unwrap();
1720
vergen_gix::Emitter::default()
1821
.add_instructions(&gitcl)
1922
.unwrap()

pnpm-lock.yaml

Lines changed: 116 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)