*actually* allow different forks

This commit is contained in:
beerpsi 2023-12-01 02:18:08 +07:00
parent bd1c461bdc
commit 5cdb7055e5
2 changed files with 6 additions and 5 deletions

View File

@ -1,3 +1,4 @@
$artemis_repo = "%%ARTEMIS_REPO%%"
$artemis_branch = "%%ARTEMIS_BRANCH%%" $artemis_branch = "%%ARTEMIS_BRANCH%%"
$old = Join-Path $(Get-Location) "artemis" $old = Join-Path $(Get-Location) "artemis"
@ -7,7 +8,7 @@ New-Item -ItemType Directory -Path $tmpdir
cd $tmpdir cd $tmpdir
Write-Output "[INFO] Downloading ARTEMiS..." Write-Output "[INFO] Downloading ARTEMiS..."
Invoke-WebRequest "https://gitea.tendokyu.moe/Hay1tsme/artemis/archive/$artemis_branch.zip" -OutFile "artemis-$artemis_branch.zip" Invoke-WebRequest "https://gitea.tendokyu.moe/$artemis_repo/archive/$artemis_branch.zip" -OutFile "artemis-$artemis_branch.zip"
Expand-Archive "artemis-$artemis_branch.zip" Expand-Archive "artemis-$artemis_branch.zip"
Move-Item "artemis-$artemis_branch/artemis" artemis Move-Item "artemis-$artemis_branch/artemis" artemis
Remove-Item -Recurse "artemis-$artemis_branch" Remove-Item -Recurse "artemis-$artemis_branch"

View File

@ -29,8 +29,8 @@ Remove-Item "python-$python_version-embed-amd64.zip"
# -------------------------------------------------------- # --------------------------------------------------------
# Setting up MariaDB # Setting up MariaDB
# -------------------------------------------------------- # --------------------------------------------------------
$mariadb_root_password = (-join ((65..90) + (97..122) | Get-Random -Count 32 | % {[char]$_})) $mariadb_root_password = (-join ((65..90) + (97..122) | Get-Random -Count 32 | ForEach-Object {[char]$_}))
$mariadb_aime_password = (-join ((65..90) + (97..122) | Get-Random -Count 32 | % {[char]$_})) $mariadb_aime_password = (-join ((65..90) + (97..122) | Get-Random -Count 32 | ForEach-Object {[char]$_}))
$mariadb_port = (40000..49151) | Get-Random $mariadb_port = (40000..49151) | Get-Random
Write-Output "[INFO] Downloading MariaDB $mariadb_version..." Write-Output "[INFO] Downloading MariaDB $mariadb_version..."
@ -129,7 +129,7 @@ Copy-Item ../assets/update-artemis.bat .
New-Item scripts -ItemType Directory New-Item scripts -ItemType Directory
Copy-Item ../assets/start.ps1 scripts/ Copy-Item ../assets/start.ps1 scripts/
$update_script = (Get-Content ../assets/update-artemis.ps1) -replace "%%ARTEMIS_BRANCH%%", "$artemis_branch" $update_script = (Get-Content ../assets/update-artemis.ps1) -replace "%%ARTEMIS_REPO%%", "$artemis_repo" -replace "%%ARTEMIS_BRANCH%%", "$artemis_branch"
$update_script | Out-File -Force -FilePath scripts/update-artemis.ps1 $update_script | Out-File -Force -FilePath scripts/update-artemis.ps1
$readme = (Get-Content ../assets/README.txt) -replace "%%MARIADB_ROOT_PASSWORD%%", "$mariadb_root_password" -replace "%%MARIADB_AIME_PASSWORD%%", "$mariadb_aime_password" -replace "%%MARIADB_PORT%%", "$mariadb_port" $readme = (Get-Content ../assets/README.txt) -replace "%%MARIADB_ROOT_PASSWORD%%", "$mariadb_root_password" -replace "%%MARIADB_AIME_PASSWORD%%", "$mariadb_aime_password" -replace "%%MARIADB_PORT%%", "$mariadb_port"
@ -137,4 +137,4 @@ $readme | Out-File -Force -FilePath README.txt
7z a -t7z ../artemis-portable.7z * 7z a -t7z ../artemis-portable.7z *
cd .. Set-Location ..