Skip to content

Commit

Permalink
refactor: text editor & media to other branch
Browse files Browse the repository at this point in the history
  • Loading branch information
he3als committed Dec 15, 2023
1 parent 1fcbb5a commit 23a4236
Show file tree
Hide file tree
Showing 9 changed files with 1 addition and 173 deletions.
52 changes: 0 additions & 52 deletions src/playbook/Configuration/atlas/start.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,56 +81,4 @@ actions:
option: 'browser-firefox'
runas: currentUserElevated

# Media players
- !writeStatus: {status: 'Installing mpv', option: 'player-mpv'}
- !powerShell:
command: '.\SOFTWARE.ps1 -mpv'
exeDir: true
wait: true
weight: 90
option: 'player-mpv'
runas: currentUserElevated
- !writeStatus: {status: 'Installing MPC-HC', option: 'player-mpchc'}
- !powerShell:
command: '.\SOFTWARE.ps1 -mpchc'
exeDir: true
wait: true
weight: 90
option: 'player-mpchc'
runas: currentUserElevated
- !writeStatus: {status: 'Installing VLC', option: 'player-vlc'}
- !powerShell:
command: '.\SOFTWARE.ps1 -vlc'
exeDir: true
wait: true
weight: 90
option: 'player-vlc'
runas: currentUserElevated

# Text editors
- !writeStatus: {status: 'Installing Notepad++', option: 'editor-npp'}
- !powerShell:
command: '.\SOFTWARE.ps1 -npp'
exeDir: true
wait: true
weight: 90
option: 'editor-npp'
runas: currentUserElevated
- !writeStatus: {status: 'Installing VSCode', option: 'editor-vscode'}
- !powerShell:
command: '.\SOFTWARE.ps1 -vscode'
exeDir: true
wait: true
weight: 120
option: 'editor-vscode'
runas: currentUserElevated
- !writeStatus: {status: 'Installing VLC', option: 'editor-vscodium'}
- !powerShell:
command: '.\SOFTWARE.ps1 -vscodium'
exeDir: true
wait: true
weight: 120
option: 'editor-vscodium'
runas: currentUserElevated

################ END NO LOCAL BUILD ################
68 changes: 1 addition & 67 deletions src/playbook/Executables/SOFTWARE.ps1
Original file line number Diff line number Diff line change
@@ -1,13 +1,7 @@
param (
[switch]$Chrome,
[switch]$Brave,
[switch]$Firefox,
[switch]$MPV,
[switch]$MPCHC,
[switch]$VLC,
[switch]$NotepadPlusPlus,
[switch]$VisualStudioCode,
[switch]$VSCodium
[switch]$Firefox
)

# ----------------------------------------------------------------------------------------------------------- #
Expand Down Expand Up @@ -60,66 +54,6 @@ if ($Chrome) {
exit
}

#################
## MEDIA ##
#################

# mpv
# if ($mpv) {
# Write-Host "Installing mpv..."
# & curl.exe -LSs "https://dl.google.com/dl/chrome/install/googlechromestandaloneenterprise64.msi" -o "$tempDir\chrome.msi"
# Start-Process -FilePath "$tempDir\chrome.msi" -WindowStyle Hidden -ArgumentList '/qn' -Wait 2>&1 | Out-Null
# exit
#}

# MPC-HC
if ($mpchc) {
Write-Host "Installing MPC-HC..."
$latestRelease = Invoke-RestMethod -Uri "https://api.github.com/repos/clsid2/mpc-hc/releases/latest"
$link = $latestRelease.assets | Where-Object { $_.browser_download_url -like "*x64.exe" } | Select-Object -ExpandProperty browser_download_url
& curl.exe -LSs "$link" -o "$tempDir\mpc-hc.exe"
Start-Process -FilePath "$tempDir\mpc-hc.exe" -WindowStyle Hidden -ArgumentList '/VERYSILENT /NORESTART' -Wait 2>&1 | Out-Null
exit
}

# VLC
if ($vlc) {
Write-Host "Installing VLC..."
$baseUrl = "https://get.videolan.org/vlc/last/win64/"
$fileName = $((Invoke-WebRequest -Uri $baseUrl -UseBasicParsing).Links | Where-Object { $_.Href -like 'vlc*.exe' } | Select-Object -First 1 -ExpandProperty Href)
& curl.exe -LSs "$baseUrl$fileName" -o "$tempDir\vlc.exe"
Start-Process -FilePath "$tempDir\vlc.exe" -WindowStyle Hidden -ArgumentList '/S' -Wait 2>&1 | Out-Null
exit
}

