将%USERPROFILE%
更改为所需的文件夹。
说明:打开Cmder->设置->任务->选择{cmd::Cmder}(在我的情况下)。在底部(文本框下方)有一个名为“Startup dir...”的按钮,然后选择启动目录。关闭Cmder,然后重新启动。就这样,享受吧。
编辑<APP_DIR>/config/user-startup.cmd
文件,在文件末尾添加一行(假设目录为“e:”):
@cd /d "e:"
编辑文件:\CMDER_DIRECTORY\config\user-profile.cmd
cd C:\xampp\htdocs
:: use this file to run your own startup commands
:: use in front of the command to prevent printing the command
:: uncomment this to have the ssh agent load when cmder starts
:: call "%GIT_INSTALL_ROOT%/cmd/start-ssh-agent.cmd"
:: uncomment this next two lines to use pageant as the ssh authentication agent
:: SET SSH_AUTH_SOCK=/tmp/.ssh-pageant-auth-sock
:: call "%GIT_INSTALL_ROOT%/cmd/start-ssh-pageant.cmd"
:: you can add your plugins to the cmder path like so
:: set "PATH=%CMDER_ROOT%\vendor\whatever;%PATH%"
e:
cd ../../../../../Homestead
@echo off
:Ask
echo Would you like to start the Homestead?(Y/N)
set INPUT=
set /P INPUT=Yes(y) ou No(n): %=%
If /I "%INPUT%"=="y" goto yes
If /I "%INPUT%"=="Y" goto yes
If /I "%INPUT%"=="n" goto no
cls
echo Invalid option
echo -
echo -
goto Ask
:yes
vagrant up
goto finalMessage
:no
cls
goto finalMessage
:finalMessage
echo Your console is ready Mr. Chapela.