96
19
Yesterday my terminal started surrounding commands that had been run with square brackets. I'm not sure how I've turned this on, but would like to turn it off.
So far, I've done:
- Checked that there's nothing funny in my
.bash_profile
- Tried changing the profile back to Basic
- Tried changing to a different shell (zsh)
I've not been able to uncover anything on Google either.
Any ideas?
Update
? What exactly do you mean? There aren't any [] in your screenshot? – Tonny – 2015-09-18T11:16:04.187
3@Tonny look at the far left and right of the first line - right up against the window edge – Josh – 2015-09-18T11:37:22.583
I see: it's the whole line including the prompt. I was focussing on just the command. I can't recall ever seeing that on my own Mac. I just checked and it isn't present on my 2 Mac's, both run Yosemite, bash with the vanilla config, i never changed that on either machine. – Tonny – 2015-09-18T13:21:33.093
Show us:
echo "$PS1"; echo "$PROMPT_COMMAND"
– glenn jackman – 2015-09-18T13:43:13.573I'm guessing that your set-prompt setup commands are slightly messed up. In order to do fancy bold or color formatting, that square-bracket character is used a lot, and I think one of them is showing up in your prompt, instead of formatting the prompt. – jimtut – 2015-09-18T23:23:04.847
1@glennjackman I've updated the question with a screenshot of the output. Googled it, and it looks to be the system defaults. – Josh – 2015-09-19T11:15:32.270
@jimtut Is that related to the
$PS1
variable? – Josh – 2015-09-19T11:19:19.870I use tcsh not the shells you're using, so I can't say for sure. Try tcsh for a minute, see if the bracket disappears. If so, go back to your shell and change $PS1 or whatever variable controls the prompt in your shell. – jimtut – 2015-09-19T15:14:12.917
1
You did not turn it on. The new Marks feature automatically marks prompt lines by default. See here for an explanation about this feature: http://apple.stackexchange.com/questions/209635/
– Chris Page – 2015-11-03T19:40:15.720