Skip to content
  • Nick Thomas's avatar
    d8a34d23
    Fix {Bash,Cmd,Ps}Writer.IfCmd to escape its arguments · d8a34d23
    Nick Thomas authored
    !359 started using IfCmd instead of Command to execute the cache-extractor and
    cache-archiver commands. These are passed URLs that include various characters
    that need escaping in the IfCmd context, but IfCmd was a naked strings.Join()
    in all cases.
    
    This commit refactors the Command() functions so they and IfCmd() use the same
    code to generate the commands that are run.
    
    PsWriter.IfCmd() is further refactored to avoid iex as I couldn't make it work
    in my powershell installation at all.
    d8a34d23
    Fix {Bash,Cmd,Ps}Writer.IfCmd to escape its arguments
    Nick Thomas authored
    !359 started using IfCmd instead of Command to execute the cache-extractor and
    cache-archiver commands. These are passed URLs that include various characters
    that need escaping in the IfCmd context, but IfCmd was a naked strings.Join()
    in all cases.
    
    This commit refactors the Command() functions so they and IfCmd() use the same
    code to generate the commands that are run.
    
    PsWriter.IfCmd() is further refactored to avoid iex as I couldn't make it work
    in my powershell installation at all.
Loading