# Notepad++
if ($npp) {
Write-Host "Installing Notepad++..."
$latestRelease = Invoke-RestMethod -Uri "https://api.github.com/repos/notepad-plus-plus/notepad-plus-plus/releases/latest"
$link = $latestRelease.assets | Where-Object { $_.browser_download_url -like "*x64.exe" } | Select-Object -ExpandProperty browser_download_url
& curl.exe -LSs "$link" -o "$tempDir\npp.exe"
Start-Process -FilePath "$tempDir\npp.exe" -WindowStyle Hidden -ArgumentList '/S' -Wait 2>&1 | Out-Null
exit
}

# VSCode
if ($vscode) {
Write-Host "Installing VSCode..."
& curl.exe -LSs "https://code.visualstudio.com/sha/download?build=stable&os=win32-x64" -o "$tempDir\vscode.exe"
Start-Process -FilePath "$tempDir\vscode.exe" -WindowStyle Hidden -ArgumentList '/VERYSILENT /NORESTART /MERGETASKS=!runcode' -Wait 2>&1 | Out-Null
exit
}

# VSCodium
if ($vscodium) {
Write-Host "Installing VSCodium..."
$latestRelease = Invoke-RestMethod -Uri "https://api.github.com/repos/VSCodium/vscodium/releases/latest"
$link = $latestRelease.assets | Where-Object { $_.browser_download_url -like "*VSCodiumSetup-x64*" -and $_.browser_download_url -like "*.exe" } | Select-Object -ExpandProperty browser_download_url
& curl.exe -LSs "$link" -o "$tempDir\vscodium.exe"
Start-Process -FilePath "$tempDir\vscodium.exe" -WindowStyle Hidden -ArgumentList '/VERYSILENT /NORESTART /MERGETASKS=!runcode' -Wait 2>&1 | Out-Null
exit
}

####################
## Software ##
####################
Expand Down
Binary file removed src/playbook/Images/mpc-hc.png
Binary file not shown.
Binary file removed src/playbook/Images/mpv.png
Binary file not shown.
Binary file removed src/playbook/Images/npp.png
Binary file not shown.
Binary file removed src/playbook/Images/vlc.png
Binary file not shown.
Binary file removed src/playbook/Images/vscode.png
Binary file not shown.
Binary file removed src/playbook/Images/vscodium.png
Binary file not shown.
54 changes: 0 additions & 54 deletions src/playbook/playbook.conf
Original file line number Diff line number Diff line change
Expand Up @@ -114,59 +114,5 @@
</Options>
<BottomLine Text="Learn more" Link="https://docs.atlasos.net/getting-started/post-installation/software/web-browsers"/>
</RadioImagePage>
<RadioImagePage DefaultOption="player-mpv" Description="Select your preferred media player to install.">
<Options>
<RadioImageOption None="true"/>
<RadioImageOption>
<Text>mpv</Text>
<Name>player-mpv</Name>
<FileName>mpv</FileName>
<GradientTopColor>#4676ed</GradientTopColor>
<GradientBottomColor>#acf5fe</GradientBottomColor>
</RadioImageOption>
<RadioImageOption>
<Text>MPC-HC</Text>
<Name>player-mpchc</Name>
<FileName>mpc-hc</FileName>
<GradientTopColor>#131524</GradientTopColor>
<GradientBottomColor>#3b3e4f</GradientBottomColor>
</RadioImageOption>
<RadioImageOption>
<Text>VLC</Text>
<Name>player-vlc</Name>
<FileName>vlc</FileName>
<GradientTopColor>#e33b2e</GradientTopColor>
<GradientBottomColor>#E38A84</GradientBottomColor>
</RadioImageOption>
</Options>
<BottomLine Text="Learn more" Link="https://docs.atlasos.net/getting-started/post-installation/software/media-playback"/>
</RadioImagePage>
<RadioImagePage DefaultOption="editor-npp" Description="Select your preferred IDE/text editor to install.">
<Options>
<RadioImageOption None="true"/>
<RadioImageOption>
<Text>Notepad++</Text>
<Name>editor-npp</Name>
<FileName>npp</FileName>
<GradientTopColor>#4676ed</GradientTopColor>
<GradientBottomColor>#acf5fe</GradientBottomColor>
</RadioImageOption>
<RadioImageOption>
<Text>Visual Studio Code</Text>
<Name>editor-vscode</Name>
<FileName>VSCode</FileName>
<GradientTopColor>#131524</GradientTopColor>
<GradientBottomColor>#3b3e4f</GradientBottomColor>
</RadioImageOption>
<RadioImageOption>
<Text>VSCodium</Text>
<Name>editor-vscodium</Name>
<FileName>VSCodium</FileName>
<GradientTopColor>#e33b2e</GradientTopColor>
<GradientBottomColor>#E38A84</GradientBottomColor>
</RadioImageOption>
</Options>
<BottomLine Text="Learn more" Link="https://docs.atlasos.net/getting-started/post-installation/software/text-editors"/>
</RadioImagePage>
</FeaturePages>
</Playbook>

0 comments on commit 23a4236

Please sign in to comment.