PowerToys 키보드 매니저 배치파일 제작

PowerToys 키보드 매니저 배치파일 제작

Summary PowerToys 키보드 매니저를 위한 배치파일 제작 방법을 설명하며, 소스 및 타겟 디렉토리를 설정하고, 파일을 복사하는 명령어와 관리자 권한 요청을 위한 스크립트를 포함하고 있습니다.


🔗 https://ngo.migrantok.org/bbs/board.php?bo_table=computer&wr_id=233

🔗 https://ansan-survivor.tistory.com/373?category=458475

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
@echo on

rem Set the source and target directories.
set SOURCE=%~dp0
set MODE=%setting_Texshinobi
set TARGET=%LOCALAPPDATA%\Microsoft\PowerToys\Keyboard Manager

rem Use xcopy to copy only the files in the "setting1" directory.
xcopy /y "%SOURCE%%MODE%\*" "%TARGET%" /e /h /k

 :: BatchGotAdmin
 :-------------------------------------
 REM  --> Check for permissions
 >nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system"

REM --> If error flag set, we do not have admin.
 if '%errorlevel%' NEQ '0' (
     echo Requesting administrative privileges...
     goto UACPrompt
 ) else ( goto gotAdmin )

:UACPrompt
     echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs"
     echo UAC.ShellExecute "%~s0", "", "", "runas", 1 >> "%temp%\getadmin.vbs"

    "%temp%\getadmin.vbs"
     exit /B

:gotAdmin
     if exist "%temp%\getadmin.vbs" ( del "%temp%\getadmin.vbs" )
     pushd "%CD%"
     CD /D "%~dp0"
 :--------------------------------------

@echo off

taskkill /F /IM powertoys.exe
start "" "C:\Program Files\PowerToys\PowerToys.exe"

exit

💬 댓글

GitHub 계정으로 로그인하여 댓글을 남겨보세요. GitHub 로그인

🔧 댓글 시스템 설정이 필요합니다

GitHub Discussions 기반 댓글 시스템을 활성화하려면:

  1. Giscus 설정 페이지에서 설정 생성
  2. GISCUS_SETUP_GUIDE.md 파일의 안내를 따라 설정 완료
  3. Repository의 Discussions 기능 활성화

Repository 관리자만 설정할 수 있습니다. 설정이 완료되면 모든 방문자가 댓글을 남길 수 있습니다.

목차