Compare commits

..

3 Commits
4.7.0 ... 4.7.1

Author SHA1 Message Date
Johannes Altmanninger
efb0223da1 Release 4.7.1
Created by ./build_tools/release.sh 4.7.1
2026-05-08 00:02:14 +08:00
Johannes Altmanninger
b6f30f11e4 webconfig: hack webconfig to fake interactive colors
Commit e2b18fc5b6 (config.fish: don't load default theme in
noninteractive shells, 2026-04-28) broke webconfig: since "fish_config
theme choose default" was removed from non-interactive shells,
webconfig won't know the current theme in interactive shells.

Fix this by adding secret knob that allows webconfig to have
noninteractive fish set the same colors as interactive fish again.

This assumes that plugins won't need the knob, i.e. won't need to
know the "current" theme.

Alternatively, webconfig could run "fish -i" but that could cause
issues if an "if status is-interactive" block in user-config does
something naughty such as writing to stdout even if it's not a terminal.

Alternatively, we could do

	fish -c '
		if test -z "$(__fish_theme_variables)"
			fish_config theme choose default
		end
		# can dump current theme now
	'

but that does not feel as reliable (what if the user explicitly does
"set -e" on all color variables or).

Fixes #12717
2026-05-08 00:01:25 +08:00
Johannes Altmanninger
fb29c85a62 start new cycle
Created by ./build_tools/release.sh 4.7.0
2026-05-06 14:51:33 +08:00
6 changed files with 21 additions and 4 deletions

View File

@@ -1,3 +1,8 @@
fish 4.7.1 (released May 08, 2026)
==================================
This release fixes a regression in 4.7.0 that caused the web config (``fish_config``) to fail to start (:issue:`12717`).
fish 4.7.0 (released May 05, 2026)
==================================

2
Cargo.lock generated
View File

@@ -291,7 +291,7 @@ checksum = "5baebc0774151f905a1a2cc41989300b1e6fbb29aff0ceffa1064fdd3088d582"
[[package]]
name = "fish"
version = "4.7.0"
version = "4.7.1"
dependencies = [
"assert_matches",
"bitflags",

View File

@@ -96,7 +96,7 @@ debug = true
[package]
name = "fish"
version = "4.7.0"
version = "4.7.1"
edition.workspace = true
rust-version.workspace = true
default-run = "fish"

View File

@@ -1,3 +1,11 @@
fish (4.7.1-1) stable; urgency=medium
* Release of new version 4.7.1.
See https://github.com/fish-shell/fish-shell/releases/tag/4.7.1 for details.
-- Johannes Altmanninger <aclopte@gmail.com> Fri, 08 May 2026 00:02:14 +0800
fish (4.7.0-1) stable; urgency=medium
* Release of new version 4.7.0.

View File

@@ -208,6 +208,8 @@ end
if status is-interactive
__fish_migrate
end
if status is-interactive || set -qgx __fish_force_load_default_theme
fish_config theme choose default --no-override
end

View File

@@ -100,13 +100,14 @@ def is_chromeos_garcon():
return False
def run_fish_cmd(text, strict=False):
def run_fish_cmd(text, strict=False, env=None):
print("$ " + text)
p = subprocess.Popen(
[FISH_BIN_PATH],
stdin=subprocess.PIPE,
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
env=env,
)
out, err = p.communicate(text.encode("utf-8"))
out = out.decode("utf-8", "replace")
@@ -811,7 +812,8 @@ class FishConfigHTTPRequestHandler(SimpleHTTPServer.SimpleHTTPRequestHandler):
TERMINAL_COLOR_THEME
)
+ "or __fish_color_theme=unknown __fish_apply_theme\n"
+ "__fish_theme_export_for_webconfig"
+ "__fish_theme_export_for_webconfig",
env=os.environ | {"__fish_force_load_default_theme": "1"},
)
assert err == ""