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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

### Fix

- (flake) pin `libwebsockets` to fix broken `ttyd`/`vhs` [#212](https://github.com/sectore/timr-tui/pull/212)
- (notification) show `Pomodoro` or `Tabata` instead of `Countdown` [#209](https://github.com/sectore/timr-tui/pull/209)

### Misc
Expand Down
2 changes: 0 additions & 2 deletions demo/pomodoro-auto-special.tape
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# Note: PR "support ctrl + arrow keys" https://github.com/charmbracelet/vhs/pull/673 needs to be merged to run this `tape`.

Output demo/pomodoro_auto_special.gif

# https://github.com/charmbracelet/vhs/blob/main/THEMES.md
Expand Down
2 changes: 0 additions & 2 deletions demo/pomodoro.tape
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# Note: PR "support ctrl + arrow keys" https://github.com/charmbracelet/vhs/pull/673 needs to be merged to run this `tape`.

Output demo/pomodoro.gif

# https://github.com/charmbracelet/vhs/blob/main/THEMES.md
Expand Down
2 changes: 0 additions & 2 deletions demo/tabata.tape
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# Note: PR "support ctrl + arrow keys" https://github.com/charmbracelet/vhs/pull/673 needs to be merged to run this `tape`.

Output demo/tabata.gif

# https://github.com/charmbracelet/vhs/blob/main/THEMES.md
Expand Down
37 changes: 27 additions & 10 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

44 changes: 9 additions & 35 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
# pinned to last known good before `libwebsockets` 4.4.5 broke ttyd/vhs (2026-06-10)
# see https://github.com/NixOS/nixpkgs/issues/532638#issuecomment-4734542554
# TODO: Remove when `libwebsockets` is fixed upstream
nixpkgs-lws.url = "github:NixOS/nixpkgs/7f1c78be632c";
flake-utils.url = "github:numtide/flake-utils";
crane.url = "github:ipetkov/crane";
fenix = {
Expand All @@ -11,13 +15,16 @@

outputs = {
nixpkgs,
nixpkgs-lws,
flake-utils,
fenix,
crane,
...
}:
flake-utils.lib.eachDefaultSystem (system: let
pkgs = nixpkgs.legacyPackages.${system};
pkgs = nixpkgs.legacyPackages.${system}.extend (_final: _prev: {
libwebsockets = nixpkgs-lws.legacyPackages.${system}.libwebsockets;
});

toolchain = fenix.packages.${system}.fromToolchainFile {
file = ./rust-toolchain.toml;
Expand Down Expand Up @@ -46,39 +53,6 @@
CARGO_BUILD_RUSTFLAGS = "-C target-feature=+crt-static";
});

vhs = pkgs.buildGoModule (finalAttrs: {
pname = "vhs";
version = "0.11.0";

src = pkgs.fetchFromGitHub {
owner = "charmbracelet";
repo = "vhs";
tag = "v${finalAttrs.version}";
# hash = nixpkgs.lib.fakeSha256;
hash = "sha256-VOiI+ddiax04QtCcDr6ze53kd/HHGbfQE3j/32iq4Ro=";
};

# vendorHash = nixpkgs.lib.fakeSha256;
vendorHash = "sha256-cgKLYUATtn4hMdIOXZe9JWYNUOrX3S6BDfvS+rIWDfM=";

nativeBuildInputs = [pkgs.makeBinaryWrapper];

ldflags = [
"-s"
"-w"
"-X=main.Version=${finalAttrs.version}"
];

postInstall = ''
wrapProgram $out/bin/vhs --prefix PATH : ${
pkgs.lib.makeBinPath (
[pkgs.ffmpeg pkgs.ttyd]
++ pkgs.lib.optionals pkgs.stdenv.hostPlatform.isLinux [pkgs.chromium]
)
}
'';
});

# Windows cross-compilation build
# @see https://crane.dev/examples/cross-windows.html
windowsBuild = let
Expand Down Expand Up @@ -107,7 +81,7 @@
packages =
[
toolchain
vhs
pkgs.vhs
pkgs.just
pkgs.nixd
pkgs.alejandra
Expand Down
Loading