Skip to content
Merged
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
11 changes: 6 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,24 +61,24 @@ jobs:
run: git config --global core.longpaths true
- uses: Swatinem/rust-cache@v2
- run: rustup target add ${{ matrix.target }}
- run: cargo build --profile dist -p goat-code --bin goat --target ${{ matrix.target }}
- run: cargo build --profile dist -p goat-code --bin goat-code --target ${{ matrix.target }}
- run: cargo build --profile dist -p goat-update --bin goat-update --target ${{ matrix.target }}
- name: package unix
if: runner.os != 'Windows'
shell: bash
run: |
mkdir -p dist
cp target/${{ matrix.target }}/dist/goat dist/goat
cp target/${{ matrix.target }}/dist/goat-code dist/goat-code
cp target/${{ matrix.target }}/dist/goat-update dist/goat-update
tar -C dist -czf goat-code-${{ matrix.target }}.tar.gz goat goat-update
tar -C dist -czf goat-code-${{ matrix.target }}.tar.gz goat-code goat-update
- name: package windows
if: runner.os == 'Windows'
shell: pwsh
run: |
New-Item -ItemType Directory -Force dist
Copy-Item target/${{ matrix.target }}/dist/goat.exe dist/goat.exe
Copy-Item target/${{ matrix.target }}/dist/goat-code.exe dist/goat-code.exe
Copy-Item target/${{ matrix.target }}/dist/goat-update.exe dist/goat-update.exe
tar -C dist -czf goat-code-${{ matrix.target }}.tar.gz goat.exe goat-update.exe
tar -C dist -czf goat-code-${{ matrix.target }}.tar.gz goat-code.exe goat-update.exe
- uses: actions/upload-artifact@v4
with:
name: goat-code-${{ matrix.target }}
Expand All @@ -103,3 +103,4 @@ jobs:
files: artifacts/*
prerelease: ${{ needs.validate.outputs.prerelease }}
generate_release_notes: true
tes: true
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ A terminal coding agent, in Rust.
curl -fsSL https://raw.githubusercontent.com/goat-agent/goat-code/main/install.sh | sh
```

Then update in place with `goat update`.
Then update in place with `goat-code update`.

Windows initial install is archive-only for now. Download `goat-code-x86_64-pc-windows-msvc.tar.gz` from the latest release, extract `goat.exe` and `goat-update.exe` into a directory on `PATH`, then update in place with `goat update`.
Windows initial install is archive-only for now. Download `goat-code-x86_64-pc-windows-msvc.tar.gz` from the latest release, extract `goat-code.exe` and `goat-update.exe` into a directory on `PATH`, then update in place with `goat-code update`.

## Build from source

Expand Down
2 changes: 1 addition & 1 deletion crates/goat-code/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ repository.workspace = true
publish = false

[[bin]]
name = "goat"
name = "goat-code"
path = "src/main.rs"

[dependencies]
Expand Down
6 changes: 5 additions & 1 deletion crates/goat-code/src/cli.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
use clap::{Parser, Subcommand};

#[derive(Parser)]
#[command(name = "goat", version, about = "goat — a terminal coding agent")]
#[command(
name = "goat-code",
version,
about = "goat-code — a terminal coding agent"
)]
pub struct Cli {
#[arg(long)]
pub print_log_path: bool,
Expand Down
4 changes: 2 additions & 2 deletions crates/goat-code/src/update.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ async fn drain_daemon(force: bool) -> color_eyre::Result<()> {
.count();
if active > 0 && !force {
return Err(eyre!(
"{active} session(s) are still running in the daemon. Finish them or run `goat daemon stop`, then retry (or use `goat update --force`)."
"{active} session(s) are still running in the daemon. Finish them or run `goat-code daemon stop`, then retry (or use `goat-code update --force`)."
));
}
println!("Stopping the running daemon before update...");
Expand Down Expand Up @@ -229,7 +229,7 @@ fn install_paths() -> color_eyre::Result<InstallPaths> {
.ok_or_else(|| eyre!("could not resolve current executable directory"))?
.to_path_buf();
Ok(InstallPaths {
bin_path: install_dir.join(exe_name("goat")),
bin_path: install_dir.join(exe_name("goat-code")),
helper_path: install_dir.join(exe_name("goat-update")),
install_dir,
})
Expand Down
2 changes: 1 addition & 1 deletion crates/goat-provider-kimi-code/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const ALLOWED_HOST: &str = "api.kimi.com";

const SETUP: &[&str] = &[
"Kimi Code OAuth device-code login.",
"Run `goat provider login kimi-code`, open the URL, and enter the code.",
"Run `goat-code provider login kimi-code`, open the URL, and enter the code.",
];

const CATALOG: &[&str] = &[
Expand Down
4 changes: 2 additions & 2 deletions crates/goat-provider-kimi/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ const ENV_VAR: &str = "MOONSHOT_API_KEY";

const KIMI_SETUP: &[&str] = &[
"Kimi Platform API key provider.",
"For Kimi Code OAuth, use `goat provider login kimi-code`.",
"API-key setup: `goat provider login kimi --key sk-...`.",
"For Kimi Code OAuth, use `goat-code provider login kimi-code`.",
"API-key setup: `goat-code provider login kimi --key sk-...`.",
];

const CATALOG: &[&str] = &[
Expand Down
2 changes: 1 addition & 1 deletion crates/goat-provider-qwen/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const QWEN_DEFAULT_ENDPOINT: &str = "https://dashscope-us.aliyuncs.com/compatibl
const QWEN_SETUP: &[&str] = &[
"Qwen DashScope API-key provider.",
"Default endpoint: https://dashscope-us.aliyuncs.com/compatible-mode/v1",
"Non-US workspaces: `goat provider login qwen --endpoint <url> --key sk-...`.",
"Non-US workspaces: `goat-code provider login qwen --endpoint <url> --key sk-...`.",
"Qwen OAuth enrollment is discontinued upstream.",
];

Expand Down
4 changes: 2 additions & 2 deletions crates/goat-provider-xai/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ const ALLOWED_HOST: &str = "api.x.ai";

const SETUP: &[&str] = &[
"xAI Grok provider (API key or SuperGrok / X Premium+ OAuth).",
"API key: `goat provider login xai --key xai-...` or `XAI_API_KEY`.",
"OAuth: `goat provider login xai` (browser or device code; no API key).",
"API key: `goat-code provider login xai --key xai-...` or `XAI_API_KEY`.",
"OAuth: `goat-code provider login xai` (browser or device code; no API key).",
"OAuth coding models (Composer, Grok Build) use the same api.x.ai Responses API.",
];

Expand Down
2 changes: 1 addition & 1 deletion crates/goat-provider-zai-coding/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const ENV_VAR: &str = "ZAI_CODING_API_KEY";

const ZAI_CODING_SETUP: &[&str] = &[
"Z.AI Coding Plan API-key provider.",
"Use `ZAI_CODING_API_KEY` or `goat provider login zai-coding --key sk-...`.",
"Use `ZAI_CODING_API_KEY` or `goat-code provider login zai-coding --key sk-...`.",
"This is not OAuth and does not reuse the standard `zai` credential.",
];

Expand Down
2 changes: 1 addition & 1 deletion crates/goat-search-provider-brave/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ pub fn metadata() -> SearchProviderMetadata {
default_account: "default",
kind: SearchProviderKind::Brave,
credential: SearchCredentialMetadata::EnvApiKey { env_var: ENV_VAR },
setup: "set BRAVE_API_KEY or run `goat search login brave --key <key>`",
setup: "set BRAVE_API_KEY or run `goat-code search login brave --key <key>`",
builtins: &[],
}
}
Expand Down
2 changes: 1 addition & 1 deletion crates/goat-search-provider-searxng/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ pub fn metadata() -> SearchProviderMetadata {
default_account: "default",
kind: SearchProviderKind::Searxng,
credential: SearchCredentialMetadata::None,
setup: "run `goat search login searxng --endpoint <url>`",
setup: "run `goat-code search login searxng --endpoint <url>`",
builtins: &[],
}
}
Expand Down
2 changes: 1 addition & 1 deletion crates/goat-search-provider-tavily/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ pub fn metadata() -> SearchProviderMetadata {
default_account: "default",
kind: SearchProviderKind::Tavily,
credential: SearchCredentialMetadata::EnvApiKey { env_var: ENV_VAR },
setup: "set TAVILY_API_KEY or run `goat search login tavily --key <key>`",
setup: "set TAVILY_API_KEY or run `goat-code search login tavily --key <key>`",
builtins: &[],
}
}
Expand Down
2 changes: 1 addition & 1 deletion crates/goat-update/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ fn apply(args: &ApplyArgs) -> color_eyre::Result<()> {
)
})?;

let staged_bin = args.staged_dir.join(exe_name("goat"));
let staged_bin = args.staged_dir.join(exe_name("goat-code"));
let staged_helper = args.staged_dir.join(exe_name("goat-update"));
require_file(&staged_bin)?;
require_file(&staged_helper)?;
Expand Down
6 changes: 3 additions & 3 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,8 @@ if ! verify; then
fi
mkdir -p "$tmp/extract"
tar -xzf "$tmp/$archive" -C "$tmp/extract"
test -f "$tmp/extract/goat"
test -f "$tmp/extract/goat-code"
test -f "$tmp/extract/goat-update"
$install_cmd -m 755 "$tmp/extract/goat" "$install_dir/goat"
$install_cmd -m 755 "$tmp/extract/goat-code" "$install_dir/goat-code"
$install_cmd -m 755 "$tmp/extract/goat-update" "$install_dir/goat-update"
printf "%bgoat-code%b installed to %s\n" "$purple" "$reset" "$install_dir/goat"
printf "%bgoat-code%b installed to %s\n" "$purple" "$reset" "$install_dir/goat-code"
Loading