bat ÆÄÀϷΠȤ½Ã ¹ÙÅÁȸé,³»¹®¼,´Ù¿î·Îµå Æú´õ Dµå¶óÀ̺ê·Î °æ·Î º¯°æ ÇÒ¼ö ÀÖ³ª¿ä ??
안녕하세요~!
제가 일하는중에 전 이거 이동 윈도우 아이콘 우클릭해서 할수있는데
이게 저 말고 다른 사용자분들이 매번 전화로 물어봐서 일이이 전부 해주기는 너무 힘들어서
bat 파일 찾아보고 있고 제가 나름 허접한 실력으로 만들어 보려고 했다가
일주일째 무성과 의미 없이 시간만 흘러서요
혹시 bat파일로 위 폴더3개 D드라이브로 경로 이동하게 할수있는 방법 아시면 알려주실수 있을까요 ??
GPT°¡ ´äÀ» Áֳ׿ä.. Âü³ª..
@echo off
setlocal
rem ¹ÙÅÁȸéÀ» D µå¶óÀ̺êÀÇ °æ·Î·Î À̵¿
move "%USERPROFILE%\Desktop" "D:\NewDesktop" /Y
rem ³» ¹®¼¸¦ D µå¶óÀ̺êÀÇ °æ·Î·Î À̵¿
move "%USERPROFILE%\Documents" "D:\NewDocuments" /Y
rem ´Ù¿î·Îµå Æú´õ¸¦ D µå¶óÀ̺êÀÇ °æ·Î·Î À̵¿
move "%USERPROFILE%\Downloads" "D:\NewDownloads" /Y
endlocal
=================================
Âü°í Çϼ¼¿ä..
º»¹® Áú¹®³»¿ëÀº À©µµ¿ì°¡ ÀνÄÇÏ´Â ¹ÙÅÁȸé, ¹®¼, ´Ù¿î·Îµå Æú´õ¸¦ ±âº» À§Ä¡°¡ ¾Æ´Ñ D:µå¶óÀ̺ê·Î ÁöÁ¤À» ÇÏ°í ½ÍÀ¸½Ã´Ù´Â °Å °°Àºµ¥...
setlocal
set NEW_DOWNLOADS_PATH=D:\Downloads
if not exist "%NEW_DOWNLOADS_PATH%" mkdir "%NEW_DOWNLOADS_PATH%"
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v "{374DE290-123F-4565-9164-39C4925E467B}" /t REG_EXPAND_SZ /d "%NEW_DOWNLOADS_PATH%" /f
echo The Downloads folder has been moved to %NEW_DOWNLOADS_PATH%
pause
endlocal
setlocal
set NEW_DOCUMENTS_PATH=D:\Documents
if not exist "%NEW_DOCUMENTS_PATH%" mkdir "%NEW_DOCUMENTS_PATH%"
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v "Personal" /t REG_EXPAND_SZ /d "%NEW_DOCUMENTS_PATH%" /f
echo The Downloads folder has been moved to %NEW_DOWNLOADS_PATH%
pause
endlocal
setlocal
set NEW_DESKTOP_PATH=D:\Desktop
if not exist "%NEW_DESKTOP_PATH%" mkdir "%NEW_DESKTOP_PATH%"
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v "Desktop" /t REG_EXPAND_SZ /d "%NEW_DESKTOP_PATH%" /f
echo The Desktop folder has been moved to %NEW_DESKTOP_PATH%
pause
endlocal
D µå¶óÀ̺ê Ò® ¸ñÇ¥ Æú´õ ¹Ù²Ù½Ã·Á¸é set NEW_OOOO_PATH= µÚ¿¡ ¿øÇÏ´Â °æ·Î ³ÖÀ¸½Ã±¸¿ä¤Å.
Reg º¯°æÀ̴ϸ¸Å Àû¿ë ÈÄ ¹Ù·Î ÀçºÎÆà Çϴ°ÍÀÌ ¾ÈÁ¤¼º¿¡ ÁÁÀ»°Ì´Ï´Ù.
setlocal
:prompt
echo WARNING: This script will change the location of a 'Desktop', 'My Documents', 'Downloads' to custom destination and reboot your system.
echo Do you want to continue? (Y/N)
set /p USERINPUT=Type Y to continue or N to abort:
if /I "%USERINPUT%"=="Y" goto proceed
if /I "%USERINPUT%"=="N" goto abort
echo Invalid input. Please type Y or N.
goto prompt
:changeFolder
set FOLDER_NAME=%1
set FOLDER_PATH=%2
set FOLDER_KEY=%3
if not exist "%FOLDER_PATH%" mkdir "%FOLDER_PATH%"
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v "%FOLDER_KEY%" /t REG_EXPAND_SZ /d "%FOLDER_PATH%" /f
echo %FOLDER_NAME% folder has been moved to %FOLDER_PATH%.
goto end
:proceed
call :changeFolder "Downloads" "D:\Downloads" "{374DE290-123F-4565-9164-39C4925E467B}"
call :changeFolder "My Documents" "D:\Documents" "Personal"
call :changeFolder "Desktop" "D:\Desktop" "Desktop"
echo Your system will reboot witnin 5sec to apply changes.
shutdown /r /t 5
goto end
:abort
echo Operation aborted by the user.
goto end
:end
endlocal
»ç¿ëÀÚÇÑÅ× Àû¿ë ÈÄ ÀçºÎÆà µÉ°Å¶ó´Â °æ°í¹®±¸ ¶ç¿î´ÙÀ½ µ¿ÀÇ ¹ÞÀ¸¸é ÁøÇàµÇ°í, Àû¿ë ÈÄ 5ÃÊ ¾È¿¡ ÀçºÎÆà ½ÃÀÛÀÔ´Ï´Ù.
Àúµµ °£È¤ ÀÏÀÏÀÌ ¼Ó¼º¿¡ µé¾î°¡¼ º¯°æÇϴµ¥ ÆíÇÏ°Ô Çѹø¿¡ ÇÒ¼öÀְڳ׿ä
±Û¾¾»öÀ» ¹Ù²Ù°í Çѱ۷Π¾È³»ÈÄ ¼±ÅÃÇÏ°Ô Âزû ¼öÁ¤Çß½À´Ï´Ù.
setlocal
color f4
:prompt
echo WARNING: This script will change the location of a 'Desktop', 'My Documents', 'Downloads' to custom destination and reboot your system. ³»¹®¼,´Ù¿î·Îµå,¹ÙÅÁȸé Æú´õ¸¦ Cµå¶óÀ̺꿡¼ Dµå¶óÀ̺ê·Î º¯°æÇÕ´Ï´Ù. º¯°æÈÄ ÀÚµ¿ ÀçºÎÆà µË´Ï´Ù.
echo Do you want to continue? ¿øÇϽøé Y ¿øÄ¡¾ÊÀ¸½Ã¸é N ¸¦ ¼±ÅÃÇϼ¼¿ä (Y/N)