Search code examples
command-linecmdenvironment-variablesvagrantregedit

Windows CMD equilvance of this command


I'm following this guide here: https://github.com/edx/configuration/wiki/edX-Developer-Stack

In setting up a edx server. I've done this on Cywgin, now I am trying to replicate the process on Windows Command Line.

I come to this command, which is setting the environment for Vagrant

export VAGRANT_MOUNT_BASE=$PWD

What would be the equivalence in Windows? I've seen multiple ways through internet searches such as regedit, but I'm not too clear what is the right one.


Solution

  • The following command should do the trick:

    set "VAGRANT_MOUNT_BASE=%CD%"
    

    The shell variable $PWD refers to the current working directory. %CD% does the same thing under CMD.EXE. The bash command export makes the variable visible as an environment variable for Vagrant. Under Windows variables set up with the set command are visible by default.