Commit Graph

16 Commits

Author SHA1 Message Date
Tautik Agrahari
ce89a98b53 fix(bootstrap): warn before sudo and document install steps (#9501)
- new `script/warp_sudo`: echoes each privileged command, prompts
`[y/N]` from `/dev/tty`, shells to real `sudo` on confirm.
`WARP_BOOTSTRAP_YES=1` or non-tty stdin skips.
- `script/bootstrap`: static `--help` install list dropped. `-y`/`--yes`
exports `WARP_BOOTSTRAP_YES=1` for children.
- ten direct `sudo` call-sites in `script/{macos,linux}/bootstrap` +
`script/linux/install_{build,runtime,test}_deps` switched to
`warp_sudo`. windows unchanged.
- `README.md`: short "what `./script/bootstrap` does" subsection
pointing at the platform scripts as the source of truth.

closes #9421.
2026-05-04 16:36:47 -04:00
Andy
14e7216c5e add RedirectionGuard=no to windows-installer.iss (#9863) 2026-05-04 10:51:33 -07:00
Andy
e51bce9ede re-enable AppMutex setting in Inno Setup (#9871)
## Description

Wrapping up the TODO in warpdotdev/warp-internal#24859

This prevents manually running the installer while an existing Warp
installation is running from erroring
2026-05-01 18:54:38 -07:00
Andy
aee0570160 add Microsoft.VisualStudio.2022.BuildTools installation (#9541)
## Description

We have been saying that installing Visual Studio is required to build
Warp. however, the whole thing isn't needed, just the MSVC Build Tools.
That is available through winget and we can easily automate that in the
script.

## Testing

This worked when setting up a dev env on a new Windows device.

---------

Co-authored-by: oz-for-oss[bot] <277970191+oz-for-oss[bot]@users.noreply.github.com>
2026-05-01 13:08:51 -07:00
B
7784428202 Remove stray backticks from Windows installer README code blocks (#9691)
## Description

Fixes a copy-paste hazard in `script/windows/README.md`. Two `iscc` /
`.exe` examples each ended with a trailing `` `. `` inside their ````
```shell ```` fenced blocks:

```diff
 ```shell
-iscc .\script\windows\windows-installer.iss`.
+iscc .\script\windows\windows-installer.iss
 ```
```
```diff
 ```shell
-.\script\windows\Output\Warp-Windows-Setup.exe`.
+.\script\windows\Output\Warp-Windows-Setup.exe
 ```
```

Inside a fenced code block those characters render literally, so anyone
copying the example commands into cmd.exe or PowerShell hits a syntax
error from the trailing `` ` ``. Most likely a leftover from when the
lines were in prose form (inline code closing a sentence) before being
wrapped in code fences.

Verified the pattern is isolated to these two lines: `grep -rn '\`\.$'`
across all repo Markdown files inside ```` ```shell ```` blocks returns
zero other instances.

## Testing

Docs-only change; no test impact. The diff is purely the removal of two
stray characters per line.

## Agent Mode

- [ ] Warp Agent Mode - This PR was created via Warp's AI Agent Mode

Co-authored-by: BennyWaitWhat <BennyWaitWhat@users.noreply.github.com>
2026-05-01 11:14:28 -05:00
Kevin Chevalier
88930cf481 Cache settings schema between Linux builds (#9743)
## Description

**Assumptions**
- The setting schema does not vary between linux builds.
- The separate builds share the same filesystem.

Cache the generated settings schema between Linux builds to avoid
redundant compilations.

During Linux release builds, `prepare_bundled_resources` is invoked
multiple times (once per package format: `.deb`, `.rpm`, AppImage, Arch,
etc.) within the same CI job. Each invocation currently runs `cargo run
--bin generate_settings_schema`, which triggers a full compilation and
execution of the generator binary — even though the output is identical
across formats for the same channel.

This PR adds a `SETTINGS_SCHEMA_CACHE` environment variable to
`prepare_bundled_resources`. When set:
- The **first** invocation generates the schema normally and saves a
copy to the cache path.
- **Subsequent** invocations copy from the cache instead of
regenerating.

The CI workflows (`create_release.yml`) and the Arch Docker action are
updated to set this variable in all Linux packaging jobs.

## Linked Issue

- [ ] The linked issue is labeled `ready-to-spec` or
`ready-to-implement`.
- [ ] Where appropriate, screenshots or a short video of the
implementation are included below (especially for user-visible or UI
changes).

## Testing

- Verified the script logic handles all edge cases: cache not set
(no-op), cache set but file doesn't exist yet (generate + save), cache
set and file exists (copy).
- No user-visible changes; this is a CI-only optimization.

## Agent Mode
- [x] Warp Agent Mode - This PR was created via Warp's AI Agent Mode

Co-Authored-By: Oz <oz-agent@warp.dev>
2026-05-01 10:36:45 -05:00
Kevin Chevalier
f696f5b830 Revert "Fix schema generator binary recompilation during release bundling." (#9676)
Reverts warpdotdev/warp#9632

Will look at in the future. Currently causing dev build issues like
https://github.com/warpdotdev/warp-internal/actions/runs/25187609052/job/73853657131
2026-04-30 16:42:57 -05:00
David Stern
f61ef1dcd9 Fix schema generator binary recompilation during release bundling. (#9632)
## Description
The release bundling workflow runs `prepare_bundled_resources` after the
main `cargo build`, and that script in turn invokes `cargo run --bin
generate_settings_schema`. Until now we passed neither `--features` nor
`--target` to this run, so cargo's resolver-v2 saw a different
per-package feature unification than the main build and recompiled every
dependency whose enabled features differed (`rust-embed` with
`debug-embed`, `warp_core`'s `release_bundle`, sentry, jemalloc, etc.).
This added significant time to release builds and pulled in extra system
dependencies (e.g. protoc) for jobs that should otherwise just be
packaging the prebuilt binary.

There was a secondary correctness issue: the schema generator iterates
settings registered via `inventory::submit!`, and `#[cfg(feature =
\"...\")]`-gated settings were silently omitted from the schema in any
context whose feature set didn't match the main binary.

The fix threads the build's feature set (and target, where applicable)
through to the schema-generator invocation, and makes package selection
explicit with `-p warp`. With matching features and target, cargo reuses
the existing compilation artifacts; with the same feature set, the
generated schema is also faithful to what the bundled binary actually
exposes.

## Testing
Verified `bash -n` syntax for the modified bash scripts and parsed the
modified PowerShell files via `pwsh`. Bundling, schema generation, and
CI behavior will be exercised by this PR's release builds.

## Agent Mode
- [x] Warp Agent Mode - This PR was created via Warp's AI Agent Mode


[Conversation](https://staging.warp.dev/conversation/1bd5574f-df28-4c2e-867d-40d71ed7e827)
2026-04-30 15:57:17 -04:00
Landon
2113a0a3cf Replace deprecated apt-key with gpg --dearmor for gcloud install (#9538)
## Description

Fixes #9534.

`script/linux/install_test_deps:32` registered Google Cloud SDK's apt
signing key via `apt-key`, which was removed from `apt` in 2.9.17
(2024-12) and is no longer present on Ubuntu 25.04+ and
Debian 13+. On those distros `script/linux/bootstrap` failed for any
contributor who didn't already have `gcloud` installed, with a confusing
`sudo: 'apt-key': command not found` / `curl: Failed writing body` pair.

Replaced the `apt-key` invocation with `gpg --dearmor`, which is the
documented replacement and works on every Debian-family release back to
Debian 9 / Ubuntu 16.04 — the same lower bound that the existing
`signed-by=/usr/share/keyrings/cloud.google.gpg` directive on the next
line already imposes. Also switched `curl -f` to `curl -fsSL`, the
standard quiet-but-fail-on-error flag set, and added `--yes` so a stale
keyring left from a partial previous bootstrap is overwritten cleanly.

```diff
-    curl -f https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key --keyring /usr/share/keyrings/cloud.google.gpg add -
+    curl -fsSL https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo gpg --dearmor --yes -o /usr/share/keyrings/cloud.google.gpg
```

This is a strict superset of the previous behavior — it works everywhere
the old command worked and additionally on apt 3.0+ where `apt-key` is
gone.

## Testing

Manually ran the patched line on Ubuntu 25.10 (apt 3.1.6, no `apt-key`
binary): it produces `/usr/share/keyrings/cloud.google.gpg` and the
subsequent `apt-get update` / `apt-get install google-cloud-cli`
succeed. Re-ran a second time to confirm `--yes` overwrites the existing
keyring without prompting. No automated regression test added — this is
a one-line bootstrap script change whose failure mode is environmental
(absence of `apt-key` on the host) and CI runs on a distro where the
bug doesn't reproduce.

## Server API dependencies

No server API dependencies.

## Agent Mode
- [ ] Warp Agent Mode - This PR was created via Warp's AI Agent Mode

CHANGELOG-BUG-FIX: 

Co-Authored-By: Warp <agent@warp.dev>
2026-04-30 13:04:56 -04:00
Landon
e91b5a2192 Add libclang-dev and clang-format to Linux bootstrap deps (#9527)
## Description

Adds `libclang-dev` and `clang-format` to the Debian/Ubuntu package list
installed by `script/linux/install_build_deps` (run via
`script/linux/bootstrap`).

Without these, `script/presubmit` fails on a fresh Linux machine that
only ran `script/linux/bootstrap`:
- `clang-format` is invoked directly by the presubmit's C/C++/Obj-C
format check.
- `libclang-dev` pulls in `libclang-common-*-dev`, which provides
clang's resource-dir builtin headers that bindgen needs when nextest
builds `minimp4-sys` (pulled in via `warpui_core`'s `integration_tests`
feature).

Fixes #9526.

## Testing

Manually verified on a fresh Ubuntu setup that `script/linux/bootstrap`
followed by `script/presubmit` no longer fails on the clang-format check
or the bindgen build for `minimp4-sys`. No automated tests added — this
is a build-deps-only change to a shell script.

## Server API dependencies

N/A — no server API changes.

## Agent Mode
- [ ] Warp Agent Mode - This PR was created via Warp's AI Agent Mode
2026-04-30 13:04:02 -04:00
David Stern
a8f57a8488 Clarify alacritty_terminal origins for some terminal model code. (#9513)
## Description

Explicitly identifies, in source files, which ones were inherited from
Alacritty when Warp was initially built, and separately bundles in the
Alacritty license.
2026-04-29 20:43:07 -05:00
Anshul Garg
184979528c Point stable-skill instructions at resources/bundled/skills/ (#9406)
### Description

The channel-gated skills README and the runtime error message in
\`script/copy_conditional_skills\` both pointed contributors at
\`resources/skills/\` for stable-ready skills, but that directory
doesn't exist in the repo — \`script/prepare_bundled_resources\` copies
the always-bundled skills from \`resources/bundled/\`, so the right
destination is \`resources/bundled/skills/\`.

The result: if anyone bumped into the existing \`stable/\` guard
(\`copy_conditional_skills\` line 39), the printed remediation pointed
them at a path that doesn't exist.

Three updates:
- \`resources/channel-gated-skills/README.md\` — \"place them in the
always-bundled \`resources/skills/\`\" → \`resources/bundled/skills/\`
(in the prose blockquote and in the gating table).
- \`script/copy_conditional_skills\` — header comment + the user-facing
error \`echo\`.

No behavior change in the script itself; only the comment and the error
string contents.

### Testing

Doc/script-comment only — nothing to run. The actual copy logic is
unchanged.

### Server API

No server changes.

### Agent Mode

Not applicable.

### Changelog Entries

None.

Co-authored-by: anshul-garg27 <anshul-garg27@users.noreply.github.com>
2026-04-29 14:15:33 -04:00
Aloke Desai
929944198c Shrink binary size for the standalone oz cli (#9301)
## Description
Reduces the `oz` CLI tarball size by adapting two techniques the WASM
build already uses for the standalone CLI artifact.

**Measured results**:

| Platform | Before (gzipped) | After (gzipped) | Reduction |
|---|---|---|---|
| macOS aarch64 | ~120 MiB | ~48 MiB | **~−60%** |
| Linux x86_64 | 121.5 MiB | ~49 MiB | **~−60%** |

There are two primary changes:
1. No longer bundle any of the async assets into the headless binary
(this drops ~57 MiB of incompressible PNG/JPG bytes from the binary)

2. Introduce a `release-ci` profile that uses `opt-level = s` and `lto =
fat`. This mirrors the release profile we use on wasm. For the CLI
specifically, this should be a no-op for user-perceived latency: `oz
agent run` is wall-clock-dominated by network round-trips to the LLM API
and file I/O, not by CPU-bound inner loops. The 5–15% slowdown that
`-Os` typically incurs on tight numeric loops is invisible next to a
multi-second model response, and a smaller binary actually loads faster
on cold start.


## Agent Mode
- [x] Warp Agent Mode - This PR was created via Warp's AI Agent Mode

## Changelog Entries for Stable

CHANGELOG-OZ: Reduced the `oz` CLI tarball download size by ~60% on both
macOS and Linux.

---------

Co-authored-by: Oz <oz-agent@warp.dev>
2026-04-28 17:20:51 -05:00
David Stern
4e807624c6 Don't let ./script/run fail for external contributors. (#9268)
## Description

Fixes https://github.com/warpdotdev/warp/issues/9266.

We don't want `./script/run` to error out b/c of
`./script/install_channel_config` failing.
2026-04-28 14:11:32 -04:00
David Stern
4a00689af9 Fix CI to work in the warpdotdev/warp repo. (#9226)
## Description

A couple issues that needed fixing:
* Using `--all-features` and `--all-targets` causes us to try to build
the first-party binaries with embedded configuration, which isn't
available from this repository. To unblock CI, we'll only run clippy on
the default feature set for right now.
* Similarly, testing compilation with release configuration was trying
to build the `dev` channel; this switches that over to the `oss`
channel.
2026-04-28 11:34:34 -04:00
David Stern
0dbd3d567a Initial public release of Warp.
Repo-Sync-Origin: warpdotdev/warp-internal@12af1d983b
2026-04-28 08:43:33 -05:00