-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
minor copy edits and formatting for Getting Started #26439
Conversation
@@ -25,8 +25,8 @@ julia> ans | |||
3 | |||
``` | |||
|
|||
To exit the interactive session, type `^D` -- the control key together with the `d` key or type | |||
`quit()`. When run in interactive mode, `julia` displays a banner and prompts the user for input. | |||
To exit the interactive session, type `CTRL-D` (press the Control/`^` key together with the `d` key), or type |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I appreciate the more explicit phrasing, but I wonder what benefit mentioning the ^
key brings here. I thought the caret notation was purely symbolic; are there input systems with an actual "^" key used for producing control characters?
FWIW, I actually just tried literally typing ^D
(^
, Space
, Shift
+D
), ^d
(^
, Space
, D
), and combinations I expected to produce ̂D
(^
, Shift
+D
) and ̂d
(^
, D
) in the julia prompt (v0.6.0 if it matters), as well as (^
+Shift
+D
), and none of this worked. For context, I'm using a Portuguese keyboard layout which has a ̂~
key that produces combined characters like "ã" and "â" (using shift), unless a space is typed after the caret key, in which case I get "~a" and "^a". Perhaps @stevengj can provide commentary here regarding whether my input methods may have interfered.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's always 'ctrl' (or 'control') on Mac keyboards, but in menus and documentation people nearly always use ⌃ (U+2303
) or something similar, but that could be mistaken for an up arrow. You can get fonts to show keys, but I wouldn't know whether that's a good idea to rely on it. Images would be a bit more explicit: not but , although keyboards vary a lot...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to make sure we're on the same page: are you saying that there are indeed physical "^" keys in keyboards, or that there are not, but people tend to represent the control character in documentation as if such keys existed (as a shortcut, I suppose, the same way Emacs/Vim use C-x
)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1: Yes
2: they do.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, got it. Thanks for clarifying.
doc/src/manual/getting-started.md
Outdated
@@ -65,19 +66,19 @@ foo | |||
bar | |||
``` | |||
|
|||
The `--` delimiter can be used to separate command-line args to the scriptfile from args to Julia: | |||
The `--` delimiter can be used to separate command-line arguments for the script file from arguments for Julia: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Arguments to
the file sounds good to me?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I clarified my intentions a bit... :)
doc/src/manual/getting-started.md
Outdated
_/ |\__'_|_|_|\__'_| | Commit 2bb94d6 (11 days old master) | ||
|__/ | x86_64-apple-darwin13.1.0 | ||
| | |_| | | | (_| | | Version 0.7.0-DEV.4480 (2018-03-07 11:38 UTC) | ||
_/ |\__'_|_|_|\__'_| | Commit fa462ba112 (5 days old master) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can replace this full code block with:
```@eval
io = IOBuffer()
Base.banner(io)
banner = String(take!(io))
import Markdown
Markdown.parse("""
```
\$ julia
$(banner)
julia> 1 + 2
3
julia> ans
3
```
""")
```
and this will be generated when the docs are built and we never have to update this manually again (:tada: )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great idea!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Failed to evaluate `@eval` block.
ERROR: ErrorException("syntax: incomplete: invalid string syntax")
Good thing we have |
Okay, this works locally
|
Good thing you are working on adding it back ;) |
Do I need to do anything more towards this? |
@@ -327,7 +327,7 @@ julia> 2*Float16(4.) | |||
Float16(8.0) | |||
``` | |||
|
|||
The underscore `_` can be used as digit separator: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the previous way was better (see e.g. dotnet/roslyn#216)
I changed back the digit separator to the previous version and merged. Hope that was ok. |
I was planning on a pass through the Julia manual doing some copy-editing. The instructions said I must do a
make docs
build before making a PR. However, I tried this and after an hour or two it died in a blizzard of complaints about Fortran and OpenBLAS...So this PR hasn't been tested with
make docs
. I'll make this one PR, just in case it contains anything worth preserving.Edit: fix #26463