@@ -2,7 +2,6 @@ package bun
2
2
3
3
import (
4
4
"log"
5
- "strings"
6
5
7
6
"github.com/moznion/go-optional"
8
7
"github.com/spf13/afero"
@@ -37,15 +36,6 @@ func GetMeta(opt GetMetaOptions) types.PlanMeta {
37
36
bunVersion := DetermineVersion (ctx )
38
37
meta ["bunVersion" ] = bunVersion
39
38
40
- if framework == types .BunFrameworkHono {
41
- entry := determineEntry (ctx )
42
- if entry != "" {
43
- meta ["entry" ] = entry
44
- }
45
-
46
- return meta
47
- }
48
-
49
39
if framework != types .BunFrameworkNone {
50
40
opt .BunFramework = optional .Some (framework )
51
41
}
@@ -99,31 +89,10 @@ func DetermineFramework(ctx *PlanContext) types.BunFramework {
99
89
return fw .Unwrap ()
100
90
}
101
91
102
- if _ , isHono := packageJSON .Dependencies ["hono" ]; isHono {
103
- * fw = optional .Some (types .BunFrameworkHono )
104
- return fw .Unwrap ()
105
- }
106
-
107
92
* fw = optional .Some (types .BunFrameworkNone )
108
93
return fw .Unwrap ()
109
94
}
110
95
111
- func determineEntry (ctx * PlanContext ) string {
112
- if strings .HasPrefix (ctx .PackageJSON .Scripts ["dev" ], "bun run --hot" ) {
113
- return strings .TrimPrefix (ctx .PackageJSON .Scripts ["dev" ], "bun run --hot " )
114
- }
115
-
116
- possibleEntries := []string {"index.ts" , "index.js" , "src/index.ts" , "src/index.js" }
117
-
118
- for _ , entry := range possibleEntries {
119
- if utils .HasFile (ctx .Src , entry ) {
120
- return entry
121
- }
122
- }
123
-
124
- return ""
125
- }
126
-
127
96
// DetermineVersion determines the Bun version to use.
128
97
func DetermineVersion (ctx * PlanContext ) string {
129
98
return utils .ConstraintToVersion (ctx .PackageJSON .Engines .Bun , "latest" )
0 commit comments