Skip to content

Commit 7ff76cf

Browse files
committed
Rewrite one-key installer for flavors and add smoke tests
1 parent fc0277a commit 7ff76cf

5 files changed

Lines changed: 669 additions & 110 deletions

File tree

.github/workflows/test.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,17 @@ on:
1515
- "**/*.go"
1616
- "go.mod"
1717
- "go.sum"
18+
- "nt_install.sh"
19+
- "scripts/test_nt_install.sh"
1820
- ".github/workflows/*.yml"
1921
pull_request:
2022
types: [opened, synchronize, reopened]
2123
paths:
2224
- "**/*.go"
2325
- "go.mod"
2426
- "go.sum"
27+
- "nt_install.sh"
28+
- "scripts/test_nt_install.sh"
2529
- ".github/workflows/*.yml"
2630
workflow_dispatch:
2731

@@ -53,6 +57,14 @@ jobs:
5357
sudo go env -w GOTOOLCHAIN=go1.26.0+auto
5458
sudo go test -v -covermode=count -coverprofile='coverage.out' ./...
5559
60+
- name: Smoke test nt_install.sh
61+
if: ${{ matrix.os != 'windows-latest' }}
62+
shell: bash
63+
run: |
64+
bash -n nt_install.sh
65+
sh -n nt_install.sh
66+
bash scripts/test_nt_install.sh
67+
5668
- name: Test with windows
5769
if: ${{ matrix.os == 'windows-latest' }}
5870
run: |

README.md

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,13 +55,30 @@ Please note, there are exceptions to this synchronization. If a version of NTrac
5555

5656
### Automated Install
5757

58-
- Linux
59-
- One-click installation script
58+
- Linux / macOS / BSD
59+
- One-click installation script (Full, default)
6060

6161
```shell
6262
curl -sL https://nxtrace.org/nt | bash
6363
```
6464

65+
- One-click installation script (Tiny)
66+
67+
```shell
68+
curl -sL https://nxtrace.org/nt | bash -s -- --flavor tiny
69+
```
70+
71+
- One-click installation script (NTR)
72+
73+
```shell
74+
curl -sL https://nxtrace.org/nt | bash -s -- --flavor ntr
75+
```
76+
77+
- Installed command names:
78+
- Full: `nexttrace`
79+
- Tiny: `nexttrace-tiny`
80+
- NTR: `ntr`
81+
6582
- Install nxtrace from the APT repository
6683
- Supports AMD64/ARM64 architectures
6784
```shell

README_zh_CN.md

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,23 @@ Document Language: [English](README.md) | 简体中文
5959

6060
### Automated Install
6161

62-
- Linux
63-
- 一键安装脚本
62+
- Linux / macOS / BSD
63+
- 一键安装脚本(完整版,默认)
6464
```shell
6565
curl -sL https://nxtrace.org/nt | bash
6666
```
67+
- 一键安装脚本(Tiny)
68+
```shell
69+
curl -sL https://nxtrace.org/nt | bash -s -- --flavor tiny
70+
```
71+
- 一键安装脚本(NTR)
72+
```shell
73+
curl -sL https://nxtrace.org/nt | bash -s -- --flavor ntr
74+
```
75+
- 安装后的命令名:
76+
- Full:`nexttrace`
77+
- Tiny:`nexttrace-tiny`
78+
- NTR:`ntr`
6779
- 从 nxtrace的APT源安装
6880
- 支持 AMD64/ARM64 架构
6981
```shell

0 commit comments

Comments
 (0)