mirror of
https://github.com/NixOS/nix
synced 2025-07-01 04:18:00 +02:00
Fix nix shebang interaction with #8131 overhaul completions
This commit is contained in:
parent
e91fd837ee
commit
ffd414eb75
4 changed files with 25 additions and 29 deletions
|
@ -24,24 +24,9 @@ class AddCompletions;
|
|||
|
||||
class Args
|
||||
{
|
||||
/**
|
||||
* @brief The command's "working directory", but only set when top level.
|
||||
*
|
||||
* Use getCommandBaseDir() to get the directory regardless of whether this
|
||||
* is a top-level command or subcommand.
|
||||
*
|
||||
* @see getCommandBaseDir()
|
||||
*/
|
||||
Path commandBaseDir = ".";
|
||||
|
||||
public:
|
||||
|
||||
/**
|
||||
* Parse the command line with argv0, throwing a UsageError if something
|
||||
goes wrong.
|
||||
*/
|
||||
void parseCmdline(const Strings & _cmdline, bool allowShebang);
|
||||
|
||||
/**
|
||||
* Return a short one-line description of the command.
|
||||
*/
|
||||
|
@ -62,7 +47,7 @@ public:
|
|||
*
|
||||
* This only returns the correct value after parseCmdline() has run.
|
||||
*/
|
||||
Path getCommandBaseDir() const;
|
||||
virtual Path getCommandBaseDir() const;
|
||||
|
||||
protected:
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue