hestiacp icon indicating copy to clipboard operation
hestiacp copied to clipboard

Update v-change-user-package

Open Skamasle opened this issue 9 months ago • 1 comments

Prevent open 3 process

Skamasle avatar Jul 14 '25 20:07 Skamasle

The new awk -F"'" '/SHELL/ {print $2}' no longer stops after the first match, while the previous grep -m1 … | cut … did. If a package file ever contains more than one SHELL token (e.g., a commented-out legacy value or additional SHELL-related directives), the command substitution now returns multiple lines, and v-change-user-shell receives a newline-separated list that will almost certainly fail.

Maybe add exit after the first print ( {print $2; exit}) so only the primary variable matches to preserve the old grep behavior.

divinity76 avatar Nov 28 '25 08:11 divinity76