Skip to content

Missing package prompt should offer to create a temp environment #46231

@LilithHafner

Description

@LilithHafner

A common workflow of mine is activate temp, install package

(@v1.7) pkg> activate --temp
  Activating new project at `/var/folders/hc/fn82kz1j5vl8w7lwd4l079y80000gn/T/jl_gHI3S1`

julia> using DataFrames
 │ Package DataFrames not found, but a package named DataFrames is available from a registry. 
 │ Install package?
 │   (jl_gHI3S1) pkg> add DataFrames 
 └ (y/n/o) [y]: 

It would be nice for me if creating a new temporary environment was an option in the missing package prompt

julia> using DataFrames
 │ Package DataFrames not found, but a package named DataFrames is available from a registry. 
 │ Install package?
 │   (@v1.7) pkg> add DataFrames 
 └ Select environment:
   1: `~/.julia/environments/v1.7/Project.toml` (@)
   2: `~/.julia/environments/v1.8/Project.toml` (@v#.#)
 > 3: `/var/folders/hc/fn82kz1j5vl8w7lwd4l079y80000gn/T/jl_gHI3S1` (-temp)

Metadata

Metadata

Assignees

No one assigned

    Labels

    REPLJulia's REPL (Read Eval Print Loop)duplicateIndicates similar issues or pull requestsfeatureIndicates new feature / enhancement requestspackagesPackage management and loading

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions