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
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [1.6.1] - 2026-05-06

### Fixed
- `install.sh`: the "Activate zsh for this session: exec zsh" advisory was shown
even when the installer ran non-interactively (e.g. `curl ... | bash`). In that
context the bash process is ephemeral — the user's real terminal session was
already in zsh. A new `NXS_STDIN_IS_TTY` flag (`[ -t 0 ]`) gates the exec-zsh
advice so it only appears in live interactive sessions.

## [1.6.0] - 2026-05-06

### Added
Expand Down
2 changes: 1 addition & 1 deletion CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ so re-runs over partial state self-heal. `test.sh` carries a regression guard.
| Flag | Set by | Read by |
|------|--------|---------|
| `_SHELL_IS_ZSH` | `_set_default_shell()` in `modules/zsh.sh` | logging during install (not used by next-steps summary) |
| `NXS_*` | `_compute_next_steps_state()` in `install.sh` | `install.sh` "next steps" — reads actual system state (passwd, ZSH_VERSION, fc-list, …) rather than install-time flags |
| `NXS_*` | `_compute_next_steps_state()` in `install.sh` | `install.sh` "next steps" — reads actual system state (passwd, ZSH_VERSION, fc-list, …) rather than install-time flags; `NXS_STDIN_IS_TTY` gates "exec zsh" advice that is noise in curl-pipe / CI contexts |
| `CAN_SUDO` | `detect_sudo()` in `lib/utils.sh` | everywhere |
| `CHECK_ONLY` | `--check` arg in `update.sh` | update.sh per-tool blocks |
| `DOTFILES_DIR` | top of each script | modules, symlink helpers |
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.6.0
1.6.1
26 changes: 20 additions & 6 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,11 @@ _compute_next_steps_state() {
&& [ -f "${HOME}/.config/autostart/caps-remap.desktop" ]; then
NXS_CAPS_REMAP_DONE=true
fi

# Interactive terminal? False when piped (curl | bash) or in CI.
# Used to suppress "exec zsh" advice that makes no sense outside a live session.
NXS_STDIN_IS_TTY=false
if [ -t 0 ]; then NXS_STDIN_IS_TTY=true; fi
}

# ── Main ──────────────────────────────────────────────────────────────────────
Expand Down Expand Up @@ -216,18 +221,27 @@ case "$PROFILE" in
elif $NXS_IN_ZSH; then
: # Already running in zsh — nothing needed
elif $NXS_ZSH_IS_DEFAULT; then
# Login shell is zsh but this session is not (common on re-runs from bash)
echo " • Activate zsh for this session: exec zsh"
_nxs_action=$(( _nxs_action + 1 ))
# Login shell is zsh but this process is bash.
# In a live terminal (tty) the user can exec zsh now — worth showing.
# In a curl-pipe the bash process is ephemeral; the user's real session
# is already in zsh, so this message is noise — suppress it.
if $NXS_STDIN_IS_TTY; then
echo " • Activate zsh for this session: exec zsh"
_nxs_action=$(( _nxs_action + 1 ))
fi
elif $NXS_BASHRC_EXECZSH; then
# Docker shim present — interactive bash will auto-exec zsh
echo " • Interactive bash sessions auto-exec zsh (via .bashrc)"
echo " Activate now: exec zsh"
if $NXS_STDIN_IS_TTY; then
echo " Activate now: exec zsh"
fi
_nxs_action=$(( _nxs_action + 1 ))
else
# Login shell is not yet zsh and no shim
# Login shell is not yet zsh and no shim — always show (real pending action)
echo " • Set default shell to zsh: chsh -s ${NXS_ZSH_BIN} (next login)"
echo " Or activate now: exec zsh"
if $NXS_STDIN_IS_TTY; then
echo " Or activate now: exec zsh"
fi
_nxs_action=$(( _nxs_action + 1 ))
fi

Expand Down
Loading