Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .github/workflows/native-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ jobs:
cache: npm
- name: Install dependencies
run: npm ci --no-audit --no-fund
- name: Install Alpine runtime build tools
- name: Install Ubuntu runtime build tools
run: brew install meson ninja llvm lld
- name: Prepare local iOS configuration
run: cp platforms/ios/Config.xcconfig.example platforms/ios/Config.xcconfig
Expand Down
33 changes: 28 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,11 @@ cd Acode
# Install dependencies
npm ci

# Allow the install scripts npm blocks by default (builds the local
# @codemirror/lsp-client, the @parcel/watcher native module, and core-js)
npm install-scripts approve codemirror-lsp-client @parcel/watcher core-js core-js-pure
npm ci

# Build the APK
npm run build -- dev apk
```
Expand All @@ -130,6 +135,10 @@ The APK will be at: `platforms/android/app/build/outputs/apk/<edition>/debug/app

> [!NOTE]
> `@codemirror/lsp-client` comes from the `codemirror-lsp-client` git submodule and is installed as a local `file:` dependency, so initialize the submodule before running `npm ci` — see [Troubleshooting](#-troubleshooting).
>
> npm's `allowScripts` feature blocks the dependency's `prepare` script, which
> generates its `dist/index.js` entry point. Approve the scripts before
> installing — see [Troubleshooting](#-troubleshooting).

## iOS development (port in progress)

Expand Down Expand Up @@ -342,7 +351,8 @@ their file URIs; parsing them as URL text loses literal filename characters.

- `platforms/android/app/src/main/java`: Acode runtime and shared native services.
- `platforms/android/app/src/free`: advertising implementation and metadata.
- `platforms/android/app/src/store`: billing and proot assets, excluded by `fdroid`.
- `platforms/android/app/src/store`: billing, the AXS binary and sandbox rootfs assets, excluded by `fdroid`.
- `platforms/android/proot`: PRoot and its loaders, compiled from the in-tree C sources with the NDK for every flavor.
- `src/native`: typed native APIs imported by `src/native/index.ts`; `bridge(service)` binds promise-based actions to the shared transport.
- `src/platforms/android` and `src/platforms/ios`: platform transports using the shared callback and binary protocol.
- `platforms/ios`: iOS app, with the template's runtime in `runner` and native services in `runner/lib`. Simulator tests and native dependencies remain alongside the app. See the [port checklist](docs/ios-port.md) for remaining work.
Expand Down Expand Up @@ -371,7 +381,7 @@ Gradle only compiles native source and packages the compiled web assets; no Java
Paid builds exclude the AdMob native sources, Google ads/consent SDKs, manifest entries,
and JavaScript bridge. The editor uses small inactive ads APIs in paid builds, so
AdMob initialization, consent and rewarded-ad implementation are not bundled either.
Shared billing and proot remain available unless `fdroid` is requested.
Shared billing remains available unless `fdroid` is requested; PRoot is compiled from source for every flavor.

```bash
npm run build -- dev apk
Expand Down Expand Up @@ -402,6 +412,19 @@ git submodule update --init --recursive
npm ci
```

### Blocked install scripts (`Module not found: Can't resolve '@codemirror/lsp-client'`)

npm's `allowScripts` security feature blocks install scripts by default. For this
project that includes the `prepare` script of the local `@codemirror/lsp-client`
dependency, which generates its `dist/index.js` entry point. If the build fails
with a missing `@codemirror/lsp-client` module (or a missing `@parcel/watcher`
native module), approve the scripts and reinstall:

```bash
npm install-scripts approve codemirror-lsp-client @parcel/watcher core-js core-js-pure
npm ci
```

## 📝 Contribution Guidelines

### Before Submitting a PR
Expand Down Expand Up @@ -489,8 +512,8 @@ To create plugins for Acode:
- [Plugin Starter Repository](https://github.com/Acode-Foundation/acode-plugin)
- [Plugin Documentation](https://docs.acode.app/)

### iOS Alpine terminal
### iOS Ubuntu terminal

Install `brew install meson ninja llvm lld` on an Apple Silicon Mac before building iOS. The normal scripts and direct Xcode builds compile the vendored runtime automatically. `Config.xcconfig` remains limited to ignored local signing information. See [Alpine runtime documentation](platforms/ios/Alpine/README.md) for source revisions, local adaptations, licensing, filesystem layout, and compatibility limits.
Install `brew install meson ninja llvm lld` on an Apple Silicon Mac before building iOS. The normal scripts and direct Xcode builds compile the vendored runtime automatically. `Config.xcconfig` remains limited to ignored local signing information. See [Ubuntu runtime documentation](platforms/ios/Ubuntu/README.md) for source revisions, local adaptations, licensing, filesystem layout, and compatibility limits.

The `AlpineTerminalTests`, `AlpineInteractionTests`, `AlpinePackageTests`, and `AlpineLspTests` suites exercise the real WebView bridge, installation, filesystem editing, backup/restore, interactive tabs, Node/npm, and the existing JSON language server. Installation and package tests require access to Alpine and npm repositories. Run them on a dedicated simulator because they install packages and restore its terminal filesystem. Keep physical-device performance and background validation separate from simulator results.
The `UbuntuTerminalTests`, `UbuntuInteractionTests`, `UbuntuPackageTests`, and `UbuntuLspTests` suites exercise the real WebView bridge, installation, filesystem editing, backup/restore, interactive tabs, Node/npm, and the existing JSON language server. Installation and package tests require access to the Ubuntu, NodeSource and npm repositories. Run them on a dedicated simulator because they install packages and restore its terminal filesystem. Keep physical-device performance and background validation separate from simulator results.
10 changes: 5 additions & 5 deletions docs/ios-port.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,14 @@ Android intents/package launching, APK updates, all-files access permissions
and Android battery controls remain platform exclusions. The main menu offers
Exit on iOS through `exit(0)`; Apple discourages programmatic termination, so
App Review may flag it.
Local terminals and native language-server processes use the ARM64 Alpine
runtime described in [platforms/ios/Alpine/README.md](../platforms/ios/Alpine/README.md).
It preserves Acode's terminal UI, AXS protocol and shell initialization script;
Local terminals and native language-server processes use the ARM64 Ubuntu
runtime described in [platforms/ios/Ubuntu/README.md](../platforms/ios/Ubuntu/README.md).
It preserves Acode's terminal UI, AXS protocol and shell initialization scripts;
Linux package compatibility is bounded by the emulator, Node JIT restrictions,
and iOS process lifetime. Browser-based and remote language servers remain available.

The native registration audit matches 22 of Android's 23 services to iOS services.
`Executor` and `BackgroundExecutor` now execute inside Alpine. `CrashHandler`
`Executor` and `BackgroundExecutor` now execute inside Ubuntu. `CrashHandler`
only installs Android's uncaught-exception handler and starts its crash activity,
with no public bridge actions. Launcher-shortcut, package-launch and
storage-manager controls remain gated in commands, menus and settings. Of the
Expand Down Expand Up @@ -208,7 +208,7 @@ flags; 19 affected native checks pass per edition, with the final six startup/ed
checks also verifying directory type errors. Incoming share tabs retain Android's
temporary-session behavior. Other share destinations, third-party providers,
iCloud and physical-device grants remain unverified. The file browser omits
unavailable Android storage roots on iOS. Terminal Public is shared with Alpine. Acode's Documents
unavailable Android storage roots on iOS. Terminal Public is shared with Ubuntu. Acode's Documents
folder opens directly; a simulator test browses it and reads a selected file
through the shared filesystem API.

Expand Down
2 changes: 1 addition & 1 deletion fastlane/metadata/android/en-US/full_description.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Acode is an open-source code editor and web IDE for Android. Edit projects, mana

LINUX TERMINAL

Acode includes an Alpine Linux terminal powered by proot, with no root required. Use apk to install supported command-line packages, keep multiple terminal tabs, customize your shell, and back up or restore your terminal setup.
Acode includes an Ubuntu Linux terminal powered by proot, with no root required. Use apt to install supported command-line packages, keep multiple terminal tabs, customize your shell, and back up or restore your terminal setup.

AI CODING SUPPORT

Expand Down
12 changes: 0 additions & 12 deletions gradle/gradle-daemon-jvm.properties

This file was deleted.

1 change: 1 addition & 0 deletions licenses/NOTICE
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
Native JavaScript helpers in src/native/{argscheck,base64,builder,channel,originalSymbols,statusbar,utils}.js are adapted from Apache Cordova JS under Apache-2.0. See native-runtime-LICENSE and native-runtime-NOTICE.
Native Android HTTP code is adapted from cordova-plugin-advanced-http; see advanced-http-LICENSE and native-provenance.json.
The Android PRoot compatibility layer is compiled from the in-tree sources under platforms/android/proot (GPL-2.0-or-later) and bundles Samba talloc (LGPL-3.0-or-later); see proot-LICENSE and talloc-LICENSE.
4 changes: 3 additions & 1 deletion licenses/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,6 @@ renamed to match their current source locations.

The HTTP MIT license is preserved from the [upstream license](https://github.com/silkimen/cordova-plugin-advanced-http/blob/master/LICENSE).

The iOS Alpine runtime has separate GPL licensing and retained upstream sources. See [the runtime provenance](../platforms/ios/Alpine/README.md) and its GPL and libarchive license texts.
The iOS Ubuntu runtime has separate GPL licensing and retained upstream sources. See [the runtime provenance](../platforms/ios/Ubuntu/README.md) and its GPL and libarchive license texts.

The Android PRoot compatibility layer is compiled from the in-tree sources under [`platforms/android/proot`](../platforms/android/proot/README.md). PRoot is GPL-2.0-or-later and the bundled Samba talloc is LGPL-3.0-or-later; see [proot-LICENSE](proot-LICENSE) and [talloc-LICENSE](talloc-LICENSE).
Loading
Loading