Giter VIP home page Giter VIP logo

creative-builds / wsa-magisk Goto Github PK

View Code? Open in Web Editor NEW
230.0 14.0 128.0 26.91 MB

A custom Windows Subsystem for Android with GApps, Magisk and KernelSU

Home Page: https://github.com/LSPosed/MagiskOnWSALocal

License: GNU Affero General Public License v3.0

Shell 58.32% Python 29.39% PowerShell 11.27% Batchfile 1.02%
windows windows-subsystem-android windows-subsystem-for-android windows-subsystem-linux wsa

wsa-magisk's Introduction

Magisk on WSA (with Google Apps)

Grab the latest release from releases.

  • Extract the package and execute run.bat.
  • Ask your queries in discussion.

⚠️ For fork developers: Please don't build using GitHub Actions, as GitHub will count your forked GitHub Actions usage against this upstream repository, which may cause this upstream repository gets disabled by GitHub staff like MagiskOnWSA because of numerous forks building GitHub Actions, and counting the forks' Action usage against this upstream repository.

Support for generating from these systems

  • Linux (x86_64 or arm64)

    The following dependencies are required:

    DistrOS
    Debian lzip patchelf e2fsprogs python3 aria2 attr unzip sudo whiptail qemu-utils python3-venv python3-pip p7zip-full
    openSUSE Tumbleweed Same as above dialog qemu-tools python3-venvctrl Same as above
    Arch Same as Debian libnewt qemu-img Same as Debian python-pip p7zip

    The python3 library requests is used.

    Python version ≥ 3.7.2.

    • Recommended use

      • Ubuntu (You can use WSL2)

        Ready to use right out of the box.

      • Debian (You can use WSL2)

        Ready to use right out of the box.

      • openSUSE Tumbleweed (You can use WSL2)

        Ready to use right out of the box.

      run.sh will handle all dependencies automatically.

      No need to type any commands.

Features

  • Integrate Magisk and GApps in a few clicks within minutes
  • Keep each build up to date
  • Support both ARM64 and x64
  • Support MindTheGapps
  • Remove Amazon Appstore
  • Fix VPN dialog not showing (use our VpnDialogs app)
  • Add device administration feature
  • Unattended installation
  • Automatically activates developers mode in Windows 11
  • Update to the new version while preserving data with a one-click script
  • Merged all language packs

Text Guide

  1. Star (if you like).

  2. Clone the repo to local:

    git clone https://github.com/creative-builds/WSA-Magisk.git --depth 1
  3. Run cd MagiskOnWSALocal.

  4. Run ./scripts/run.sh.

  5. Select the WSA version and its architecture (mostly x64).

  6. Select the version of Magisk.

  7. Choose which brand of GApps you want to install:

    • MindTheGapps

      There is no other variant we can choose.

  8. Select the root solution (none means no root).

  9. If you are running the script for the first time, it will take some time to complete. After the script completes, two new folders named output and download will be generated in the MagiskOnWSALocal folder. Go to the output folder. While running the ./run.sh script in the step 3, if you selected Yes for Do you want to compress the output? then in output folder you will see a compressed file called WSA-with-magisk-stable-MindTheGapps_2207.40000.8.0_x64_Release-Nightlyor else there will be folder with the WSA-with-magisk-stable-MindTheGapps_2207.40000.8.0_x64_Release-Nightly. If there is a folder open it and skip to step 10. NOTE: The name of compressed file or the folder generated in the output folder may be different for you. It will be dependent on the choices made when executing ./run.sh.

  10. Extract the compressed file and open the folder created after the extraction of the file.

  11. Here look for file Run.bat and run it.

    • If you previously have a MagiskOnWSA installation, it will automatically uninstall the previous one while preserving all user data and install the new one, so don't worry about your data.
    • If you have an official WSA installation, you should uninstall it first. (In case you want to preserve your data, you can backup %LOCALAPPDATA%\Packages\MicrosoftCorporationII.WindowsSubsystemForAndroid_8wekyb3d8bbwe\LocalCache\userdata.vhdx before uninstallation and restore it after installation.)
    • If the popup windows disappear without asking administrative permission and WSA is not installed successfully, you should manually run Install.ps1 as Administrator:
      1. Press Win+x and select Windows Terminal (Admin).
      2. Input cd "{X:\path\to\your\extracted\folder}" and press enter, and remember to replace {X:\path\to\your\extracted\folder} including the {}, for example cd "D:\wsa"
      3. Input PowerShell.exe -ExecutionPolicy Bypass -File .\Install.ps1 and press Enter.
      4. The script will run and WSA will be installed.
      5. If this workaround does not work, your PC is not supported for WSA.
  12. Magisk/Play Store will be launched. Enjoy by installing LSPosed-Zygisk with Zygisk enabled or Riru and LSPosed-Riru.


