about summary refs log blame commit diff
path: root/src/libexpr/common-opts.hh
blob: bb6d399a8a611851a5f43daf82036711230b7864 (plain) (tree)
1
2
3
4
5
6
7
8
9
            


                  


                                                                     

                                                                       
 


                                                                                    
                                                             
 

                                                
 
#pragma once

#include "eval.hh"

namespace nix {

/* Some common option parsing between nix-env and nix-instantiate. */
bool parseAutoArgs(Strings::iterator & i,
    const Strings::iterator & argsEnd, std::map<string, string> & res);

void evalAutoArgs(EvalState & state, std::map<string, string> & in, Bindings & out);

bool parseSearchPathArg(Strings::iterator & i,
    const Strings::iterator & argsEnd, Strings & searchPath);

Path lookupFileArg(EvalState & state, string s);

}