Prerequisites

Installation Steps

  1. Install Termux: Download and install Termux from the Google Play Store or F-Droid.
  2. Update and Upgrade Packages:
    pkg update && pkg upgrade -y
    pkg install proot-distro -y
  3. Install Arch Linux:
    proot-distro install archlinux
  4. Login into Arch Linux:
    proot-distro login archlinux
  5. Install Git, OpenSSH, and Base-devel:
    pacman -Syu base-devel git openssh
  6. Download Visual Studio Code CLI:

    For 64-bit devices:

    curl -L https://update.code.visualstudio.com/latest/cli-linux-arm64/stable | bsdtar -xf - -C /usr/local/bin

    For 32-bit devices:

    curl -L https://update.code.visualstudio.com/latest/cli-linux-armhf/stable | bsdtar -xf - -C /usr/local/bin
  7. Run Visual Studio Code (Online Version):
    code tunnel

    Advantages: Accessible from anywhere.

    Disadvantages: Slow and highly dependent on GitHub and Microsoft authentication.

  8. Run Visual Studio Code (Offline Version):
    code serve-web --host 127.0.0.1

    Advantages: Fast and doesn't require any authentication.

    Disadvantages: Runs on localhost and isn't accessible on remote devices, only on the device where the server is started.

Screenshot of Visual Studio Code running on Android