This repository has been archived by the owner on Jun 13, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
install.ps1
52 lines (48 loc) · 1.87 KB
/
install.ps1
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
41
42
43
44
45
46
47
48
49
50
51
52
function IsAuroraInstalled?ReturnWhere {
[CmdletBinding()]
$app = Get-ItemProperty -Path "HKLM:\Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\*" |
Where-Object { $_.URLInfoAbout -match "http://www.project-aurora.com/" } |
Select-Object "Inno Setup: App Path"
if ($app) {
return $app."Inno Setup: App Path"
}
}
$installPath = $(IsAuroraInstalled?ReturnWhere)
if($installPath) {
Get-ChildItem -Path "kb_layouts/Extra Features" | % {
Copy-Item $_.fullname "$installPath/kb_layouts/Extra Features" -Recurse -Force
}
do
{
echo "select your claymore keyboard configuration:
1) Asus Claymore Core
2) Asus Claymore Core + Asus Claymore Bond
3) Asus Claymore Bond + Asus Claymore Core
"
$input = Read-Host "Please make a selection"
switch ($input)
{
'1' {
Copy-Item "kb_layouts/asus-claymore-core.json" $installPath/kb_layouts/generic_laptop.json
echo "Asus Claymore Core keyboard layout successfully overwrite Generic Laptop"
return
} '2' {
Copy-Item "kb_layouts/asus-claymore-full.json" $installPath/kb_layouts/generic_laptop.json
echo "Asus Claymore Core + Asus Claymore Bond keyboard layout successfully overwrite Generic Laptop"
return
} '3' {
Copy-Item "kb_layouts/asus-claymore-left.json" $installPath/kb_layouts/generic_laptop.json
echo "Asus Claymore Bond + Asus Claymore Core keyboard layout successfully overwrite Generic Laptop"
return
} 'q' {
return
}
}
}
until ($input -eq 'q')
} else {
echo "Please install Aurora first, you can get it at the following link:
https://www.project-aurora.com/
or with the chocolatey command:
cinst project-aurora"
}