📝
winget の一発環境構築
@echo off
setlocal enabledelayedexpansion
rem winget
set APPS_0=9NBLGGH4NNS1
rem windows tools
set APPS_1=Microsoft.PowerToys
set APPS_2=Microsoft.WindowsTerminal
set APPS_3=Microsoft.PowerShell
rem game
set APPS_10=Valve.Steam
rem iTunes
set APPS_11=9PB2MZ1ZMB1S
rem LINE
set APPS_12=9WZDNCRFJ2G6
rem communication
set APPS_20=SlackTechnologies.Slack
set APPS_21=Discord.Discord
rem tweeten
set APPS_22=9NBLGGH52XBX
rem browse
set APPS_30=Google.Chrome
set APPS_31=Mozilla.Firefox
rem develop
set APPS_40=Microsoft.VisualStudioCode
set APPS_41=Git.Git
set APPS_42=Docker.DockerDesktop
set APPS_43=Google.Drive
set APPS_44=Kitware.CMake
set APPS_45=7zip.7zip
set APPS_46=Audacity.Audacity
set APPS_47=Google.CloudSDK
set APPS_48=WinMerge.WinMerge
rem lang
set APPS_60=Python.Python.3.10
set APPS_61=Rustlang.Rust.MSVC
set APPS_62=RubyInstallerTeam.RubyWithDevKit.3.1
set APPS_63=Oracle.JavaRuntimeEnvironment
rem os
set APPS_80=Canonical.Ubuntu.2204
set i=0
:FOREACH_APPS
set app=!APPS_%i%!
if defined app (
echo %app%
winget install -e --id %app% --accept-package-agreements --accept-source-agreements
if %ERRORLEVEL% EQU 0 Echo %app% installed successfully.
)
set /a i+=1
if %i% lss 100 (
goto :FOREACH_APPS
)
rem PowerShell setting
Set-ExecutionPolicy RemoteSigned
Discussion