aboutsummaryrefslogtreecommitdiff
path: root/src/cli.zig
diff options
context:
space:
mode:
authorGravatar Jarred Sumner <jarred@jarredsumner.com> 2021-08-26 15:09:53 -0700
committerGravatar Jarred Sumner <jarred@jarredsumner.com> 2021-08-26 15:09:53 -0700
commita6bf54668acf6d0e099e1ffed4f2126887b5a5c8 (patch)
tree21d202e0840338b76e961208b37b6fc3a0a2ea6f /src/cli.zig
parent029ba1ea4439dff3943b053848901d0391912037 (diff)
downloadbun-a6bf54668acf6d0e099e1ffed4f2126887b5a5c8.tar.gz
bun-a6bf54668acf6d0e099e1ffed4f2126887b5a5c8.tar.zst
bun-a6bf54668acf6d0e099e1ffed4f2126887b5a5c8.zip
Bug fixes
Former-commit-id: 853b372665a3762b1eeeb2202e279895bce6f544
Diffstat (limited to 'src/cli.zig')
-rw-r--r--src/cli.zig8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/cli.zig b/src/cli.zig
index b1eb3fe52..2589fbcfc 100644
--- a/src/cli.zig
+++ b/src/cli.zig
@@ -394,8 +394,10 @@ pub const Arguments = struct {
};
}
- if (entry_points.len == 0 and opts.framework == null and opts.node_modules_bundle_path == null) {
- return error.MissingEntryPoint;
+ if (cmd == .BunCommand or !FeatureFlags.dev_only) {
+ if (entry_points.len == 0 and opts.framework == null and opts.node_modules_bundle_path == null) {
+ return error.MissingEntryPoint;
+ }
}
opts.output_dir = output_dir;
@@ -497,7 +499,7 @@ pub const Command = struct {
log: *logger.Log,
allocator: *std.mem.Allocator,
- pub fn create(allocator: *std.mem.Allocator, log: *logger.Log, comptime command: Command.Tag) !Context {
+ pub fn create(allocator: *std.mem.Allocator, log: *logger.Log, comptime command: Command.Tag) anyerror!Context {
return Command.Context{
.args = try Arguments.parse(allocator, command),
.log = log,