update README for release

This commit is contained in:
Mitchell Hashimoto
2024-12-21 12:49:59 -08:00
parent a74b555c42
commit f2d4170322
2 changed files with 19 additions and 720 deletions

632
README.md
View File

@ -9,29 +9,29 @@
<br /> <br />
<a href="#about">About</a> <a href="#about">About</a>
· ·
<a href="#download">Download</a> <a href="https://ghostty.org/download">Download</a>
· ·
<a href="#roadmap-and-status">Roadmap</a> <a href="https://ghostty.org/docs">Documentation</a>
· ·
<a href="#developing-ghostty">Developing</a> <a href="#developing-ghostty">Developing</a>
</p> </p>
<p align="center">
<a href="https://github.com/ghostty-org/ghostty/blob/main/README_TESTERS.md"><b>Testers! Read This Too!</b></a>
</p>
</p> </p>
## About ## About
Ghostty is a cross-platform, GPU-accelerated terminal emulator that aims to Ghostty is a terminal emulator that differentiates itself by being
push the boundaries of what is possible with a terminal emulator by exposing fast, feature-rich, and native. While there are many excellent terminal
modern, opt-in features that enable CLI tool developers to build more feature emulators available, they all force you to choose between speed,
rich, interactive applications. features, or native UIs. Ghostty provides all three.
There are a number of excellent terminal emulator options that exist In all categories, I am not trying to claim that Ghostty is the
today. The unique goal of Ghostty is to have a platform for experimenting best (i.e. the fastest, most feature-rich, or most native). But
with modern, optional, non-standards-compliant features to enhance the Ghostty is competitive in all three categories and Ghostty
capabilities of CLI applications. We aim to be the best in this category, doesn't make you choose between them.
and competitive in the rest.
Ghostty also intends to push the boundaries of what is possible with a
terminal emulator by exposing modern, opt-in features that enable CLI tool
developers to build more feature rich, interactive applications.
While aiming for this ambitious goal, our first step is to make Ghostty While aiming for this ambitious goal, our first step is to make Ghostty
one of the best fully standards compliant terminal emulator, remaining one of the best fully standards compliant terminal emulator, remaining
@ -39,338 +39,11 @@ compatible with all existing shells and software while supporting all of
the latest terminal innovations in the ecosystem. You can use Ghostty the latest terminal innovations in the ecosystem. You can use Ghostty
as a drop-in replacement for your existing terminal emulator. as a drop-in replacement for your existing terminal emulator.
**Project Status:** Ghostty is still in beta but implements most of the For more details, see [About Ghostty](https://ghostty.org/docs/about).
features you'd expect for a daily driver. We currently have hundreds of active
beta users using Ghostty as their primary terminal. See more in
[Roadmap and Status](#roadmap-and-status).
## Download ## Download
| Platform / Package | Links | Notes | See the [download page](https://ghostty.org/download) on the Ghostty website.
| ------------------ | -------------------------------------------------------------------------- | -------------------------- |
| macOS | [Tip ("Nightly")](https://github.com/ghostty-org/ghostty/releases/tag/tip) | MacOS 13+ Universal Binary |
| Linux | [Build from Source](#developing-ghostty) | |
| Linux (NixOS/Nix) | [Use the Flake](#nix-package) | |
| Linux (Arch) | [Use the AUR package](https://aur.archlinux.org/packages/ghostty-git) | |
| Windows | [Build from Source](#developing-ghostty) | [Notes](#windows-notes) |
### Configuration
To configure Ghostty, you must use a configuration file. GUI-based configuration
is on the roadmap but not yet supported. In the meantime, there is a
[community-built webtool](https://ghostty.zerebos.com/) that you can use to help
generate and preview your configuration. The configuration file must be
placed at `$XDG_CONFIG_HOME/ghostty/config`, which defaults to
`~/.config/ghostty/config` if the [XDG environment is not set](https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html).
The file format is documented below as an example:
```ini
# The syntax is "key = value". The whitespace around the equals doesn't matter.
background = 282c34
foreground= ffffff
# Comments start with a `#` and are only valid on their own line.
# Blank lines are ignored!
keybind = ctrl+z=close_surface
keybind = ctrl+d=new_split:right
# Empty values reset the configuration to the default value
font-family =
# Colors can be changed by setting the 16 colors of `palette`, which each color
# being defined as regular and bold.
#
# black
palette = 0=#1d2021
palette = 8=#7c6f64
# red
palette = 1=#cc241d
palette = 9=#fb4934
# green
palette = 2=#98971a
palette = 10=#b8bb26
# yellow
palette = 3=#d79921
palette = 11=#fabd2f
# blue
palette = 4=#458588
palette = 12=#83a598
# purple
palette = 5=#b16286
palette = 13=#d3869b
# aqua
palette = 6=#689d6a
palette = 14=#8ec07c
# white
palette = 7=#a89984
palette = 15=#fbf1c7
```
#### Configuration Documentation
There are multiple places to find documentation on the configuration options.
All locations are identical (they're all generated from the same source):
1. There are HTML and Markdown formatted docs in the
`$prefix/share/ghostty/docs` directory. This directory is created
when you build or install Ghostty. The `$prefix` is `zig-out` if you're
building from source (or the specified `--prefix` flag). On macOS,
`$prefix` is the `Contents/Resources` subdirectory of the `.app` bundle.
2. There are man pages in the `$prefix/share/man` directory. This directory
is created when you build or install Ghostty.
3. In the CLI, you can run `ghostty +show-config --default --docs`.
Note that this will output the full default configuration with docs to
stdout, so you may want to pipe that through a pager, an editor, etc.
4. In the source code, you can find the configuration structure in the
[Config structure](https://github.com/ghostty-org/ghostty/blob/main/src/config/Config.zig).
The available keys are the keys verbatim, and their possible values are typically
documented in the comments.
5. Not documentation per se, but you can search for the
[public config files](https://github.com/search?q=path%3Aghostty%2Fconfig&type=code)
of many Ghostty users for examples and inspiration.
> [!NOTE]
>
> You may see strange looking blank configurations like `font-family =`. This
> is a valid syntax to specify the default behavior (no value). The
> `+show-config` outputs it so it's clear that key is defaulting and also
> to have something to attach the doc comment to.
> [!NOTE]
>
> Configuration can be reloaded on the fly with the `reload_config`
> command. Not all configuration options can change without restarting Ghostty.
> Any options that require a restart should be documented.
#### Configuration Errors
If your configuration file has any errors, Ghostty does its best to ignore
them and move on. Configuration errors currently show up in the log. The
log is written directly to stderr, so it is up to you to figure out how to
access that for your system (for now). On macOS, you can also use the
system `log` CLI utility. See the [Mac App](#mac-app) section for more
information.
#### Debugging Configuration
You can verify that configuration is being properly loaded by looking at
the debug output of Ghostty. Documentation for how to view the debug output
is in the "building Ghostty" section at the end of the README.
In the debug output, you should see in the first 20 lines or so messages
about loading (or not loading) a configuration file, as well as any errors
it may have encountered. Configuration errors are also shown in a dedicated
window on both macOS and Linux (GTK). Ghostty does not treat configuration
errors as fatal and will fall back to default values for erroneous keys.
You can also view the full configuration Ghostty is loading using
`ghostty +show-config` from the command-line. Use the `--help` flag to
additional options for that command.
### Themes
Ghostty ships with 300+ built-in themes (from
[iTerm2 Color Schemes](https://github.com/mbadolato/iTerm2-Color-Schemes)).
You can configure Ghostty to use any of these themes using the `theme`
configuration. Example:
```
theme = Solarized Dark - Patched
```
You can find a list of built-in themes using the `+list-themes` action:
```
ghostty +list-themes
...
```
On macOS, the themes are built-in to the `Ghostty.app` bundle. On Linux,
theme support requires a valid Ghostty resources dir ("share" directory).
More details about how to validate the resources directory on Linux
is covered in the [shell integration section](#shell-integration-installation-and-verification).
Any custom color configuration (`palette`, `background`, `foreground`, etc.)
in your configuration files will override the theme settings. This can be
used to load a theme and fine-tune specific colors to your liking.
**Interested in contributing a new theme or updating an existing theme?**
Please send theme changes upstream to the
[iTerm2 Color Schemes](https://github.com/mbadolato/iTerm2-Color-Schemes))
repository. Ghostty periodically updates the themes from this source.
_Do not send theme changes to the Ghostty project directly_.
### Shell Integration
Ghostty supports some features that require shell integration. I am aiming
to support many of the features that
[Kitty supports for shell integration](https://sw.kovidgoyal.net/kitty/shell-integration/).
The currently supported shell integration features in Ghostty:
- We do not confirm close for windows where the cursor is at a prompt.
- New terminals start in the working directory of the previously focused terminal.
- Complex prompts resize correctly by allowing the shell to redraw the prompt line.
- Triple-click while holding control (Linux) or command (macOS) to select the output of a command.
- The cursor at the prompt is turned into a bar.
- The `jump_to_prompt` keybinding can be used to scroll the terminal window
forward and back through prompts.
- Alt+click (option+click on macOS) to move the cursor at the prompt.
- `sudo` is wrapped to preserve Ghostty terminfo (disabled by default)
#### Shell Integration Installation and Verification
Ghostty will automatically inject the shell integration code for `bash`, `zsh`
and `fish`. Other shells do not have shell integration code written but will
function fine within Ghostty with the above mentioned shell integration features
inoperative. **If you want to disable automatic shell integration,** set
`shell-integration = none` in your configuration file.
> [!NOTE]
>
> The version of Bash distributed with macOS (`/bin/bash`) does not support
> automatic shell integration. You'll need to manually source the shell
> integration script (as shown below). You can also install a standard
> version of Bash from Homebrew or elsewhere and set it as your shell.
**For the automatic shell integration to work,** Ghostty must either be run
from the macOS app bundle or be installed in a location where the contents of
`zig-out/share` are available somewhere above the directory where Ghostty
is running from. On Linux, this should automatically work if you run from
the `zig-out` directory tree structure (a standard FHS-style tree).
You may also manually set the `GHOSTTY_RESOURCES_DIR` to point to the
`zig-out/share/ghostty` contents. To validate this directory the file
`$GHOSTTY_RESOURCES_DIR/../terminfo/ghostty.terminfo` should exist.
To verify shell integration is working, look for the following log lines:
```
info(io_exec): using Ghostty resources dir from env var: /Applications/Ghostty.app/Contents/Resources
info(io_exec): shell integration automatically injected shell=termio.shell_integration.Shell.fish
```
If you see any of the following, something is not working correctly.
The main culprit is usually that `GHOSTTY_RESOURCES_DIR` is not pointing
to the right place.
```
ghostty terminfo not found, using xterm-256color
or
shell could not be detected, no automatic shell integration will be injected
```
#### Switching Shells with Shell Integration
Automatic shell integration as described in the previous section only works
for the _initially launched shell_ when Ghostty is started. If you switch
shells within Ghostty, i.e. you manually run `bash` or you use a command
like `nix-shell`, the shell integration _will be lost_ in that shell
(it will keep working in the original shell process).
To make shell integration work in these cases, you must manually source
the Ghostty shell-specific code at the top of your shell configuration
files. Ghostty will automatically set the `GHOSTTY_RESOURCES_DIR` environment
variable when it starts, so you can use this to (1) detect your shell
is launched within Ghostty and (2) to find the shell-integration.
For example, for bash, you'd put this _at the top_ of your `~/.bashrc`:
```bash
# Ghostty shell integration for Bash. This must be at the top of your bashrc!
if [ -n "${GHOSTTY_RESOURCES_DIR}" ]; then
builtin source "${GHOSTTY_RESOURCES_DIR}/shell-integration/bash/ghostty.bash"
fi
```
For details see <a href="https://github.com/ghostty-org/ghostty/blob/main/src/shell-integration/README.md">shell-integration/README.md</a>.
Each shell integration's installation instructions are documented inline:
| Shell | Integration |
| -------- | ---------------------------------------------------------------------------------------------- |
| `bash` | `${GHOSTTY_RESOURCES_DIR}/shell-integration/bash/ghostty.bash` |
| `fish` | `${GHOSTTY_RESOURCES_DIR}/shell-integration/fish/vendor_conf.d/ghostty-shell-integration.fish` |
| `zsh` | `${GHOSTTY_RESOURCES_DIR}/shell-integration/zsh/ghostty-integration` |
| `elvish` | `${GHOSTTY_RESOURCES_DIR}/shell-integration/elvish/lib/ghostty-integration.elv` |
### Terminfo
Ghostty ships with its own [terminfo](https://en.wikipedia.org/wiki/Terminfo)
entry to tell software about its capabilities. When that entry is detected,
Ghostty sets the `TERM` environment variable to `xterm-ghostty`.
If the Ghostty resources dir ("share" directory) is detected, Ghostty will
set a `TERMINFO` environment variable so `xterm-ghostty` properly advertises
the available capabilities of Ghostty. On macOS, this always happens because
the terminfo is embedded in the app bundle. On Linux, this depends on
appropriate installation (see the installation instructions).
If you use `sudo`, sudo may reset your environment variables and you may see
an error about `missing or unsuitable terminal: xterm-ghostty` when running
some programs. To resolve this, you must either configure sudo to preserve
the `TERMINFO` environment variable, or you can use shell-integration with
the `sudo` feature enabled and Ghostty will alias sudo to automatically do
this for you. To enable the shell-integration feature specify
`shell-integration-features = sudo` in your configuration.
If you use SSH to connect to other machines that do not have Ghostty's terminfo
entry, you will see error messages like `missing or unsuitable terminal:
xterm-ghostty`.
Hopefully someday Ghostty will have terminfo entries pre-distributed
everywhere, but in the meantime there are two ways to resolve the situation:
1. Copy Ghostty's terminfo entry to the remote machine.
2. Configure SSH to fall back to a known terminfo entry.
#### Copy Ghostty's terminfo to a remote machine
The following one-liner will export the terminfo entry from your host and
import it on the remote machine:
```shell-session
infocmp -x | ssh YOUR-SERVER -- tic -x -
```
> [!NOTE]
>
> **macOS versions before Sonoma cannot use the system-bundled `infocmp`.**
> The bundled version of `ncurses` is too old to emit a terminfo entry that can be
> read by more recent versions of `tic`, and the command will fail with a bunch
> of `Illegal character` messages. You can fix this by using Homebrew to install
> a recent version of `ncurses` and replacing `infocmp` above with the full path
> `/opt/homebrew/opt/ncurses/bin/infocmp`.
#### Configure SSH to fall back to a known terminfo entry
If copying around terminfo entries is untenable, you can override `TERM` to a
fallback value using SSH config.
```ssh-config
# .ssh/config
Host example.com
SetEnv TERM=xterm-256color
```
**Requires OpenSSH 8.7 or newer.** [The 8.7 release added
support](https://www.openssh.com/txt/release-8.7) for setting `TERM` via
`SetEnv`.
> [!WARNING]
>
> **Fallback does not support advanced terminal features.** Because
> `xterm-256color` does not include all of Ghostty's capabilities, terminal
> features beyond xterm's like colored and styled underlines will not work.
## Roadmap and Status ## Roadmap and Status
@ -512,40 +185,9 @@ SENTRY_DSN=https://e914ee84fd895c4fe324afa3e53dac76@o4507352570920960.ingest.us.
## Developing Ghostty ## Developing Ghostty
To build Ghostty, you need [Zig 0.13](https://ziglang.org/) installed. See the documentation on the Ghostty website for
[building Ghostty from source](http://ghostty.org/docs/install/build).
On Linux, you may need to install additional dependencies. See For development, omit the `-Doptimize` flag to build a debug build.
[Linux Installation Tips](#linux-installation-tips). On macOS, you
need Xcode installed with the macOS and iOS SDKs enabled. See
[Mac `.app`](#mac-app).
The official development environment is defined by Nix. You do not need
to use Nix to develop Ghostty, but the Nix environment is the environment
which runs CI tests and builds release artifacts. Any development work on
Ghostty must pass within these Nix environments.
> [!NOTE]
>
> **Zig 0.13 is required.** Ghostty only guarantees that it can build
> against 0.13. Zig is still a fast-moving project so it is likely newer
> versions will not be able to build Ghostty yet. You can find binary
> releases of Zig release builds on the
> [Zig downloads page](https://ziglang.org/download/).
With Zig and necessary dependencies installed, a binary can be built using
`zig build`:
```shell-session
zig build
...
zig-out/bin/ghostty
```
This will build a binary for the currently running system (if supported).
**Note: macOS does not result in a runnable binary with this command.**
macOS builds produce a library (`libghostty.a`) that is used by the Xcode
project in the `macos` directory to produce the final `Ghostty.app`.
On Linux or macOS, you can use `zig build -Dapp-runtime=glfw run` for a quick On Linux or macOS, you can use `zig build -Dapp-runtime=glfw run` for a quick
GLFW-based app for a faster development cycle while developing core GLFW-based app for a faster development cycle while developing core
@ -562,189 +204,6 @@ Other useful commands:
in the current running terminal emulator so if you want to check the in the current running terminal emulator so if you want to check the
behavior of this project, you must run this command in Ghostty. behavior of this project, you must run this command in Ghostty.
### Compiling a Release Build
The normal build will be a _debug build_ which includes a number of
safety features as well as debugging features that dramatically slow down
normal operation of the terminal (by as much as 100x). If you are building
a terminal for day to day usage, build a release version:
```shell-session
zig build -Doptimize=ReleaseFast
...
```
You can verify you have a release version by checking the filesize of the
built binary (`zig-out/bin/ghostty`). The release version should be significantly
smaller than debug builds. On Linux, the release build is around 31MB while the
debug build is around 145MB.
When using the GTK runtime (`-Dapp-runtime=gtk`) a release build will
use a [single-instance application](https://developer.gnome.org/documentation/tutorials/application.html).
If you're developing Ghostty from _inside_ a release build and build & launch a
new one that will not reflect the changes you made, but instead launch a new
window for the existing instance. You can disable this behaviour with the
`--gtk-single-instance=false` flag or by adding `gtk-single-instance = false` to
the configuration file.
### Linux Installation Tips
On Linux, you'll need to install header packages for Ghostty's dependencies
before building it. Typically, these are only gtk4 and libadwaita, since
Ghostty will build everything else static by default. On Ubuntu and Debian, use
```
sudo apt install libgtk-4-dev libadwaita-1-dev git
```
> [!NOTE]
>
> **A recent GTK is required for Ghostty to work with Nvidia (GL) drivers
> under x11.** Ubuntu 22.04 LTS has GTK 4.6 which is not new enough. Ubuntu 23.10
> has GTK 4.12 and works. From [this discussion](https://discourse.gnome.org/t/opengl-context-version-not-respected-on-gtk4-rs/12162?u=cdehais)
> the problem was fixed in GTK by Dec 2022. Also, if you are a BTRFS user, make
> sure to manually upgrade your Kernel (6.6.6 will work). The stock kernel in
> Ubuntu 23.10 is 6.5.0 which has a bug which
> [causes zig to fail its hash check for packages](https://github.com/ziglang/zig/issues/17282).
> [!WARNING]
>
> GTK 4.14 on Wayland has a bug which may cause an immediate crash.
> There is an [open issue](https://gitlab.gnome.org/GNOME/gtk/-/issues/6589/note_2072039)
> to track this GTK bug. You can workaround this issue by running ghostty with
> `GDK_DEBUG=gl-disable-gles ghostty`
>
> However, that fix may not work for you if the GTK version Ghostty is compiled
> against is too old, which mainly currently happens with development builds on NixOS.
>
> If your build of Ghostty immediately crashes after launch, try looking
> through the debug output. If running `./zig-out/bin/ghostty 2>&1 | grep "Unrecognized value"`
> result in the line `Unrecognized value "gl-disable-gles". Try GDK_DEBUG=help`,
> then the GTK version used is too old.
>
> To fix this, you might need to manually tie the `nixpkgs-stable` inputs to your
> system's `nixpkgs` in `flake.nix`:
>
> ```nix
> {
> inputs = {
> # nixpkgs-stable.url = "github:nixos/nixpkgs/release-23.05";
>
> # Assumes your system nixpkgs is called "nixpkgs"
> nixpkgs-stable.url = "nixpkgs";
> }
> }
> ```
On Arch Linux, use
```
sudo pacman -S gtk4 libadwaita
```
On Fedora variants, use
```
sudo dnf install gtk4-devel zig libadwaita-devel
```
On Fedora Atomic variants, use
```
rpm-ostree install gtk4-devel zig libadwaita-devel
```
If you're planning to use a build from source as your daily driver,
I recommend using the `-p` (prefix) flag for `zig build` to install
Ghostty into `~/.local`. This will setup the proper FHS directory structure
that ensures features such as shell integration, icons, GTK shortcuts, etc.
all work.
```
zig build -p $HOME/.local -Doptimize=ReleaseFast
...
```
With a typical Freedesktop-compatible desktop environment (i.e. Gnome,
KDE), this will make Ghostty available as an app in your app launcher.
Note, if you don't see it immediately you may have to log out and log back
in or maybe even restart. For my Gnome environment, it showed up within a
few seconds. For any other desktop environment, you can launch Ghostty
directly using `~/.local/bin/ghostty`.
If Ghostty fails to launch using an app icon in your app launcher,
ensure that `~/.local/bin` is on your _system_ `PATH`. The desktop environment
itself must have that path in the `PATH`. Google for your specific desktop
environment and distribution to learn how to do that.
This _isn't required_, but `~/.local` is a directory that happens to be
on the search path for a lot of software (such as Gnome and KDE) and
installing into a prefix with `-p` sets up a directory structure to ensure
all features of Ghostty work.
### Mac `.app`
To build the official, fully featured macOS application, you must
build on a macOS machine with Xcode installed, and the active developer
directory pointing to it. If you're not sure that's the case, check the
output of `xcode-select --print-path`:
```shell-session
xcode-select --print-path
/Library/Developer/CommandLineTools # <-- BAD
sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer
xcode-select --print-path
/Applications/Xcode.app/Contents/Developer # <-- GOOD
```
The above can happen if you install the Xcode Command Line Tools _after_ Xcode
is installed. With that out of the way, make sure you have both the macOS and
iOS SDKs installed (from inside Xcode → Settings → Platforms), and let's move
on to building Ghostty:
```shell-session
zig build -Doptimize=ReleaseFast
cd macos && xcodebuild
```
> [!NOTE]
> If you're using the Nix environment on macOS, `xcodebuild` will
> fail due to the linker environment variables Nix sets. You must
> run the `xcodebuild` command specifically outside of the Nix
> environment.
This will output the app to `macos/build/ReleaseLocal/Ghostty.app`.
This app will be not be signed or notarized.
[Official continuous builds are available](https://github.com/ghostty-org/ghostty/releases/tag/tip)
that are both signed and notarized.
The "ReleaseLocal" build configuration is specifically for local release
builds and disables some security features (such as "Library Validation")
to make it easier to run without having to have a code signing identity
and so on. These builds aren't meant for distribution. If you want a release
build with all security features, I highly recommend you use
[the official continuous builds](https://github.com/ghostty-org/ghostty/releases/tag/tip).
When running the app, logs are available via macOS unified logging such
as `Console.app`. The easiest way I've found to view these is to just use the CLI:
```sh
sudo log stream --level debug --predicate 'subsystem=="com.mitchellh.ghostty"'
...
```
### Windows Notes
Windows support is still a [work-in-progress](https://github.com/ghostty-org/ghostty/issues/437).
The current status is that a bare bones glfw-based build _works_! The experience
with this build is super minimal: there are no native experiences, only a
single window is supported, no tabs, etc. Therefore, the current status is
simply that the core terminal experience works.
If you want to help with Windows development, please see the
[tracking issue](https://github.com/ghostty-org/ghostty/issues/437). We plan
on vastly improving this experience over time.
### Linting ### Linting
#### Prettier #### Prettier
@ -786,59 +245,6 @@ alejandra .
Make sure your Alejandra version matches the version of Alejandra in [devShell.nix](https://github.com/ghostty-org/ghostty/blob/main/nix/devShell.nix). Make sure your Alejandra version matches the version of Alejandra in [devShell.nix](https://github.com/ghostty-org/ghostty/blob/main/nix/devShell.nix).
### Nix Package
There is Nix package that can be used in the flake (`packages.ghostty` or `packages.default`).
It can be used in NixOS configurations and otherwise built off of.
Below is an example:
```nix
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
# NOTE: This will require your git SSH access to the repo.
#
# WARNING:
# Do NOT pin the `nixpkgs` input, as that will
# declare the cache useless. If you do, you will have
# to compile LLVM, Zig and Ghostty itself on your machine,
# which will take a very very long time.
#
# Additionally, if you use NixOS, be sure to **NOT**
# run `nixos-rebuild` as root! Root has a different Git config
# that will ignore any SSH keys configured for the current user,
# denying access to the repository.
#
# Instead, either run `nix flake update` or `nixos-rebuild build`
# as the current user, and then run `sudo nixos-rebuild switch`.
ghostty = {
url = "git+ssh://git@github.com/ghostty-org/ghostty";
# NOTE: The below 2 lines are only required on nixos-unstable,
# if you're on stable, they may break your build
inputs.nixpkgs-stable.follows = "nixpkgs";
inputs.nixpkgs-unstable.follows = "nixpkgs";
};
};
outputs = { nixpkgs, ghostty, ... }: {
nixosConfigurations.mysystem = nixpkgs.lib.nixosSystem {
modules = [
{
environment.systemPackages = [
ghostty.packages.x86_64-linux.default
];
}
];
};
};
}
```
You can also test the build of the nix package at any time by running `nix build .`.
#### Updating the Zig Cache Fixed-Output Derivation Hash #### Updating the Zig Cache Fixed-Output Derivation Hash
The Nix package depends on a [fixed-output The Nix package depends on a [fixed-output

View File

@ -1,107 +0,0 @@
# Hello Ghostty Testers! 👋👻
Thank you for being an early Ghostty user! I'm super excited to have you
here. **Please, please read the [README](https://github.com/ghostty-org/ghostty#readme)!**
There is a lot of information in the README that I will not be repeating here,
especially about how to get Ghostty and configure it.
## Let's Build An Excellent Terminal
The Ghostty development process so far has been a cycle of inviting people,
getting Ghostty to work great for them, then inviting new people once it
feels stable.
So, if you're part of a new group, _expect there will be bugs_!
Ghostty may work really great for previous testers, but every new group of
users has their own OS quirks, programs, expected features, etc. that tend
to surface new issues. **That's why you're here and I appreciate you so much!**
**I will not invite new groups of testers until Ghostty is _very stable and
excellent_ for the previous group of testers.** So let's work together on getting
Ghostty to a place that works well for you.
## Talking About Ghostty Publicly
Feel free to talk about Ghostty, share screenshots, etc. in the public!
Please don't share source access yet. And obviously, if Ghostty is buggy
or you want to say something mean, I'd rather you talk to me first so
I can try to fix it, this is an early beta after all... I hope no testers
I invite would be mean, though!
## Reporting Issues and Contributing
Please report any issues you have, including feature requests!
As Ghostty is nearing its public release we are tweaking the flow of contributing. The general outline is first discuss a topic (issue, bug, feature request, pull request) in a [discussion](https://github.com/ghostty-org/ghostty/discussions). The discussion can then be the basis for opening an _actionable_ issue and subsequent pull request. To get a more complete picture read [CONTRIBUTING.md](https://github.com/ghostty-org/ghostty/blob/main/CONTRIBUTING.md).
That said, **feel free to contribute!** I would _love_ that. If you want
any help, ask in Discord and I'll do my best to point you in the right direction
or even pair (time permitting) if you're interested.
### Bug Priority
This is the priority of bugs:
1. Crashes. 💥 These are just unacceptable and I'll drop everything to
fix a crash.
2. Escape sequence logic or rendering issues. These are almost as bad as
crashes because they usually make your workflow unusable. This includes
unsupported escape sequences that impact your workflow.
3. Anything else...
## Let's Talk!
You likely landed in the Discord community first, if for some reason you're not
in there, join [here](https://discord.gg/ghostty). Discord is a great place to
share feedback, discuss issues, ask questions and talk to other testers.
## Other FAQ
### Can I Invite a Friend?
Yes, if you have any friends you'd like to add to the beta, you can use
the `/vouch` command in the Ghostty Discord server and mods will be notified
of your vouch request.
If the username of your friend doesn't show up for the `/vouch` command,
it means they either haven't joined the Discord yet or they haven't accepted
the server rules. Please ask them to join the Discord and accept the rules
and then try again.
Vouches are handled on a as-available basis, so please be patient. They're
usually processed quickly, but sometimes it may take a day or two. In very
rare cases, we pause vouches to ensure the stability of the beta. But that's
very rare and has only happened a handful of times.
Anyone you vouch is your responsibility, so please make sure they're a good
fit for the beta and will follow the rules. There is no limit on the number
of people you can vouch in total, but we do rate limit the number of vouches
you can do. If any mods feel you're vouching for too many people, they may
reject your requests.
### I want to help, what can I work on?
I'd really love that, I want to foster a healthy contributing community
with Ghostty over time, and I really appreciate the help.
Take a look at the issues list. Feel free to suggest new things. If you
have a favorite feature from some other terminal emulator, let's build it!
My only ask is that for big features, please ask the Discord first to gauge
interest/acceptance for it before opening up some huge PR.
There are also non-core help we can use: docs, website work, Discord bots,
etc. etc. For example, a web UI to generate a configuration file would be
cool. Or a web UI to preview your color settings. There is currently one
[community project](https://github.com/zerebos/ghostty-config) attempting
to tackle both of these.
### Is Ghostty Open Source?
Right now technically not (no license file). But yes, it will be full
open source (by the OSI definition). I'm not sure what license to choose
yet, leaning towards going with MIT for this project but open to ideas.
We will add a license prior to opening up the repository. During the private
beta period, I'll continue with a no license project.