Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC: make julia prompt non bold #20236

Closed
wants to merge 1 commit into from
Closed

RFC: make julia prompt non bold #20236

wants to merge 1 commit into from

Conversation

KristofferC
Copy link
Sponsor Member

Makes the julia prompt (julia>) non bold since the input and answer text now is non bold.

image

Lemme see some thumbs.

@kshyatt kshyatt added the domain:display and printing Aesthetics and correctness of printed representations of objects. label Jan 25, 2017
@StefanKarpinski
Copy link
Sponsor Member

I'd like some ability to turn thing bold again. E.g. export JULIA_PROMPT_COLOR="bold_green". Can we do that currently? If not, could we add that feature to parsing of color names?

@KristofferC
Copy link
Sponsor Member Author

Yeah, that could be one reason to leave it on. Adding bold to all 16 + 256 colors is one way to do it (or punt on boldness for the 256 colors...).

@DNF2
Copy link

DNF2 commented Jan 26, 2017

Has there ever been any discussion about what the prompt actually should be? (Couldn't find any..)

Matlab has >> and Python has >>>. What about
screen shot 2017-01-26 at 15 16 40
?

(I apologize if this is just noise, but I believe this PR addresses the visual impact of the prompt, so I thought it relevant to bring it up. I always found the current prompt a bit 'heavyweight'.)

@StefanKarpinski
Copy link
Sponsor Member

What's wrong with julia> as the prompt?

@DNF2
Copy link

DNF2 commented Jan 30, 2017

Nothing wrong, just a bit long :) If something more 'lightweight' would be considered, then jl is highly recognizable, given file extensions, package names, etc. Just throwing it out there, since visual impact was part of the consideration.

This can be changed by every user, of course -- though changing the length of the prompt seems to cause some cursor weirdness.

@ararslan ararslan added the stdlib:REPL Julia's REPL (Read Eval Print Loop) label Feb 6, 2017
@ararslan
Copy link
Member

ararslan commented Feb 6, 2017

Personally I like the extra visual distinction provided by having a bold prompt with non-bold input. Some terminal color schemes map colors in a weird way so in some cases the prompt color becomes nearly indistinguishable from the input color (Jameson noticed this with solarized dark), in which case having the bold by default is handy.

@KristofferC
Copy link
Sponsor Member Author

Isn't solarized mapping colours weirdly because of the bold?

@ararslan
Copy link
Member

ararslan commented Feb 6, 2017

That I don't know, I don't use solarized. @vtjnash?

@pkofod
Copy link
Contributor

pkofod commented Feb 6, 2017

(If matlab uses >>, python uses >>>, then we should trump them and use >>>> and win bigly)

I vote for nonbold. Ohmyrepl has shown how costumizable the Julia repl is, so people can always turn bold back on (right?). Given that @KristofferC (I believe) has earlier show that color names are sometimes weird with bold on, I say make bold opt-in.

(Ps autocorrect wanted to change bigly to bigot, go figure)

@KristofferC
Copy link
Sponsor Member Author

The problem is that there is no really nice way of enabling bold + color once the prompt is non bold because the API so far only considered colors as changeable.

@Ismael-VC
Copy link
Contributor

@pkofod pypy uses >>>>, should we go for >>>>> then? 😄

Seriously I like jl> as a prompt julia> is a little bit long for my taste. Currently one can change the prompt but the REPL doesn't behave correctly with prompts of different lenght than the original julia> as okvs mentions.

@StefanKarpinski
Copy link
Sponsor Member

I'm fine with making the prompt configurable, but I'm vehemently against changing the default from julia>. It's great marketing whenever someone demos something in Julia: what's that program that person is using to present this amazing demo? Well, it says "julia" right there.

@StefanKarpinski
Copy link
Sponsor Member

My proposal for an API for bold + color is to allow each color name to be prefixed with bold_.

@vtjnash
Copy link
Sponsor Member

vtjnash commented Feb 6, 2017

Isn't solarized mapping colours weirdly because of the bold?

Solarized maps all of the colors weirdly (it's designed to be low-contrast choice), so it's not much of a metric to go by for the average user.

@KristofferC
Copy link
Sponsor Member Author

BAM: https://kristofferc.github.io/OhMyREPL.jl/latest/features/prompt.html. Even got an output prompt.

@StefanKarpinski
Copy link
Sponsor Member

We should probably start merging some OhMyREPL features back into the Base REPL.

@KristofferC
Copy link
Sponsor Member Author

"start"?

#19680
#18228
#17599
#17838

;)

@StefanKarpinski
Copy link
Sponsor Member

Point taken. Let me rephrase that: we should continue to merge more awesome features from OhMyREPL into the main REPL 😁

@ararslan ararslan deleted the kc/repl_nonbold branch May 26, 2017 16:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:display and printing Aesthetics and correctness of printed representations of objects. stdlib:REPL Julia's REPL (Read Eval Print Loop)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants