Skip to content

Commit acc55c7

Browse files
committed
Update Bun not use R
1 parent 5e9b563 commit acc55c7

File tree

1 file changed

+5
-8
lines changed
  • src/recipe/lang/Node.js

1 file changed

+5
-8
lines changed

src/recipe/lang/Node.js/Bun.c

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* File Authors : Aoran Zeng <[email protected]>
55
* Contributors : Lontten <[email protected]>
66
* Created On : <2024-09-29>
7-
* Last Modified : <2025-07-21>
7+
* Last Modified : <2025-07-22>
88
* ------------------------------------------------------------*/
99

1010
/**
@@ -30,13 +30,10 @@ pl_nodejs_bun_setsrc (char *option)
3030
// 用的是 npm Registry 的源
3131
chsrc_yield_source (pl_nodejs_group);
3232

33-
char *file =
34-
R"(
35-
[install]
36-
registry = "@url@"
37-
)";
33+
char *content = "[install]\n"
34+
"registry = \"@url@\"\n";
3835

39-
file = xy_str_gsub (file, "@url@", source.url);
36+
content = xy_str_gsub (content, "@url@", source.url);
4037

4138
if (chsrc_in_local_mode())
4239
{
@@ -47,7 +44,7 @@ registry = "@url@"
4744
chsrc_note2 (xy_strjoin (3, "请手动写入以下内容到 ", xy_normalize_path ("~/.bunfig.toml"), " 文件中"));
4845
}
4946

50-
p(file);
47+
print (content);
5148

5249
chsrc_determine_chgtype (ChgType_Auto);
5350
chsrc_conclude (&source);

0 commit comments

Comments
 (0)