Skip to content

Commit 4925100

Browse files
committed
refactor(installer): 重构安装脚本并添加新功能
将原有的installScoop.ps1删除,拆分为多个专用安装脚本(installFont.ps1, installSoftware.ps1等) 新增install.ps1作为入口脚本,统一调用各子安装脚本 添加install.psm1模块提供模块安装检测功能 新增测试用例验证安装功能
1 parent ea146b1 commit 4925100

12 files changed

Lines changed: 121 additions & 15 deletions

profile/installer/install.ps1

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
2+
./installModules.ps1
3+
./installApps.ps1
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# 安装模块
2+
3+
$requiredModules = @(
4+
'BurntToast',
5+
'Pester'
6+
)
7+
8+
Install-RequiredModule -ModuleNames $requiredModules

profile/installer/installScoop.ps1

Whitespace-only changes.

profile/loadModule.ps1

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
11
$moduleParent = Split-Path -Parent $PSScriptRoot
2-
Import-Module -Name (Join-Path -Path $moduleParent -ChildPath 'psutils')
2+
Import-Module -Name (Join-Path -Path $moduleParent -ChildPath 'psutils')
3+
4+

profile/loadProfile.ps1

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)