Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run.sh not working. #1

Closed
D4rkov opened this issue Aug 14, 2022 · 3 comments
Closed

Run.sh not working. #1

D4rkov opened this issue Aug 14, 2022 · 3 comments

Comments

@D4rkov
Copy link

D4rkov commented Aug 14, 2022

ARCH=run.sh: line 6: whiptail: command not found
x64
RELEASE_TYPE=run.sh: line 6: whiptail: command not found
retail
MAGISK_VER=run.sh: line 6: whiptail: command not found
stable
GAPPS_VARIANT=
REMOVE_AMAZON=remove
ROOT_SOL=run.sh: line 6: whiptail: command not found
magisk
Download WSA
Traceback (most recent call last):
  File "C:\Users\Darkov\OneDrive\Documents\Personal\Windows\MagiskOnWSALocal\scripts\downloadWSA.py", line 5, in <module>
    import requests
ModuleNotFoundError: No module named 'requests'
extractWSA
Traceback (most recent call last):
  File "C:\Users\Darkov\OneDrive\Documents\Personal\Windows\MagiskOnWSALocal\scripts\extractWSA.py", line 5, in <module>
    import requests
ModuleNotFoundError: No module named 'requests'
Download Magisk
Traceback (most recent call last):
  File "C:\Users\Darkov\OneDrive\Documents\Personal\Windows\MagiskOnWSALocal\scripts\downloadMagisk.py", line 9, in <module>
    import requests
