Repository navigation
140 lines (117 loc) · 4.18 KB
/
Copy pathrelease.yml
File metadata and controls
140 lines (117 loc) · 4.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
name: Release
on:
push:
tags:
- 'v*'
permissions:
contents: write
jobs:
build:
name: Build ${{ matrix.target }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
name: pcode-linux-amd64
- target: x86_64-apple-darwin
os: macos-latest
name: pcode-darwin-amd64
- target: aarch64-apple-darwin
os: macos-latest
name: pcode-darwin-arm64
- target: x86_64-pc-windows-msvc
os: windows-latest
name: pcode-windows-amd64.exe
steps:
- uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
- name: Install dependencies (Ubuntu)
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y musl-tools
- name: Build
run: |
cargo build --release --target ${{ matrix.target }}
- name: Strip binary (Unix)
if: matrix.os != 'windows-latest'
run: |
strip target/${{ matrix.target }}/release/pcode
- name: Rename binary
shell: bash
run: |
if [ "${{ matrix.os }}" = "windows-latest" ]; then
cp target/${{ matrix.target }}/release/pcode.exe ${{ matrix.name }}
else
cp target/${{ matrix.target }}/release/pcode ${{ matrix.name }}
fi
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.name }}
path: ${{ matrix.name }}
release:
name: Create Release
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Download artifacts
uses: actions/download-artifact@v4
with:
path: artifacts
- name: Create checksums
run: |
cd artifacts
for dir in */; do
(cd "$dir" && sha256sum * > ../"${dir%/}.sha256")
done
cd ..
sha256sum artifacts/*.sha256 > checksums.txt
- name: Extract version
id: version
run: echo "version=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- name: Create Release
uses: softprops/action-gh-release@v1
with:
name: pcode ${{ steps.version.outputs.version }}
body: |
# pcode ${{ steps.version.outputs.version }}
Production-grade AI code agent with extreme performance and security.
## Installation
### Linux (x86_64)
```bash
curl -L https://github.com/paiml/pcode/releases/download/${{ steps.version.outputs.version }}/pcode-linux-amd64 -o pcode
chmod +x pcode
sudo mv pcode /usr/local/bin/
```
### macOS (Intel)
```bash
curl -L https://github.com/paiml/pcode/releases/download/${{ steps.version.outputs.version }}/pcode-darwin-amd64 -o pcode
chmod +x pcode
sudo mv pcode /usr/local/bin/
```
### macOS (Apple Silicon)
```bash
curl -L https://github.com/paiml/pcode/releases/download/${{ steps.version.outputs.version }}/pcode-darwin-arm64 -o pcode
chmod +x pcode
sudo mv pcode /usr/local/bin/
```
### Windows
```powershell
Invoke-WebRequest -Uri "https://github.com/paiml/pcode/releases/download/${{ steps.version.outputs.version }}/pcode-windows-amd64.exe" -OutFile "pcode.exe"
```
## Features
- 13 built-in tools including Python and JavaScript execution
- 83 passing tests with 80.9% coverage
- 5.2MB binary size (Linux)
- Sandboxed execution without admin privileges
See [README.md](https://github.com/paiml/pcode#readme) for full documentation.
files: |
artifacts/**/pcode*
checksums.txt