mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-22 22:16:16 +02:00
Merge pull request #3477 from Ninlives/nix-run-using-env
`nix run` using $SHELL as default command
This commit is contained in:
commit
5449ff7d8a
1 changed files with 2 additions and 2 deletions
|
@ -59,14 +59,14 @@ struct RunCommon : virtual Command
|
||||||
|
|
||||||
struct CmdRun : InstallablesCommand, RunCommon, MixEnvironment
|
struct CmdRun : InstallablesCommand, RunCommon, MixEnvironment
|
||||||
{
|
{
|
||||||
std::vector<std::string> command = { "bash" };
|
std::vector<std::string> command = { getEnv("SHELL").value_or("bash") };
|
||||||
|
|
||||||
CmdRun()
|
CmdRun()
|
||||||
{
|
{
|
||||||
mkFlag()
|
mkFlag()
|
||||||
.longName("command")
|
.longName("command")
|
||||||
.shortName('c')
|
.shortName('c')
|
||||||
.description("command and arguments to be executed; defaults to 'bash'")
|
.description("command and arguments to be executed; defaults to '$SHELL'")
|
||||||
.labels({"command", "args"})
|
.labels({"command", "args"})
|
||||||
.arity(ArityAny)
|
.arity(ArityAny)
|
||||||
.handler([&](std::vector<std::string> ss) {
|
.handler([&](std::vector<std::string> ss) {
|
||||||
|
|
Loading…
Reference in a new issue