ModuleNotFoundError: No module named 'requests'
run.sh: line 120: [: !=: unary operator expected
Expand images
run.sh: line 138: e2fsck: command not found
du: cannot access '../workdir/wsa/run.sh:': No such file or directory
du: cannot access 'x64/system_ext.img': No such file or directory
run.sh: line 139: 8
8
8
8
8
8 + 20000: syntax error in expression (error token is "8
8
8
8
8 + 20000")
run.sh: line 143: resize2fs: command not found
run.sh: line 145: e2fsck: command not found
du: cannot access '../workdir/wsa/run.sh:': No such file or directory
du: cannot access 'x64/product.img': No such file or directory
run.sh: line 146: 8
8
8
8
8
8 + 20000: syntax error in expression (error token is "8
8
8
8
8 + 20000")
run.sh: line 150: resize2fs: command not found
run.sh: line 152: e2fsck: command not found
du: cannot access '../workdir/wsa/run.sh:': No such file or directory
du: cannot access 'x64/system.img': No such file or directory
run.sh: line 153: 8
8
8
8
8
8 + 20000: syntax error in expression (error token is "8
8
8
8
8 + 20000")
run.sh: line 166: resize2fs: command not found
run.sh: line 168: e2fsck: command not found
du: cannot access '../workdir/wsa/run.sh:': No such file or directory
du: cannot access 'x64/vendor.img': No such file or directory
run.sh: line 169: 8
8
8
8
8
8 + 20000: syntax error in expression (error token is "8
8
8
8
8 + 20000")
run.sh: line 170: resize2fs: command not found
Mount images
run.sh: line 174: sudo: command not found
run.sh: line 175: sudo: command not found
run.sh: line 176: sudo: command not found
run.sh: line 177: sudo: command not found
run.sh: line 178: sudo: command not found
Remove Amazon AppStore
run.sh: line 182: sudo: command not found
find: ‘../workdir/system/product/etc/permissions’: No such file or directory
find: ‘../workdir/system/product/etc/sysconfig’: No such file or directory
find: ‘../workdir/system/product/framework’: No such file or directory
find: ‘../workdir/system/product/priv-app’: No such file or directory
run.sh: line 185: [: too many arguments
run.sh: line 185: [: too many arguments
Merge Language Resources
cp: target '../workdir/wsa/pri/en-us.pri' is not a directory
cp: target '../workdir/wsa/xml/en-us.xml' is not a directory
tee: ../workdir/wsa/priconfig.xml: No such file or directory
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<resources targetOsVersion="10.0.0" majorVersion="1">
<index root="\" startIndexAt="\">
    <indexer-config type="folder" foldernameAsQualifier="true" filenameAsQualifier="true" qualifierDelimiter="."/>
    <indexer-config type="PRI"/>
</index>
</resources>
run.sh: line 284: wine64: command not found
cat: '../workdir/wsa/xml/*': No such file or directory
sed: can't read ../workdir/wsa/run.sh:: No such file or directory
sed: can't read x64/AppxManifest.xml: No such file or directory
Add extra packages
run.sh: line 288: sudo: command not found
run.sh: line 289: sudo: command not found
run.sh: line 290: sudo: command not found
run.sh: line 291: sudo: command not found
run.sh: line 293: [: !=: unary operator expected
run.sh: line 361: [: !=: unary operator expected
Umount images
run.sh: line 368: sudo: command not found
run.sh: line 369: sudo: command not found
run.sh: line 370: sudo: command not found
run.sh: line 371: sudo: command not found
Shrink images
run.sh: line 374: e2fsck: command not found
run.sh: line 375: resize2fs: command not found
run.sh: line 376: e2fsck: command not found
run.sh: line 377: resize2fs: command not found
run.sh: line 378: e2fsck: command not found
run.sh: line 379: resize2fs: command not found
run.sh: line 380: e2fsck: command not found
run.sh: line 381: resize2fs: command not found
Remove signature and add scripts
cp: target 'x64' is not a directory
ls: cannot access '../workdir/wsa/run.sh:': No such file or directory
ls: cannot access 'line': No such file or directory
ls: cannot access '6:': No such file or directory
ls: cannot access 'whiptail:': No such file or directory
ls: cannot access 'command': No such file or directory
ls: cannot access 'not': No such file or directory
ls: cannot access 'found': No such file or directory
ls: cannot access 'x64': No such file or directory
tee: '../workdir/wsa/run.sh:': No such file or directory
tee: x64/Install.ps1: No such file or directory
# Automated Install script by Mioki
# https://github.com/okibcn
function Test-Administrator {
    [OutputType([bool])]
    param()
    process {
        [Security.Principal.WindowsPrincipal]$user = [Security.Principal.WindowsIdentity]::GetCurrent();
        return $user.IsInRole([Security.Principal.WindowsBuiltinRole]::Administrator);
    }
}

function Finish {
    Clear-Host
    Start-Process "wsa://com.topjohnwu.magisk"
    Start-Process "wsa://com.android.vending"
}

if (-not (Test-Administrator)) {
    Set-ExecutionPolicy -Scope CurrentUser -ExecutionPolicy Bypass -Force
    $proc = Start-Process -PassThru -WindowStyle Hidden -Verb RunAs powershell.exe -Args "-executionpolicy bypass -command Set-Location '$PSScriptRoot'; &'$PSCommandPath' EVAL"
    $proc.WaitForExit()
    if ($proc.ExitCode -ne 0) {
        Clear-Host
        Write-Warning "Failed to launch start as Administrator`r`nPress any key to exit"
        $null = $Host.UI.RawUI.ReadKey('NoEcho,IncludeKeyDown');
    }
    exit
}
elseif (($args.Count -eq 1) -and ($args[0] -eq "EVAL")) {
    Start-Process powershell.exe -Args "-executionpolicy bypass -command Set-Location '$PSScriptRoot'; &'$PSCommandPath'"
    exit
}

if (((Test-Path -Path ) -eq $false).Count) {
    Write-Error "Some files are missing in the zip. Please try to download it again from the browser downloader, or try to run the workflow again. Press any key to exist"
    $null = $Host.UI.RawUI.ReadKey('NoEcho,IncludeKeyDown')
    exit 1
}

reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\AppModelUnlock" /t REG_DWORD /f /v "AllowDevelopmentWithoutDevLicense" /d "1"

$VMP = Get-WindowsOptionalFeature -Online -FeatureName 'VirtualMachinePlatform'
if ($VMP.State -ne "Enabled") {
    Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName 'VirtualMachinePlatform'
    Clear-Host
    Write-Warning "Need restart to enable virtual machine platform`r`nPress y to restart or press any key to exit"
    $key = $Host.UI.RawUI.ReadKey('NoEcho,IncludeKeyDown')
    If ("y" -eq $key.Character) {
        Restart-Computer -Confirm
    }
    Else {
        exit 1
    }
}

Add-AppxPackage -ForceApplicationShutdown -ForceUpdateFromAnyVersion -Path vclibs.appx
Add-AppxPackage -ForceApplicationShutdown -ForceUpdateFromAnyVersion -Path xaml.appx

$Installed = $null
$Installed = Get-AppxPackage -Name 'MicrosoftCorporationII.WindowsSubsystemForAndroid'

If (($null -ne $Installed) -and (-not ($Installed.IsDevelopmentMode))) {
    Clear-Host
    Write-Warning "There is already one installed WSA. Please uninstall it first.`r`nPress y to uninstall existing WSA or press any key to exit"
    $key = $Host.UI.RawUI.ReadKey('NoEcho,IncludeKeyDown')
    If ("y" -eq $key.Character) {
        Remove-AppxPackage -Package $Installed.PackageFullName
    }
    Else {
        exit 1
    }
}
Clear-Host
Write-Host "Installing MagiskOnWSA..."
Stop-Process -Name "wsaclient" -ErrorAction "silentlycontinue"
Add-AppxPackage -ForceApplicationShutdown -ForceUpdateFromAnyVersion -Register .\AppxManifest.xml
if ($?) {
    Finish
}
Elseif ($null -ne $Installed) {
    Clear-Host
    Write-Host "Failed to update, try to uninstall existing installation while preserving userdata..."
    Remove-AppxPackage -PreserveApplicationData -Package $Installed.PackageFullName
    Add-AppxPackage -ForceApplicationShutdown -ForceUpdateFromAnyVersion -Register .\AppxManifest.xml
    if ($?) {
        Finish
    }
}
Write-Host "All Done`r`nPress any key to exit"
$null = $Host.UI.RawUI.ReadKey('NoEcho,IncludeKeyDown')
Generate info
WSA-with-run.sh: line 6: whiptail: command not found
magisk-NoGApps_run.sh: line 6: whiptail: command not found
x64
cat: ../workdir/ENV: No such file or directory
mv: target '../output' is not a directory
@D4rkov D4rkov changed the title Wait, is this for linux only? Run.sh not working, Aug 14, 2022
@D4rkov D4rkov changed the title Run.sh not working, Run.sh not working. Aug 14, 2022
@Howard20181
Copy link
Member

Work in Ubuntu, you can use WSL2.

@D4rkov
Copy link
Author

D4rkov commented Aug 14, 2022

Work in Ubuntu, you can use WSL2.

How do I get it from WSL to my windows?
Ah, found it.

torlmen pushed a commit to torlmen/MagiskOnWSALocal that referenced this issue Aug 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants