Skip to content

Commit 831c3a1

Browse files
committed
chore: bump mcpp to 0.0.11 + update README
- .xlings.json: mcpp 0.0.7 → 0.0.11 - CI: xlings 0.4.25 → 0.4.30, mcpp 0.0.11 - README: expand mcpp build/usage instructions
1 parent 8eab0b3 commit 831c3a1

3 files changed

Lines changed: 26 additions & 9 deletions

File tree

.github/workflows/ci.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414

1515
- name: Install xlings
1616
env:
17-
XLINGS_VERSION: 0.4.25
17+
XLINGS_VERSION: 0.4.30
1818
run: |
1919
tarball="xlings-${XLINGS_VERSION}-linux-x86_64.tar.gz"
2020
curl -fsSL -o "/tmp/${tarball}" \
@@ -23,17 +23,17 @@ jobs:
2323
"/tmp/xlings-${XLINGS_VERSION}-linux-x86_64/subos/default/bin/xlings" self install
2424
echo "$HOME/.xlings/subos/current/bin" >> "$GITHUB_PATH"
2525
26-
- name: Install workspace tools (.xlings.json → mcpp 0.0.7)
26+
- name: Install workspace tools (.xlings.json → mcpp 0.0.11)
2727
run: xlings install -y
2828

2929
# Cache mcpp's self-bootstrapped sandbox (musl-gcc + binutils +
3030
# glibc + ninja + patchelf, ~800 MB). Toolchain set is pinned by
31-
# mcpp 0.0.7, so a fixed key suffices.
31+
# mcpp 0.0.11, so a fixed key suffices.
3232
- name: Cache mcpp sandbox
3333
uses: actions/cache@v4
3434
with:
35-
path: ~/.xlings/data/xpkgs/xim-x-mcpp/0.0.7/registry
36-
key: mcpp-sandbox-${{ runner.os }}-mcpp0.0.7
35+
path: ~/.xlings/data/xpkgs/xim-x-mcpp/0.0.11/registry
36+
key: mcpp-sandbox-${{ runner.os }}-mcpp0.0.11
3737

3838
- name: Build with mcpp
3939
run: mcpp build

.xlings.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"workspace": {
3-
"mcpp": { "linux": "0.0.7" }
3+
"mcpp": { "linux": "0.0.11" }
44
}
55
}

README.md

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,14 +112,31 @@ target("mytool")
112112

113113
### mcpp
114114

115-
在项目的 `mcpp.toml` 中声明依赖:
115+
#### 添加依赖
116+
117+
```bash
118+
mcpp add cmdline@0.0.2
119+
```
120+
121+
或在 `mcpp.toml` 中手动添加:
116122

117123
```toml
118124
[dependencies]
119-
"mcpplibs.cmdline" = "^0.0.2"
125+
cmdline = "0.0.2"
126+
```
127+
128+
#### 构建
129+
130+
```bash
131+
mcpp build
120132
```
121133

122-
然后在源码中 `import mcpplibs.cmdline;` 即可使用。
134+
#### 代码示例
135+
136+
```cpp
137+
import mcpplibs.cmdline;
138+
// ... 参见上方"快速开始"
139+
```
123140

124141
## 相关链接
125142

0 commit comments

Comments
 (0)