FAQ

  • Can I delete the installed folder?

    No.

  • How can I update WSA to a newer version?

    1. Update build scripts:

      git pull

      For more usage of git, referred to https://git-scm.com/book

    2. Rerun the script, replace the content of your previous installation and rerun Install.ps1. Don't worry, your data will be preserved.

  • How can I get the logcat from WSA?

    %LOCALAPPDATA%\Packages\MicrosoftCorporationII.WindowsSubsystemForAndroid_8wekyb3d8bbwe\LocalState\diagnostics\logcat

  • How can I update Magisk to a newer version?

    Do the same as updating WSA.

  • How to pass Play Integrity (formerly known as SafetyNet)?

    Like all the other emulators, no way.

  • Virtualization is not enabled?

    Install.ps1 helps you enable it if not enabled. After rebooting, rerun Install.ps1 to install WSA. If it's still not working, you have to enable virtualization in BIOS. That's a long story so ask Google for help.

  • How to remount the system as read-write?

    No way in WSA since it's mounted as read-only by Hyper-V. You can modify the system by making a Magisk module. Or directly modify the system.img. Ask Google for help.

  • I cannot adb connect localhost:58526, what to do?

    Make sure developer mode is enabled. If the issue persists, check the IP address of WSA on the setting page and try adb connect ip:5555.

  • Why the Magisk online module is empty?

    Magisk actively removes the online module repository. You can install the module locally or by adb push module.zip /data/local/tmp and adb shell su -c magisk --install-module /data/local/tmp/module.zip.

  • Can I use Magisk v23.0 stable or a lower version?

    No. Magisk has bugs preventing itself from running on WSA. Magisk v24+ has fixed them. So you must use Magisk v24 or later.

  • How can I get rid of Magisk?

    Choose none as the root solution.

  • How to install custom GApps?

    Tutorial

  • Where can I download MindTheGapps?

    You can download from here MindTheGapps (mirror).

    Note that there is no x86_64 pre-build, so you need to build it by yourself (Repository).

    Or you can download the built package for 12.1 and 13 for x86_64 from this page.

  • Can I switch OpenGApps to MindTheGapps and keep user data in a previous build?

    No. You should wipe data after changing the GApps brand. Otherwise, you will find that the installed GApps are not recognized.

  • WSA with OpenGApps integrated fails to start.

    OpenGApps has not yet released a version built for Android 12L and 13, only built for Android 11, which may not be compatible and thus cause crashes. Consider switching to MindTheGapps.

  • How to install KernelSU?

    Tutorial


Credits

The repository is provided as a utility.

Android is a trademark of Google LLC. Windows is a trademark of Microsoft Corporation.

wsa-magisk's People

Contributors

