这是indexloc提供的服务,不要输入任何密码
Skip to content
Closed
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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 45 additions & 25 deletions .github/workflows/debug_build.yml
Original file line number Diff line number Diff line change
@@ -1,45 +1,65 @@
name: Build
name: Build APK

on:
push:
branches:
- master
- x11-client-experimental
paths-ignore:
- "**.md"
- "img/**"
pull_request:
branches:
- master
paths-ignore:
- "**.md"
- "img/**"

jobs:
build:
build_apk:
name: Build APK
runs-on: ubuntu-latest
permissions:
actions: write

steps:
- name: Clone repository
uses: actions/checkout@v3
with:
submodules: recursive

- name: Restore cache
uses: actions/cache@v3
with:
- name: Cancel previous runs
uses: styfle/cancel-workflow-action@0.11.0
with:
access_token: ${{ github.token }}

- name: Clone repository
uses: actions/checkout@v3
with:
submodules: recursive

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: "17"
distribution: "temurin"

- name: Restore cache
uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}

restore-keys: |
${{ runner.os }}-gradle-

- name: Build
run: |
./gradlew assembleDebug
- name: Install libarchive-tools
run: |
sudo apt install -y libarchive-tools
- name: Build companion package
run: |
./build_termux_package
- name: Store generated APK file
uses: actions/upload-artifact@v3
with:
name: termux-x11
path: ./app/build/outputs/apk/debug
- name: Build
run: bash ./gradlew assembleDebug

- name: Install libarchive-tools
run: sudo apt install -y libarchive-tools

- name: Build companion package
run: bash ./build_termux_package

- name: Store generated APK file
uses: actions/upload-artifact@v3
with:
name: termux-x11
path: ./app/build/outputs/apk/debug
7 changes: 7 additions & 0 deletions .github/workflows/gradle-wrapper-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,16 @@ on:
push:
branches:
- master
- x11-client-experimental
paths-ignore:
- "**.md"
- "img/**"
pull_request:
branches:
- master
paths-ignore:
- "**.md"
- "img/**"

jobs:
validation:
Expand Down
57 changes: 39 additions & 18 deletions .github/workflows/run_tests.yml
Original file line number Diff line number Diff line change
@@ -1,38 +1,59 @@
name: Unit tests
name: Unit test

on:
push:
branches:
- master
- x11-client-experimental
paths-ignore:
- "**.md"
- "img/**"
pull_request:
branches:
- master
paths-ignore:
- "**.md"
- "img/**"

jobs:
testing:
unit_test_debug:
name: Run Unit test
runs-on: ubuntu-latest
permissions:
actions: write

steps:
- name: Clone repository
uses: actions/checkout@v3
with:
submodules: recursive

- name: Restore cache
uses: actions/cache@v3
with:
- name: Cancel previous runs
uses: styfle/cancel-workflow-action@0.11.0
with:
access_token: ${{ github.token }}

- name: Clone repository
uses: actions/checkout@v3
with:
submodules: recursive

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: "17"
distribution: "temurin"

- name: Restore cache
uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}

restore-keys: |
${{ runner.os }}-gradle-
- name: Execute tests
run: |
./gradlew test --stacktrace
- name: Android Integration Test
uses: ReactiveCircus/android-emulator-runner@v2.27.0
with:

- name: Execute tests
run: bash ./gradlew test --stacktrace

- name: Android Integration Test
uses: ReactiveCircus/android-emulator-runner@v2.27.0
with:
api-level: 28
script: ./gradlew test
13 changes: 7 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@ Termux:X11 uses [XCB](https://xcb.freedesktop.org/) display protocol.
This repo uses submodules. Use

```
git clone --recurse-submodules https://github.com/termux/termux-x11
git clone --recurse-submodules https://github.com/termux/termux-x11.git
```
or
```
git clone https://github.com/termux/termux-x11
git submodule update --init --recursive
git clone https://github.com/termux/termux-x11.git
cd termux-x11/
git submodule update --init --recursive
```

## How does it work?
Expand Down Expand Up @@ -77,9 +78,9 @@ To work with GUI applications, start Xvfb first.

then you can start your desired graphical application by doing:
```
~ $ Xvfb :1 -ac -screen 0 4096x4096x24 &
~ $ DISPLAY=:1 termux-x11 &
~ $ env DISPLAY=:1 dbus-launch --exit-with-session startxfce4
Xvfb :1 -ac -screen 0 4096x4096x24 &
DISPLAY=:1 termux-x11 &
env DISPLAY=:1 dbus-launch --exit-with-session startxfce4 &
```
You may replace `xfce4-session` if you use other than Xfce

Expand Down