puppy is an example implementation of a tiny Web browser for educational purposes.
puppy depends on OpenSSL (through reqwest), ncurses (the backend of the
cursive TUI) and V8 (rusty_v8), so the following packages are required to
build it on Linux (tested on Ubuntu 22.04/24.04):
sudo apt install -y build-essential pkg-config libssl-dev libncurses-devpkg-configandlibssl-dev: needed byopenssl-sys, otherwise its build script fails withCould not find directory of OpenSSL installation.libncurses-dev: needed byncurses, otherwise its build script fails withfatal error: ncurses.h: No such file or directory.
NOTE: rusty_v8 0.22.1 is not compatible with recent Rust toolchains, because
its TypeIdHasher assumes that std::any::TypeId is 8 bytes long while
TypeId is a 128-bit value since Rust 1.72. puppy therefore vendors a minimally
patched copy of the crate under vendor/rusty_v8, which is wired up with
[patch.crates-io] in Cargo.toml. See
vendor/rusty_v8/PATCH.md for the details.
You can run puppy program with the following command(s):
cargo run -- helpYou can install puppy by the following command(s):
cargo install --locked --path . --forceAfter you have successfully installed puppy, you can see help as follows:
puppy helpYou can install shell completions as follows:
# in bash
eval "$(puppy completion bash)"
# in fish
puppy completion fish | sourceYou can run tests with the following command(s):
cargo testYou can cache files related to V8 as follows:
$ export RUSTY_V8_MIRROR=$HOME/.cache/rusty_v8
(...omitted...)
$ ./scripts/prepare-v8.sh
(...omitted...)
$ cargo build
(...omitted...)