alex-sandro92 avatar b- avatar bilditup1 avatar calendulish avatar carlgao4 avatar everclearecct avatar faizauthar12 avatar ferferga avatar github-actions[bot] avatar howard20181 avatar humenth avatar kokarare1212 avatar lalishansh avatar mriamnobody avatar okibcn avatar orariley70 avatar pawloland avatar pazhanir avatar rabilrbl avatar ricnava00 avatar s1204it avatar sekibetu avatar sn-o-w avatar soleera avatar someone5678 avatar star-zer0 avatar vvb2060 avatar yeyaowei avatar yujincheng08 avatar zhongfly avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

wsa-magisk's Issues

[Feature Request] Add a non-google play services version

Is your feature request related to a problem?/你的请求是否与某个问题相关?

I'm wanting to test out the Subsystem for Android without the need of Google Play Services, but containing Magisk.

Describe the solution you'd like/描述你想要的解决方案

The releases section should contain a attachment that is just magisk only and no mind-the-gapps

Additional context/其他信息

No response

[Bug] Remove 'Removed' in asset title.

Steps to reproduce

image
All the assets contain Removed at the end which can be confusing

Expected behaviour

Remove the 'Removed' at the end, (if possible)

Actual behaviour

Removed exists...

MagiskOnWSALocal commit full SHA/MagiskOnWSALocal

c9f2a8d

Linux distribution info/Linux

None

Windows version/Windows

No need

Build Parameters

No need

Version requirement

  • I am using latest commit of MagiskOnWSALocal commit

Logs

No need

[Feature Request] Windows 10 Support

Is your feature request related to a problem?

In Github, we have a dll patch to install WSA in Windows 10. Here is the repos of this patch:
https://github.com/cinit/WSAPatch

Describe the solution you'd like

So how about if you update the install.ps1 file to check the Windows version. If the version is 10, copy and paste modifided file to WSA folder then install it.
And can you also add option in Custom Build for people to choose the version for build. Thanks

Additional context

No response

[Feature Request] Codespaces as an alternative to GitHub Actions?

Is your feature request related to a problem?

So this repo keeps getting banned due to Actions usage.

Describe the solution you'd like

I'm not too familiar with all this stuff to be honest. That said, do you think Codespaces might be a less dangerous option to offer for anybody who wants to be rebuilding?

Just curious.

Additional context

I built this: https://github.com/nelsonjchen/op-replay-clipper. I use Codespaces as the platform but I'm interested in hearing your thoughts since I definitely don't want to be angering Github either.

upstream changes causes github actions to fail

Steps to reproduce

build manually or try to merge sync from upstream

Expected behaviour

no errors and github actions to work flawlessly

Actual behaviour

theres an upstream changes into the scripts/build.sh and spellcheck workflow which causes the Sync with upstream
and building to fail with github actions

i recommend fixing some codes in accorfance to
https://www.shellcheck.net/wiki/SC2086
https://www.shellcheck.net/wiki/SC2116

like this line on 844 , 35 on scripts/build.sh

from
echo "artifact=$(echo "$artifact_name")" >> $GITHUB_OUTPUT
to
echo "artifact=$artifact_name" >> "$GITHUB_OUTPUT"

this change seems to fix the issue for merging

from
echo "changes=$(git diff --name-only HEAD origin/main)" >> $GITHUB_OUTPUT
to

echo "changes=$(git diff --name-only HEAD origin/main | tr '\n' ' ' )" >> "$GITHUB_OUTPUT"

MagiskOnWSALocal commit full SHA/MagiskOnWSALocal

f29774d

Linux distribution info/Linux

github actions default

Windows version/Windows

10.0.22621.1344

Build Parameters

n/a

Version requirement

  • I am using latest commit of MagiskOnWSALocal commit

Logs

Run git diff --name-only HEAD origin/main
.github/workflows/shellcheck.yml
scripts/build.sh
scripts/generateGappsLink.py
scripts/generateKernelSULink.py
scripts/getWSAMainVersion.py
scripts/install_deps.sh
scripts/run.sh
Error: Unable to process file command 'output' successfully.
Error: Invalid format 'scripts/build.sh'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.