Skip to content

Commit 0ce9dbc

Browse files
committed
remove moar pathStackInPlace
1 parent fca3dab commit 0ce9dbc

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

devbox.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ type Devbox interface {
2020
Config() *devconfig.Config
2121
EnvVars(ctx context.Context) ([]string, error)
2222
Info(ctx context.Context, pkg string, markdown bool) (string, error)
23-
Install(ctx context.Context, pathStackInPlace bool) error
23+
Install(ctx context.Context) error
2424
IsEnvEnabled() bool
2525
ListScripts() []string
26-
NixEnv(ctx context.Context, includeHooks, pathStackInPlace bool) (string, error)
26+
NixEnv(ctx context.Context, includeHooks bool) (string, error)
2727
PackageNames() []string
2828
ProjectDir() string
2929
Pull(ctx context.Context, opts devopt.PullboxOpts) error

internal/boxcli/install.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ func installCmdFunc(cmd *cobra.Command, flags runCmdFlags) error {
3939
if err != nil {
4040
return errors.WithStack(err)
4141
}
42-
if err = box.Install(cmd.Context(), false /*preservePathStack*/); err != nil {
42+
if err = box.Install(cmd.Context()); err != nil {
4343
return errors.WithStack(err)
4444
}
4545
fmt.Fprintln(cmd.ErrOrStderr(), "Finished installing packages.")

internal/boxcli/shell.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ func runShellCmd(cmd *cobra.Command, flags shellCmdFlags) error {
6666
if flags.printEnv {
6767
// false for includeHooks is because init hooks is not compatible with .envrc files generated
6868
// by versions older than 0.4.6
69-
script, err := box.NixEnv(cmd.Context(), false /*includeHooks*/, false /*preservePathStack*/)
69+
script, err := box.NixEnv(cmd.Context(), false /*includeHooks*/)
7070
if err != nil {
7171
return err
7272
}

internal/boxcli/shellenv.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,12 +80,12 @@ func shellEnvFunc(cmd *cobra.Command, flags shellEnvCmdFlags) (string, error) {
8080
}
8181

8282
if flags.install {
83-
if err := box.Install(cmd.Context(), flags.preservePathStack); err != nil {
83+
if err := box.Install(cmd.Context()); err != nil {
8484
return "", err
8585
}
8686
}
8787

88-
envStr, err := box.NixEnv(cmd.Context(), flags.runInitHook, flags.preservePathStack)
88+
envStr, err := box.NixEnv(cmd.Context(), flags.runInitHook)
8989
if err != nil {
9090
return "", err
9191
}

internal/impl/devbox.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -264,11 +264,11 @@ func (d *Devbox) RunScript(ctx context.Context, cmdName string, cmdArgs []string
264264
// Install ensures that all the packages in the config are installed and
265265
// creates all wrappers, but does not run init hooks. It is used to power
266266
// devbox install cli command.
267-
func (d *Devbox) Install(ctx context.Context, pathStackInPlace bool) error {
267+
func (d *Devbox) Install(ctx context.Context) error {
268268
ctx, task := trace.NewTask(ctx, "devboxInstall")
269269
defer task.End()
270270

271-
if _, err := d.NixEnv(ctx, false /*includeHooks*/, pathStackInPlace); err != nil {
271+
if _, err := d.NixEnv(ctx, false /*includeHooks*/); err != nil {
272272
return err
273273
}
274274
return wrapnix.CreateWrappers(ctx, d)
@@ -285,7 +285,7 @@ func (d *Devbox) ListScripts() []string {
285285
return keys
286286
}
287287

288-
func (d *Devbox) NixEnv(ctx context.Context, includeHooks, pathStackInPlace bool) (string, error) {
288+
func (d *Devbox) NixEnv(ctx context.Context, includeHooks bool) (string, error) {
289289
ctx, task := trace.NewTask(ctx, "devboxNixEnv")
290290
defer task.End()
291291

0 commit comments

Comments
 (0)