nushell / nushell.github.io Goto Github PK
View Code? Open in Web Editor NEWNushell's main website, blog, book, and more
Home Page: https://www.nushell.sh/book/
License: MIT License
Nushell's main website, blog, book, and more
Home Page: https://www.nushell.sh/book/
License: MIT License
When I type nushell.sh
(at least in Firefox on macOS Catalina), the page seems to end up sitting there waiting for a response. But if I type www.nushell.sh
I get an instant response. My guess is the DNS records for nushell.sh
weren't set up for a naked domain to either forward to www
or to serve the same response as www
.
cc @Aloso who was working to improve this.
Looks like tables are a bit better, but not quite lined up, at least on my Samsung Galaxy S10.
Here's what it looks like for me:
This happens if there's a backslash at the end of the directory (as is included by tab autocomplete).
Steps to replicate:
mkdir Thing.Stuff
cd Thing.Stuff\
(note the backslash at the end)This can be worked around by removing the backslash at the end, but that also creates the issue that if you wanted to cd to Thing.Stuff\Misc
, that will also cause a Parse error.
When trying to find an analog for a Bash for
, I searched for for
, loop
, and iteration
in the Nushell docs, but came up short ... can we add something to make it a bit easier to find each
?
The instructions to install nushell
using Winget reference an incorrect package name nu
.
The correct package name is nushell
- the website and book documentation should be updated to reflect this.
As in title: I'm getting an error where CORS blocks JQuery so I can't browse the quick reference docs for the built-in commands. :/
https://www.nushell.sh/book/working_with_tables.html#changing-data-in-a-table
We can use the add command to add a new column to the table. Let's look at an example:
This goes on to give an example that adds a new row using the insert
command.
(I would try to work out the commands and suggest some changes, but I don't have time right now and wanted to log the issue.)
We should document the nu equivalents to jq
idioms. As a deadline strapped developer I greatly appreciate this kind of focused documentation. It empowers me to solve a familiar problem in unfamiliar territory.
I love the "Coming from Bash" documentation and think long term a jq equivalent would be nice.
Then, folks could easily map from the 10 year old Stack Overflow answer to the brave nu world.
imagine post 1.x makes the most sense too. Once syntax and everything is stable enough!
jq has an official tutorial. We could write an example in nu.
In the introduction section, the sys
command output is:
> sys
─────────┬─────────────────────────────────────────
host │ [row 7 columns]
cpu │ [row cores current ghz max ghz min ghz]
disks │ [table 2 rows]
mem │ [row free swap free swap total total]
net │ [table 11 rows]
battery │ [table 1 rows]
─────────┴─────────────────────────────────────────
But the output of sys
on a fresh installation (0.33.1) with the default setup is:
> sys
───┬────────────┬───────────┬──────────┬────────────┬──────────┬───────────
# │ host │ cpu │ disks │ mem │ temp │ net
───┼────────────┼───────────┼──────────┼────────────┼──────────┼───────────
0 │ [row name │ [table 12 │ [table 2 │ [row │ [table 4 │ [table 19
│ os version │ rows] │ rows] │ total free │ rows] │ rows]
│ kernel │ │ │ swap total │ │
│ version │ │ │ swap free] │ │
│ hostname │ │ │ │ │
│ uptime │ │ │ │ │
│ sessions] │ │ │ │ │
───┴────────────┴───────────┴──────────┴────────────┴──────────┴───────────
This is because pivot_mode
by default never
.
The book should probably use the default setup for its examples.
Contributors Page has a link to the contributors book git repo instead of the book itself.
rust-lang/regex
to the book and contributor book.hi!
https://www.nushell.sh/ says at the bottom
If you have suggestions or want to change something please give us feedback
it would be nice if it linked/pointed to where that is
I found it because I was looking for a place to ask some basic questions about nushell without filling an issue and only found that on the site.
If there's a community (discord/slack/forum) it could point there or to a page where it lists the best place to provide feedback for the site and for nushell
I'm willing to make a PR once I know what should be done, let me know :)
The current section on strings in the "Types of data" page could use some additions.
There are two existing issues that seem related to this:
Both of these commands are commonly used with strings.
It seems to me that working with strings is a major part of a shell, should a top-level page about strings be created? It could contain the following topics:
char
commandstr
commandThe current section on strings in "Types of data" could redirect the reader to the top-level page.
I'm interested in working on this.
I think having installation instructions directly on the front page would be ideal. Every extra step to do something often lowers conversion.
Is there a list of all the names of characters that char
can print documented? Might be nice to have a handy reference.
Here's a picture from one screenshot:
Asking around on twitter, I was told:
"Ok so I assumed this was ligatures from ---- not the actual characters for those lines. The misalignment on Android comes from the droid sans mono font not having those characters, causing it to fall back to noto sans symbols, which has different widths.
Which means font-variant-ligatures: none
will have no effect, but using a web font to force it to use one of the other fonts in your list before it falls back to monospace will fix this for you"
So it sounds like we need to set better fallback fonts so that Android (and other browsers with the same issue) don't fallback to the wrong font.
cc @ibraheemdev
Tried to install the latest 0.9.0 Release
according to the documentation https://www.nushell.sh/installation.html but got an error:
❯ cargo install nu --all --features=stable
error: Found argument '--all' which wasn't expected, or isn't valid in this context
Did you mean --all-features?
USAGE:
cargo install --all-features
For more information try --help
Command cargo install nu --all-features --features=stable
works fine.
Please update the documentation page.
@elferherrera is currently working on adding Nushell support in Python's virtualenv
and there's a general pattern for working with virtual environments, which was mentioned in the changelog.
We have some example scripts for that in the nu_scripts
repo.
Right now, though, there's no way for users to discover those resources, unless they dig through old issues or follow updates in the nu_scripts
repo.
I would like to document this in the Environment
page in the Nu book.
I'm planning on:
load-env
for activating and deactivating environments.nu_scripts
repo for more examplesIs there anything else anyone would like to have in the docs about virtual environments?
I'd like to improve the page layout and am opening this issue to discuss the proposed changes.
650px
to 900px
and16px
to 18px
nu>
logo monospaced<pre>
blocks━━━━━━━━━━┯━━━━━━━━━━┯━━━━━━━━━━━━━
│ │
──────────┼──────────┼─────────────
│ │
━━━━━━━━━━┷━━━━━━━━━━┷━━━━━━━━━━━━━
@font-face
have the wrong weight and style, fix it.local(...)
to use system fonts instead of web fonts, if they are available in the clientOpen Sans Semibold
and Open Sans Semibold Italic
, since they aren't used. Then the remaining fonts are:
user-scalable=no
, which is discouraged. Remove it:focus
CSS states for nicer keyboard navigationWe should do a pass over the site with something like https://chrome.google.com/webstore/detail/wcag-color-contrast-check/plnahcmalebffmaghcpcmpaciebdhgdf?hl=en and update the colors to have better contrast. I did a quick one and noticed a few aren't quite high enough for clear readability.
What would really help me with getting into Nu is having any easy reference to all the commands.
This should be the place: https://www.nushell.sh/book/command_reference.html
But this page has some issues:-
alias
. There is no anchor link to this command! I can't bookmark a link to it. This makes building a commands index hard, of course.Examples
section has the exact same link! Scroll to the bottom of the page, and click on the for
command's Examples
anchor link (when the green #
appears). You will be taken to the top of the page, to the first instance of what this link links to.Usage
, Parameters
, Flags
.Examples
, Usage
, Parameters
, Flags
sections, so long as the links were specialized by the command name.str camel-case
and for
doing at the bottom of the page, and not in alpahbetical order like the others?str camel-case
is an outlier (along with a few others) in that it has a repeated title, and the second one has an associated anchor link.It's a package manager for windows, which I like to use to install apps: https://chocolatey.org. Unfortunately, I have never published something there myself, so don't know how to do that.
I just wanted to ask if there is support/if it would be possible to add support for RSS or atom on the blog? The old blog had support for that I think. I understand that this is probably rather niche and not a priority for the project if it is possible.
I noticed some people talking about how tables looked in different browsers on Reddit, and then when I checked nushell.sh I noticed a similar thing. Here's what I see in Firefox+Windows:
I wonder if there's a way to either render this the same across browsers, or if maybe we should just put an image there instead.
Going to https://www.nushell.sh/ and searching for "install" came up empty. The top nav bar also doesn't include a link to "download". It's only now that after opening up this issue that I'm seeing the "get" link.
I think I was thrown off by the big green "blog" button, which feels like the main call to action in the navigation menu but didn't point me to what I wanted.
The reason why I'm bringing this up is because just like when logging in on a website I'll search for "login" on the page, when installing software I'll be looking for "install" on the page. Hope this is useful feedback!
From https://www.nushell.sh/book/en/installation.html:
For Rust to work properly, you’ll need to have a compatible compiler suite installed on your system. These are the recommended compiler suites:
. . .
. . .
. Windows: Visual Studio Community Edition
For Windows, when you install Visual Studio Community Edition, make sure to install the “C++ build tools” as what we need is link.exe which is provided as part of that optional install. With that, we’re ready to move to the next step.
Keep in mind that Visual Studio Community Edition with just the C++ build tools (unless I'm doing it incorrectly) is a 10.4 GB installation! I'll stick with Vim, thanks.
Since I used scoop.sh to install nu, I already have gcc installed. I'll see if I can just stick with that, but I would recommend that your directions remove such a big ask. It runs very counter to the entire philosophy of nu advertised on the website to ask newcomers to get such a massive dependency.
The str
commands are documented in the command_reference page starting here https://www.nushell.sh/book/command_reference.html#str-camel-case. There are simple examples on how to use it, with the only ones being documented are echo "sample text" | str command
several of these commands list ...args
as "...args: optionally command by column paths". There are no examples showing how one uses the optional arguments and how to use the command on structured data.
This issue was made because I wanted to list and then delete file names containing a substring I had tried the following.
ls | str contains 'old'
str contains 'old' ls.name
ls | get name | str contains 'old'
however, none of the solutions above worked. This is an example of using structured data and I don't know how to approach it.
nushell is gaining momentum, and I think it's time for our landing page to get a refresh. Let's modernize it, highlighting nushell's great features, and just making nushell really shine 🌟
Some ideas:
https://www.nushell.sh/commands/from-csv.html
I'd expect --headerless
to mean "there's no header row, treat the first row as data". Testing in the web demo supports that expectation. In the sample output shown on the doc page, though, it's not only discarded the first (header) row completely, but also discarded the first data row too.
I was learning nu shell using Nu Book and noticed that documentation specific to strings is missing.
Nu Book should have a section about strings: "Working with strings" or "Working with text"
There are some examples of it but they are all scattered in topics about other subjects.
The idea is to show how nu could be used instead of sed/awk to do text processing.
Suggested topics:
Some of the info in Coming from bash
page and the Adding paths to your PATH
page needs to be updated to include pathvar
.
Right now we're publishing the Nu book through gitbooks, but we could look into publishing it differently, and also pull in the contributor book and cookbook.
Seems like website went down, as i think, after last commit...
On the installation page it says to run cargo install nu --all --features=stable
for an "all bells and whistles" install. But it seems there is no --all
flag in cargo. I'm new to Rust so not sure if this should be --all-features
or --features=stable
which both seem valid.
EDIT: I have copied the installation instructions from the book
The example in this page is not working: https://www.nushell.sh/cookbook/native_shell_programs.html
C:\Windows\system32> version
───┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────
# │ version │ short_c │ commit_ │ commit_ │ build_o │ rust_ve │ rust_ch │ cargo_v │ pkg_ver │ build_t │ ...
│ │ ommit │ hash │ date │ s │ rsion │ annel │ ersion │ sion │ ime │
───┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────
0 │ 0.38.0 │ e1ebd46 │ e1ebd46 │ 2021-10 │ windows │ rustc │ stable- │ cargo │ 0.38.0 │ 2021-10 │ ...
│ │ 1 │ 1d24927 │ -05 │ -x86_64 │ 1.55.0 │ x86_64- │ 1.55.0 │ │ -05 │
│ │ │ deb48ac │ 17:35:2 │ │ (c8dfcf │ pc-wind │ (32da73 │ │ 18:08:2 │
│ │ │ 758f9b4 │ 5 │ │ e04 │ ows-msv │ ab1 │ │ 3 │
│ │ │ 56a21b4 │ +00:00 │ │ 2021-09 │ c │ 2021-08 │ │ +00:00 │
│ │ │ 79065 │ │ │ -06) │ (defaul │ -23) │ │ │
│ │ │ │ │ │ │ t) │ │ │ │
───┴─────────┴─────────┴─────────┴─────────┴─────────┴─────────┴─────────┴─────────┴─────────┴─────────┴─────
C:\Windows\system32> ^sc queryex eventlog | lines | trim | parse "{key}: {value}"
error: Command not found
┌─ shell:51:32
│
51 │ ^sc queryex eventlog | lines | trim | parse "{key}: {value}"
│ ^^^^ command trim not found
I think we need to create a table to summarize the status of all the documents, so that we can translate the ones that are completed and relatively stable. Maybe a table like this:
name | status | zh-cn | ja |
---|---|---|---|
aliases.md | Finished | Translated | Untranslated |
configuration.md | In progress | Being translated by @xyz | Untranslated |
Was skimming through https://www.nushell.sh/book/command_reference.html and noticed that we're using split-row
in a few places. The more modern form is split row
.
This may mean we need to update the command docs on the main repo and republish here.
It'd be nice if the websites could detect dark mode and switch to a dark theme if the mode was detected.
Online Nubook is helpful, and it would be better if we can generate a downloadable ebook so I can read it on my kindle even without network. Thanks again.
A few commands need to have their outputs updated. I was looking at prepend
, for example.
It shows:
> open continents.txt | lines
━━━┯━━━━━━━━━━━━━━━
# │
───┼───────────────
0 │ Africa
1 │ South America
2 │ Australia
3 │ Europe
4 │ Antarctica
━━━┷━━━━━━━━━━━━━━━
I believe this is old and should not use the mixed table drawing or the empty header.
This probably needs to be updated in the command docs on the main repo first, and then regenerated for the website.
originally from nushell/nushell#3193
As a curious bystander I often explore a project's stated purpose.
nu's core repository has one philosophy.md
document:
https://github.com/nushell/nushell/blob/318d13ed58fc749626f985b65be54b9b14896580/docs/philosophy.md
The contributor book here has one as well:
https://github.com/nushell/nushell.github.io/blob/ff405d6de3bd0513e9a5ff0bb7137f05e17cf295/contributor-book/philosophy.md
This issue tracks consolidating those documents into one.
I was thinking we might want to link to this github from the bottom of pages in case people have things they want to change or suggest.
It would be great if the README contained a brief explanation of
When making a custom command (e.g., def foo [x: <some-type>] { })
, it's not clear which types are accepted in the signature. We should put into the book which values of <some-type>
are accepted.
The accepted values are in the source code here: https://github.com/nushell/nushell/blob/c2bad7112358c472406d23dd95403f3f610a048f/crates/nu-parser/src/parser.rs#L2008
Add an analytics ID to the config file
The book does a great job on the How. It explains well how Nushell works. But it lacks a bit on the Why. The Introduction hints on it but it seems to get lost on the surface, e.g. "modern style of development", "modern feel", "UX polish". New users tend to want to know the Why first before the How.
The Philosophy section of the Contributor Book does a great job on the Why. But it's usually read only long after the How and only by people interested in the underlying details.
I'd like to propose moving the Why before the How. This means moving the Philosophy section into the main book before any concrete "Usage" sections. It would probably make sense to put it just after the Installation section.
There is an existing configuration setting to enable case-insensitive completions (source code):
[line_editor]
completion_match_method = "case-insensitive"
However, this setting is not currently documented on the Configuration page of the Nu Book.
Add a row to the Line Editor section of the Configuration page - something like:
Name | Purpose | Value Type | Options |
---|---|---|---|
completion_match_method | Enable case-insensitive completions; completions are case-sensitive by default | string | case-insensitive |
The header of the Line Editor section currently reads:
The
[line_editor]
section of theconfig.toml
controls how our line editor,rustyline
behaves. These configuration settings are specific to therustyline
crate we use.
The completion_match_method
setting is not provided by rustyline
- it's implemented directly by Nushell. Should the wording of the section header be changed, as well?
Based on Documenting your command, I can't create a top description on my custom commands.
In command line, when I press Enter my comment is simply ignored as expected, and in config.toml when I use multi-line comment ("""), still don't have it printed in my command --help.
# | name | os version | kernel version |
---|---|---|---|
0 | Ubuntu | 20.04 | 5.8.0-44-generic |
version | 0.28.0 |
---|---|
short_commit | 22ae962b |
commit_hash | 22ae962b573e1cd9cdf8db5c0278759132c3b6f3 |
commit_date | 2021-03-09 10:40:17 |
build_os | linux-x86_64 |
rust_version | rustc 1.50.0 (cb75ad5db 2021-02-10) |
rust_channel | stable-x86_64-unknown-linux-gnu (default) |
cargo_version | cargo 1.50.0 (f04e7fab7 2021-02-04) |
pkg_version | 0.28.0 |
build_time | 2021-03-09 18:50:29 |
build_rust_channel | release |
features | clipboard-cli, ctrlc, default, directories, dirs, ichwh, ptree, rustyline, term, trash, uuid, which, zip |
PS: I restart nushell after each config.toml modification.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.