profile
viewpoint
Jonathan Turner jonathandturner @Microsoft New Zealand jonathanturner.org Current: @azure and @nushell. Previously: @rust-lang, PM for TypeScript @microsoft.

AzureAD/microsoft-authentication-library-for-js 1194

Microsoft Authentication Library (MSAL) for JS

jonathandturner/AudioScope-ng2 32

AudioScope demo written in Angular 2 + TypeScript

jonathandturner/actress 4

Experimenting with a simple actor system in Rust

jonathandturner/api-extractor.com-website 0

GitHub Pages website for api-extractor.com

jonathandturner/azure-functions-rs 0

Create Azure Functions with Rust!

jonathandturner/azure-rest-api-specs 0

The source for REST API specifications for Microsoft Azure.

jonathandturner/azure-sdk-for-js 0

An isomorphic javascript sdk for Azure services

jonathandturner/blog.rust-lang.org 0

The Rust Programming Language Blog

create barnchjonathandturner/azure-sdk-for-js

branch : msal_wip6

created branch time in 14 hours

push eventnushell/nushell

Leonhard Kipp

commit sha 400bc97e353f3a89a898dbb789a447904d7f0496

Add parser improvements (#2679) * Add parser improvements Previously everything starting with "$" was parsed as a column path. With this commit applied, the lite_arg starting with $ is parsed as the most appropriate thing - $true/$false ==> Expression::Boolean - $(...) ==> Invocation - $it ==> ColumnPath - Anything with at least one '.' ==> ColumnPath - Anything else ==> Variable * Ignore failing tests

view details

push time in a day

PR merged nushell/nushell

Add parser improvements

Previously everything starting with "$" was parsed as a column path. With this commit applied, the lite_arg starting with $ is parsed as the most appropriate thing

  • Anything containing ".." ==> Range
  • $true/$false ==> Boolean
  • $(...) ==> Invocation
  • $it ==> ColumnPath
  • Anything with at least one '.' ==> ColumnPath
  • Anything else ==> Variable

One could argue that $it should be parsed as a variable (There is even Expression(Variable::It)). Implementing that would require more changes, as other parts rely on $it being a column path.

Please note: Some tests of the alias command, regarding the deduction are failing by applying this commit. As requested in the discussion of PR #2486, I will pick the PR in pieces and open PR's for the pieces individually. This is the first. As soon as all pieces have landed, the tests will work again.

+95 -39

1 comment

4 changed files

LhKipp

pr closed time in a day

pull request commentnushell/nushell

Add parser improvements

Yeah, this looks a bit cleaner. Cool

LhKipp

comment created time in a day

push eventnushell/nushell

Joseph T. Lyons

commit sha 2fd464bf7b78ffdd1ee8ebcac29108a515e4389f

Refactor `to md` and Add Padding for Pretty Flag (#2678) * refactor and cleanup to md * Add padding around values in each row * Add padding to test * Update code to satisfy Clippy and pass other failing tests

view details

push time in a day

PR merged nushell/nushell

Refactor `to md` and Add Padding for Pretty Flag

In the last PR I opened for to md, I mentioned that I didn't quite like the fact that I had a lot of copy and pasting going on. This PR fixes the copy and pasting. In order to compute the final width of a column for the -p flag, you must run through the whole table and get the longest string for each column. Then you have to go through the table again and pad each string. There is some encoding going on in the to md command that I was doing twice for each string, but I corrected this by storing the encoded values into vector, to remove the encoding that was happening twice.

The second thing this PR does is adds a single space of padding to the left and right side of each column. Here are couple of popular Markdown table formatting plugin:

  1. For Atom, there is Markdown Table Editor, which formats Markdown tables to look like this:

Screen Shot 2020-10-17 at 7 26 08 PM

I used this package extensively

  1. For VS Code, there is Markdown Table Formatter, which formats Markdown tables to look like this:

Screen Shot 2020-10-17 at 7 25 52 PM

Both of these tables are nearly identical, both have the padding on the sides of the columns, so I felt it would be good to add this to the -p flag on to md:

Screen Shot 2020-10-17 at 7 37 44 PM

+90 -55

1 comment

2 changed files

JosephTLyons

pr closed time in a day

pull request commentnushell/nushell

Refactor `to md` and Add Padding for Pretty Flag

Thanks!

JosephTLyons

comment created time in a day

push eventjonathandturner/azure-sdk-for-js

Jonathan Turner

commit sha 2b3b667b27847233367688c8fd350396406495d3

Further improve client secret and msal client

view details

Jonathan Turner

commit sha bb8eff08b4d64655f734fa8fedb8a4a76d504827

Further improve client secret and msal client

view details

push time in 2 days

push eventjonathandturner/azure-sdk-for-js

Jonathan Turner

commit sha 8430a1b00c5a4351eff8b635d7032255462e2f0a

Fix lints

view details

push time in 2 days

pull request commentnushell/rfcs

Type deduction RFC

I think this looks good. I'm okay landing it as is. Other Nushell team folks, how do you feel?

  • [ ] @fdncred
  • [ ] @andrasio
LhKipp

comment created time in 4 days

push eventnushell/this_week_in_nu

Michael Nitschinger

commit sha 775f9ef4fc9804a18ca658a4c576b87999102f0e

Update This week in Nu 60.md the link doesn't work otherwise

view details

Jonathan Turner

commit sha 83e354ccb871372ba397d4607d980646cc2caee2

Merge pull request #2 from daschl/patch-1 Update This week in Nu 60.md

view details

push time in 4 days

PR merged nushell/this_week_in_nu

Update This week in Nu 60.md

the link doesn't work otherwise, ping @jonathandturner

+1 -1

1 comment

1 changed file

daschl

pr closed time in 4 days

pull request commentnushell/this_week_in_nu

Update This week in Nu 60.md

Oops! Good catch

daschl

comment created time in 4 days

push eventnushell/this_week_in_nu

Jonathan Turner

commit sha 849c6f9b324500e8216425f2f9842df401cef267

Create This week in Nu 60.md

view details

push time in 4 days

push eventnushell/book

Michiel W. Beijen

commit sha 683b030fccbc92bb6ba4d0ccd6ff51d1342bcf34

error wit file extension

view details

Jonathan Turner

commit sha df3fd1eba0d8615a94f12692eba542dfec718ec8

Merge pull request #133 from mbeijen/patch-1 error with file extension

view details

push time in 4 days

PR merged nushell/book

error with file extension
+1 -1

1 comment

1 changed file

mbeijen

pr closed time in 4 days

pull request commentnushell/book

error with file extension

Thanks!

mbeijen

comment created time in 4 days

push eventnushell/nushell.github.io

Jon Grythe Stødle

commit sha d9f97347e0b118792bbbcd84bf8377cea39c2b04

Update commands Updates commands to version `0.20.0` from `0.18.1`

view details

Jon Grythe Stødle

commit sha 54d24c1c6a0d91318f4ea5bf1a3b26fa1eae5287

Update `ls` command Updates the quick command reference text for the `ls` command.

view details

Jonathan Turner

commit sha 17ddeb40f06bf7c90b217313a14e4b58e52b8449

Merge pull request #62 from jonstodle/update-commands Update commands to `0.20.0`

view details

push time in 4 days

PR merged nushell/nushell.github.io

Update commands to `0.20.0`

Updates the commands to version 0.20.0 by running update_commands.py.

Also manually updates the ls command.

+212 -69

1 comment

65 changed files

jonstodle

pr closed time in 4 days

pull request commentnushell/nushell.github.io

Update commands to `0.20.0`

Thanks!

jonstodle

comment created time in 4 days

Pull request review commentnushell/nushell

Add rounding functionalties

+use crate::commands::math::utils::run_with_function;+use crate::commands::WholeStreamCommand;+use crate::prelude::*;+use bigdecimal::One;+use nu_errors::ShellError;+use nu_protocol::{Primitive, Signature, UntaggedValue, Value};++pub struct SubCommand;++#[async_trait]+impl WholeStreamCommand for SubCommand {+    fn name(&self) -> &str {+        "math ceil"+    }++    fn signature(&self) -> Signature {+        Signature::build("math celi")+    }++    fn usage(&self) -> &str {+        "Applies the ceil function to a list of numbers"+    }++    async fn run(+        &self,+        args: CommandArgs,+        registry: &CommandRegistry,+    ) -> Result<OutputStream, ShellError> {+        run_with_function(+            RunnableContext {+                input: args.input,+                registry: registry.clone(),+                shell_manager: args.shell_manager,+                host: args.host,+                ctrl_c: args.ctrl_c,+                current_errors: args.current_errors,+                name: args.call_info.name_tag,+                raw_input: args.raw_input,+            },+            ceil,+        )+        .await+    }++    fn examples(&self) -> Vec<Example> {+        vec![Example {+            description: "Apply the ceil function to a list of numbers",+            example: "echo [1.5 2.3 -3.1] | math ceil",+            result: Some(vec![+                UntaggedValue::int(2).into(),+                UntaggedValue::int(3).into(),+                UntaggedValue::int(-3).into(),+            ]),+        }]+    }+}++fn ceil_big_decimal(val: &BigDecimal) -> BigInt {+    let mut maybe_ceiled = val.round(0);+    if &maybe_ceiled < val {+        maybe_ceiled += BigDecimal::one();+    }+    let (ceiled, _) = maybe_ceiled.into_bigint_and_exponent();+    ceiled+}++/// Calculate product of given values+pub fn ceil(values: &[Value], _name: &Tag) -> Result<Value, ShellError> {+    if !values.iter()

Right, instead of passing in a slice here, operate on the InputStream itself. You can use functions like.map to apply a function to the stream of data as it passes. For this PR, that function could pattern match the values, and apply the ceil/floor/round functionality to the numeric ones.

morbatex

comment created time in 4 days

PullRequestReviewEvent

Pull request review commentnushell/nushell

Add Tau constant to math eval

 pub async fn eval( }  pub fn parse<T: Into<Tag>>(math_expression: &str, tag: T) -> Result<Value, String> {-    match meval::eval_str(math_expression) {+    let mut ctx = meval::Context::new();+    ctx.var("tau", std::f64::consts::TAU);

Looking at the error messages, it seems that this constant isn't available in stable Rust. I wonder if there are other ways to get to it (or if you could add it to the meval library.

rjboas

comment created time in 4 days

PullRequestReviewEvent

push eventnushell/nushell

Luccas Mateus

commit sha e626522b3aee762fac4eed652d44a2d2d71f4962

LS support for other number formatting (#2650) * make sort-by fail gracefully if mismatched types are compared * Added a test to check if sorted-by with invalid types exists gracefully * Linter changes * removed redundant pattern matching * Changed the error message * Added a comma after every argument * Changed the test to accomodate the new err messages * Err message for sort-by invalid types now shows the mismatched types * Lints problems * Changed unwrap to expect * Added the -f flag to rm command Now when you a use rm -f there will be no error message, even if the file doesnt actually exist * Lint problems * Fixed the wrong line * Removed println * Spelling mistake * Fix problems when you mv a file into itself * Lint mistakes * Remove unecessary filtering in most cases * Allow the removal of sockets * Conditional compilations to systems without socket * Add a size-format option to ls command * Added kib and mib formating * Make patterns lowercase * New subcommand to format, filesize * Forgot the linter once more * Remove the ls changes since its no longer needed * CI mistakes * Lint stuff * Fix lint * Added formatting for bytes * fix lint * Changed the usage comment

view details

push time in 4 days

PR merged nushell/nushell

LS support for other number formatting

I think it Closes #2127

Added a flag to the ls command(--size-format/-f) that allows you to define a custom format, currently there are only the file formats, although in the issue related @fdncred talked about other formats that didn't involved a filesize format, so i would like his input on this. I have one big problem with my code currently, which is the "convert_bytes_to_string_using_format" function, which i think has the potential to get quite big, in a file(filesystem_shell.rs) which i think already is too big to be easily understandable + i don't know if the filesystem_shell is the best file to put this function, given that it only relates to the ls command. Should i put it in the ls.rs file and just import in the filesystem_shell? Any help would be appreciated.

This is an example of the new flag. The todo file aparently has 0 size so it becomes this "-" image

+226 -1

20 comments

6 changed files

luccasmmg

pr closed time in 4 days

issue closednushell/nushell

LS support for other number formatting

Is your feature request related to a problem? Please describe. No

Describe the solution you'd like Current ls looks like this:

────┬────────────────────┬──────┬──────────┬─────────────
 #  │        name        │ type │   size   │  modified
────┼────────────────────┼──────┼──────────┼─────────────
 10 │ CODE_OF_CONDUCT.md │ File │   3.5 KB │ 6 hours ago
 11 │ CONTRIBUTING.md    │ File │   1.4 KB │ 6 hours ago
 12 │ Cargo.lock         │ File │ 121.5 KB │ 6 hours ago
 13 │ Cargo.toml         │ File │   4.7 KB │ 6 hours ago
 14 │ LICENSE            │ File │   1.1 KB │ 6 hours ago
 15 │ Makefile.toml      │ File │    473 B │ 6 hours ago
 16 │ README.build.txt   │ File │    193 B │ 6 hours ago
 17 │ README.md          │ File │  16.3 KB │ 6 hours ago

I'd like to be able to specify how the bytes are displayed whether it's 16.3 KB or 16279 or 16,279 or even perhaps 15.9 KiB or 0.015 MiB. The point is, I'd like more control over how these numbers are represented.

Describe alternatives you've considered ls | each {to json} | each {from json}

 #  │        name        │ type │  size  │             modified
────┼────────────────────┼──────┼────────┼───────────────────────────────────
 0  │ .azure             │ Dir  │      0 │ 2020-07-06 13:27:12.875672900 UTC
 1  │ .cargo             │ Dir  │      0 │ 2020-07-06 13:27:12.877672400 UTC
 2  │ .circleci          │ Dir  │      0 │ 2020-07-06 13:27:12.879672700 UTC
 3  │ .dockerignore      │ File │      8 │ 2020-07-06 13:27:12.880672900 UTC
 4  │ .editorconfig      │ File │    236 │ 2020-07-06 13:27:12.881673800 UTC
 5  │ .github            │ Dir  │      0 │ 2020-07-06 13:27:12.885672300 UTC
 6  │ .gitignore         │ File │    303 │ 2020-07-06 13:27:12.888672800 UTC
 7  │ .gitpod.Dockerfile │ File │    302 │ 2020-07-06 13:27:12.889672500 UTC
 8  │ .gitpod.yml        │ File │    891 │ 2020-07-06 13:27:12.890673300 UTC
 9  │ .theia             │ Dir  │      0 │ 2020-07-06 13:27:12.892672800 UTC
 10 │ CODE_OF_CONDUCT.md │ File │   3520 │ 2020-07-06 13:27:12.894672900 UTC
 11 │ CONTRIBUTING.md    │ File │   1403 │ 2020-07-06 13:27:12.895670800 UTC
 12 │ Cargo.lock         │ File │ 121461 │ 2020-07-06 13:27:12.897670800 UTC
 13 │ Cargo.toml         │ File │   4721 │ 2020-07-06 13:27:12.898671800 UTC
 14 │ LICENSE            │ File │   1113 │ 2020-07-06 13:27:12.899673 UTC
 15 │ Makefile.toml      │ File │    473 │ 2020-07-06 13:27:12.900683400 UTC
 16 │ README.build.txt   │ File │    193 │ 2020-07-06 13:27:12.901671700 UTC
 17 │ README.md          │ File │  16279 │ 2020-07-06 13:27:12.902672500 UTC

Additional context N/A

closed time in 4 days

fdncred

pull request commentnushell/nushell

LS support for other number formatting

This looks good, thanks for putting it together!

luccasmmg

comment created time in 4 days

PR opened Azure/azure-sdk-for-js

Reviewers
[Identity][DRAFT] Update how we're working with MSAL

This updates a few parts of how we're connecting with MSAL:

  • It moves away from letting users pass in their own persistence plugin, as this could be error prone and a security issue. Instead, users can say that they want persistence and what authentication record to use, and the rest is handled internally.
  • We move to beta 11 of msal-node, which automatically does the reading and writing from persistent cache, if available
  • I've also begun adding support for the confidential client functionality, though currently the only piece is an extra method in the msalClient which can handle initializing the confidential client
  • Added caching to device code credential

I may be forgetting something, but that's the gist.

A few things to look at:

  • The current logic will attempt to read from the cache first. If it can't, or the cache isn't available, it then switches to the credential's logic (like asking for the device code in DCC, etc). This helps cut down on duplicate code, removes the need for a parent class with unexposed methods. In its place, it uses an exception as part of the expected flow if a cache isn't available. If that's okay, great, just wanted to confirm.
  • If this looks good I'll start converting our confidential client credentials over to use MSAL
  • IBC for browsers is still the old MSAL, but we can transition it as well.

Adding Scott for identity logic. Adding Brian to confirm this method is okay with the guidelines. If not, we can find a different approach.

cc @schaabs @bterlson

+389 -242

0 comment

9 changed files

pr created time in 5 days

push eventjonathandturner/azure-sdk-for-js

Wei Dong

commit sha 2c82ded02961274838a31d8ed1f982ffab15b70c

Subscription release (#11773) * Generated from 2174f01d50fead9cd9fe3fa9d193714217c9ce4a * bump version Co-authored-by: SDK Automation <sdkautomation@microsoft.com>

view details

colawwj

commit sha 76154889a4de64bf0705f36a4daa2408d3bba93c

Sdk automation/@azure arm kusto (#11776) * Generated from 107bc96b5f9b28633b5f99549f983421e66d8ddc * version update Co-authored-by: SDK Automation <sdkautomation@microsoft.com>

view details

Daniel Rodríguez

commit sha 4cf3b9cb9d483bf10ade684333d9ab115a7a5fb0

[KeyVault Keys] Fixed the rollup warnings (#11549) * wip * small lint fix * moved the models out of the algorithms files * cleanup after moving the models * made an oversight locally. CI was there to help me. Assertions was needed on algorithms.browser.ts

view details

Nick Guerrera

commit sha 3a5166eaa690f72386b2d0dbc4d071fe5198e359

Enable live tests for schema registry (#11728)

view details

Mark Wolff

commit sha 57911f67213415da12be29d91e22abae90eeaf03

monitor: changelog update for preview.6 (#11746)

view details

Sarangan Rajamanickam

commit sha 74476b3ad90051f7a59b2f6eca3c435c62e549da

Make BufferedSender an interface and Hide the Constructor (#11785)

view details

Azure SDK Bot

commit sha ebb7bf80bc48d35ce9712ce95dadcdea80c27738

Increment version for monitor releases (#11783) * Increment package version after release of azure-monitor-opentelemetry-exporter * fix version constant Co-authored-by: Mark Wolff <mark.wolff@microsoft.com>

view details

Daniel Rodríguez

commit sha a6fd4a70a9b696ba4ed7c07cd25a35cc0250aa4b

[Key Vault Admin] Samples README format fix (#11781) * [Key Vault Admin] Samples README format fix Christopher Scott found a bug in our readme! * Updating the readme in the javascript folder

view details

Mohsin Mehmood

commit sha e961914efb60481f159f5b98fa37edcc22e095ba

ServiceBus remove InternalReceiveMode usage (#11755) Co-authored-by: Mohsin Mehmood <mohsin85mehmod@gmail.com>

view details

Jeremy Meng

commit sha 5ce310cb374bdf79afee45323f0a93b52994166a

[MetricsAdvisor,test] Fix listing datafeed live tests (#11787) We have a scenario to rename the datafeed so the listing by the "js-test" prefix would only return one result thus break listing tests' assumption. Fixed by moving listing to after creating three data feeds so we still have two data feeds with "js-test" prefix.

view details

Azure SDK Bot

commit sha ef0323ba33d24091dd91c05bcdc03e1f531c9a92

Sync eng/common directory with azure-sdk-tools for PR 1081 (#11788) Sync eng/common directory with azure-sdk-tools for PR https://github.com/Azure/azure-sdk-tools/pull/1081 See [eng/common workflow](https://github.com/Azure/azure-sdk-tools/blob/master/eng/common/README.md#workflow)

view details

Qiaoqiao Zhang

commit sha 8a196d342998268646b76b0e70868403c1ca6d50

release-arm-billing-with-new-generator (#11525) Co-authored-by: diberry <diberry@microsoft.com>

view details

Qiaoqiao Zhang

commit sha 5afbd604518e823894361bd9cab99867f85a91d9

release-mgmt-iothub-resolve-issue-#11341 (#11382)

view details

colawwj

commit sha 4399def77c6dfae4cc90fb31efa77182083a5e87

Sdk automation/@azure arm azurestackhci (#11775) Co-authored-by: SDK Automation <sdkautomation@microsoft.com>

view details

Lin Jian

commit sha 0a567a0b501d2ee68477d8bf9f71b0a99327e9ef

[storage] stg74 (#11459) * [storage][stg74] swagger update (#11171) * build:autorest * f7425b8 * update service and pacakge versions * queue updateMessage protocol layer breaking change * createPermissionOperationSpec.isXML=false * regenerate with 3360920245f8c06e10f5e349ce3dca5e4d10372e * fix ae-forgotten-export Co-authored-by: Lin Jian <ljian3377@gmail.com> * swagger-regenerate: 196d5c1 * smb multi-channel (#11178) * [Storage] Feature - Recursive ACL (#9689) * Sdk automation/@azure arm operationalinsights (#10935) * Generated from ba891b7274af8cb22ee173e1998b4145d2d8d98b Adding a point get. * version 4.0.0 Co-authored-by: SDK Automation <sdkautomation@microsoft.com> * Increment package version after release of azure-cosmos (#11311) * [Text Analytics] Ignore document index when parsing opinion pointers (#11302) * [Text Analytics] Ignore Document Index * adding a test * update tests * add recordings * [Text Analytics] Update release date (#11313) * [Text Analytics] Update release date for 5.1.0-beta.1 * format * [core-http] Move challenge based auth to core-http (#11226) * Begin move of challenge-based auth * Begin move of challenge-based auth * Remove keyvault-common * Update paths * Fixing paths after removing keyvault-common * fixed bad dist-esm index.js references * Update paths * Update docs * Add mock tests * Add mock tests Co-authored-by: Daniel Rodríguez <sadasant@gmail.com> * Revert "[core-http] Move challenge based auth to core-http (#11226)" (#11320) This reverts commit 43033ff0571913a1301200ddd358546c6818fb7f. * [AnomalyDetector] Update AnomalyDetector README (#11110) * Update AnomalyDetector README * Update pto beta * Update changelog * Address PR comments * Replaced relative link with absolute links and remove locale (#11317) Replaced relative link with absolute links and remove locale * Enable the link check on aggregate-report (#11330) * Increment package version after release of azure-ai-text-analytics (#11315) * [Tables] Enable recorded tests in CI (#11238) * Enable recorded tests in CI * Update test script * Add pollyfill * [Anomaly Detector] Add sample snippet to README (#11335) * Add samples to readme * Update changelog date * [Core-http] Support xml namespaces (#11201) * Prototype xmlns * Update prototype * Additional tests * Address PR comments * formatting * Apply changes to core-client * Address comments * update core-client api-extractor * use getXmlObjectValue * Increment package version after release of azure-ai-anomaly-detector (#11340) * [event-hubs] Update docs to mention the checkpoint store updates made when the subscription is closed. (#11345) As part of investigating #11316 we found it was non-obvious that we would be using the checkpoint store when closing. The reason we use it is when we close the subscription we also mark, in the checkpoint store, that the partitions are abandoned. This lets other consumers more quickly pick up abandoned partitions rather than forcing them to wait for an expiration interval and discover it. Fixes #11316 * Add testcases for handling odata (#11321) * Add testcases for handling odata * Formatting code * PR Comments * Minor Formatting * Update sdk/search/search-documents/src/odata.ts Co-authored-by: Jeff Fisher <xirzec@xirzec.com> * Update sdk/search/search-documents/src/odata.ts Co-authored-by: Jeff Fisher <xirzec@xirzec.com> Co-authored-by: Jeff Fisher <xirzec@xirzec.com> * release arm-netapp (#10849) * release arm-netapp * Generated from efcb7ecf4722c919d5528c53671b124046badcdb update netapp readme.java.md * version change Co-authored-by: SDK Automation <sdkautomation@microsoft.com> * Sdk automation/@azure arm hybridcompute (#11307) * Generated from a35b1cd98e20d7c9b3c4fdcb23125b7ea85acca6 add alias for auto_rev_minor_version * v2.0.0 Co-authored-by: SDK Automation <sdkautomation@microsoft.com> * [Event Grid] Remove some 'en-us' from some links (#11185) * [Identity] Fix broken eslint in the builds (#11354) * [Identity] Fix broken eslint in the builds * .eslintignore was being ignored * Feedback by Deya * [Abort Controller] Update linting and fix linting errors (#11269) * update linting and fix linting errors * update linting scripts * formatting * fix linting errors * fixes * fix * run api-extractor * include the shim files in shipped files * use the unrolledup type declarations * do not lint package.json * still lint package.json * remove the call to api-extractor from the npm build script * simplify eslint commands * only ship src types * [Identity] Idea for the Device Code Credential Use Console Feature (#11355) * [Identity] Idea for the Device Code Credential Use Console Feature * Feedback by Schaab and Vinay * [Key Vault] Use the swagger generated from the service 7.2-preview (#11370) * swagger reference to 7.2-preview/keys.json * generated update * 7.2 on keys * 7.2 preview on certs and secrets * generated files for secrets and certs * secrets and certs * sticking the swagger change to a specific commit * Add placeholder yml file for pipeline generation * Smoke test failure due to rollup peer dependency error (#11372) * Change to move @rollup/plugin-json as dev dependency * Add client libraries for Azure Communication Services (#11385) * Add Communication service mapping * Communication - Add code owners and label triggers (#11401) * Communication - Add code owners and label triggers * [ESLint Plugin] fix docs link (#11400) * Increment package version after release of azure-keyvault-admin (#11216) * Sync eng/common directory with azure-sdk-tools repository for Tools PR 1022 (#11347) * Disable smoke test for storage-blob-changefeed (#11406) * [Core paging] Update linting scripts and auto linting (#11274) * [Core paging] Update linting scripts and auto linting * formatting changes * addressing Jeff's comments * fixes * turn sideEffects back on * adding comments to address Ramya's feedback * a typo * adding dist-esm/index.js back * Update sdk/core/core-paging/.eslintrc.json Co-authored-by: Ramya Rao <ramya.rao.a@outlook.com> * remove dist-esm/src from files in package.json Co-authored-by: Ramya Rao <ramya.rao.a@outlook.com> * fix package.json (#11412) * [Service Bus] Remove stream-browserify dependency (#11221) * [Core asynciterator] Update linting scripts and apply auto linting and some formatting (#11272) * update linting scripts * edits * turn off relevant rules and lint package.json back * adding .eslintrc.json * [service-bus] Fixing broken option - we renamed it to maxWaitTimeInMs a few previews back. (#11410) * Communication: fix test-resources config (#11434) * [core-http] Add NDJSON support (#11325) * [EventGrid] Add Azure Communication Service Events (#11428) This change adds typings for the new events sent by the Azure Communication Services * Sync eng/common directory with azure-sdk-tools repository for Tools PR 989 (#11214) * [Cosmos] Adding missing copyright headers (#11449) * [Service Bus] Type docs fix - Added @internal and @ignore tags for internal methods (#11427) * logger, isError, toAmqpAnnotatedMessage changed to internal * SubQueue renamed to _SubQueue and changed to internal for jsdoc * Revert "SubQueue renamed to _SubQueue and changed to internal for jsdoc" This reverts commit b97b6826d1016d5ce9d6aa25d427098d27820c56. * [Storage] Recursive ACL swagger transform patch * [Storage] Add support for recursive ACL * [Storage] Recording for recursive ACL * [Storage] Update changelog for recursive acl * [Storage] Add comments for recursive ACL parameters; Resolve review comments * Add continueOnFailure option for set AccessControlRecursive methods * Removed PathSetAccessControlRecursiveMode from public API list * Update AccessControlChangeFailure to AccessControlChangeError with typical name and message properties * Resolve build failures * Resolve build failures Co-authored-by: changlong-liu <59815250+changlong-liu@users.noreply.github.com> Co-authored-by: SDK Automation <sdkautomation@microsoft.com> Co-authored-by: Azure SDK Bot <53356347+azure-sdk@users.noreply.github.com> Co-authored-by: Deyaaeldeen Almahallawi <dealmaha@microsoft.com> Co-authored-by: Jonathan Turner <jonathandturner@users.noreply.github.com> Co-authored-by: Daniel Rodríguez <sadasant@gmail.com> Co-authored-by: Jose Manuel Heredia Hidalgo <joheredi@microsoft.com> Co-authored-by: Sima Zhu <48036328+sima-zhu@users.noreply.github.com> Co-authored-by: Richard Park <51494936+richardpark-msft@users.noreply.github.com> Co-authored-by: Sarangan Rajamanickam <sarajama@microsoft.com> Co-authored-by: Jeff Fisher <xirzec@xirzec.com> Co-authored-by: colawwj <70128817+colawwj@users.noreply.github.com> Co-authored-by: Matt Ellis <matell@microsoft.com> Co-authored-by: Daniel Rodríguez <sadasant@users.noreply.github.com> Co-authored-by: Wes Haggard <Wes.Haggard@microsoft.com> Co-authored-by: praveenkuttappan <55455725+praveenkuttappan@users.noreply.github.com> Co-authored-by: Dominik <domessin@microsoft.com> Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com> Co-authored-by: Ramya Rao <ramya.rao.a@outlook.com> Co-authored-by: Jeff Fisher <jeffish@microsoft.com> Co-authored-by: Mohsin Mehmood <mohsin85mehmood@gmail.com> * lastAccessed in BlobDownloadResponse wrapper * [storage][stg74] container restore (#11457) * interface * includeDeleted * [storage][stg74] get file range diff (#11455) * wip * circular dependency * move share, dirctory and file clients to the same file * swagger-regeneration: df297c8 * get file range diff * nit: PR comments * [storage][stg74] quick query new output format "arrow" (#11423) * quick query new outputSerialization "arrow" * for datalake, and remove preprod * [storage][stg74] Delegation SAS v2 and Directory SAS (#11395) * move under sas/ * wip * wip * test wip * autofill directoryDepth * update allow optional messageText (#11258) * [storage][stg74] 4TB file for standard account (#11177) * build:autorest * update service and pacakge versions * createPermissionOperationSpec.isXML=false * test create, resize, uploadRange for 4tb file with a preprod account * record test then manually remove preprod from recording file, fix documentation * update comments 1TB -> 4TB Co-authored-by: Lin Jian <ljian3377@gmail.com> * add set expiry (#11461) Co-authored-by: Lin Jian <ljian3377@gmail.com> * fix merge issue * Continuation Token wrapped with Error when Recursive Acl call is interrupted (#11716) * [storage][stg74] address PR comments (#11520) * wip * overload SASQueryParameters constructor * api extract * Rename leaseTime -> leaseTimeInSeconds * share lease tests * container restore test wip * restore container test fixed * fix CI * make options optional and add comments * [storage][stg74] set file tier (#11735) * format datalake * re-generate file with de8a4f0 * add set share tier * edit import * [storage] temporary fix for issue #11505 (#11737) * temporary fix for issue #11505 * format * update pacakge versions and change log (#11739) * [storage][stg74] fix ci (#11752) * use beta * fix listContainers when include = [] * fix CI * unskip quick query record & support include-leased for x-ms-delete-snapshots (#11754) * Resolve CRI failure (#11756) * fix lease test case * Record RecAcl (#11765) * [storage][stg74] test coverage improvement (#11757) * use preview for blob and use defaultCredential in datalake * use preview subscription for datalake * turn on log * throw when accountName is invalid * CONTAINER_SOFT_DELETE_ * set cors in service properties * PREMIUM_FILE_ * blob remove .only * SOFT_DELETE_ for both blob and share * unskip a tag case * unskip all f,t cases in browser * file use production subscription * add role for datalakeAccount * me * undo datalake roleAssignment * unskip blob delegation SAS cases via using DefaultCredential * add blobDataOwnerRoleId * premiumFileAccountName * me * unskip last access tracking case * me * delegation sas refactor * fix CI * getRangeListDiff .only * run all cases in file * skip getRangeListDiff in live tests * rename and add comments * last access * skip LAT * me * re-record blob delegation SAS cases * modify testutils and re-record * record for browser * me * fix CI and unskip cases * tune setProperties in IE * remove .only Co-authored-by: Lin Jian <ljian3377@gmail.com> Co-authored-by: xiaonlimsft <xiaonli@microsoft.com> Co-authored-by: changlong-liu <59815250+changlong-liu@users.noreply.github.com> Co-authored-by: SDK Automation <sdkautomation@microsoft.com> Co-authored-by: Azure SDK Bot <53356347+azure-sdk@users.noreply.github.com> Co-authored-by: Deyaaeldeen Almahallawi <dealmaha@microsoft.com> Co-authored-by: Jonathan Turner <jonathandturner@users.noreply.github.com> Co-authored-by: Daniel Rodríguez <sadasant@gmail.com> Co-authored-by: Jose Manuel Heredia Hidalgo <joheredi@microsoft.com> Co-authored-by: Sima Zhu <48036328+sima-zhu@users.noreply.github.com> Co-authored-by: Richard Park <51494936+richardpark-msft@users.noreply.github.com> Co-authored-by: Sarangan Rajamanickam <sarajama@microsoft.com> Co-authored-by: Jeff Fisher <xirzec@xirzec.com> Co-authored-by: colawwj <70128817+colawwj@users.noreply.github.com> Co-authored-by: Matt Ellis <matell@microsoft.com> Co-authored-by: Daniel Rodríguez <sadasant@users.noreply.github.com> Co-authored-by: Wes Haggard <Wes.Haggard@microsoft.com> Co-authored-by: praveenkuttappan <55455725+praveenkuttappan@users.noreply.github.com> Co-authored-by: Dominik <domessin@microsoft.com> Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com> Co-authored-by: Ramya Rao <ramya.rao.a@outlook.com> Co-authored-by: Jeff Fisher <jeffish@microsoft.com> Co-authored-by: Mohsin Mehmood <mohsin85mehmood@gmail.com>

view details

praveenkuttappan

commit sha 10de0731d96b200588cd1beb0c6860c755450042

Updated regex to pick correct package artifact (#11801) * Updated regex to pick correct package artifact

view details

Azure SDK Bot

commit sha 28120aecba6fa994f69887fd522e5f462e36d730

Increment package version after release of azure-storage-file-share (#11799)

view details

Azure SDK Bot

commit sha e0a27e75eaaa203e23217e9d7bbb1378db318f94

Increment package version after release of azure-search-documents (#11648)

view details

Nick Guerrera

commit sha ed06abfd3bcfd82085b150254777b48ba306483d

[schema registry] Omit extra record methods from deserialization (#11786)

view details

underTakerChamp

commit sha a96e79d107b337c8ba83c29d1cfce3af1402e950

added missing global varrible names (#11791)

view details

push time in 5 days

push eventjonathandturner/azure-sdk-for-js

Jonathan Turner

commit sha 9fa72cb395df046bb93f396f40c4dab6b9dc7f66

Refactor to use an MSAL-specific client

view details

Jonathan Turner

commit sha 33399761a5c54029c0d931c4efe4d4996f260278

Refactor to use an MSAL-specific client

view details

push time in 5 days

push eventnushell/nushell

Joseph T. Lyons

commit sha bf2363947b7c00b3b217781708c160f33b7e3e3e

Add pretty flag to `to md` (#2640) * First draft for adding a `pretty` flag to `to md` * rustfmt * Fix Clippy warnings * rustfmt * Using Clippy suggestion broken code, reverting and putting in a statement to ignore clippy warning * Add test for `to md -p`

view details

push time in 5 days

PR merged nushell/nushell

Add pretty flag to `to md`

This is mostly a draft for the -p flag on to md. I feel some code needs work in terms of removing repetition, but I'm not sure the best way to go about, so any advice would be great.

+171 -12

5 comments

4 changed files

JosephTLyons

pr closed time in 5 days

pull request commentnushell/nushell

Add pretty flag to `to md`

Thanks!

JosephTLyons

comment created time in 5 days

Pull request review commentnushell/nushell

Add rounding functionalties

+use crate::commands::math::utils::run_with_function;+use crate::commands::WholeStreamCommand;+use crate::prelude::*;+use bigdecimal::One;+use nu_errors::ShellError;+use nu_protocol::{Primitive, Signature, UntaggedValue, Value};++pub struct SubCommand;++#[async_trait]+impl WholeStreamCommand for SubCommand {+    fn name(&self) -> &str {+        "math ceil"+    }++    fn signature(&self) -> Signature {+        Signature::build("math celi")+    }++    fn usage(&self) -> &str {+        "Applies the ceil function to a list of numbers"+    }++    async fn run(+        &self,+        args: CommandArgs,+        registry: &CommandRegistry,+    ) -> Result<OutputStream, ShellError> {+        run_with_function(+            RunnableContext {+                input: args.input,+                registry: registry.clone(),+                shell_manager: args.shell_manager,+                host: args.host,+                ctrl_c: args.ctrl_c,+                current_errors: args.current_errors,+                name: args.call_info.name_tag,+                raw_input: args.raw_input,+            },+            ceil,+        )+        .await+    }++    fn examples(&self) -> Vec<Example> {+        vec![Example {+            description: "Apply the ceil function to a list of numbers",+            example: "echo [1.5 2.3 -3.1] | math ceil",+            result: Some(vec![+                UntaggedValue::int(2).into(),+                UntaggedValue::int(3).into(),+                UntaggedValue::int(-3).into(),+            ]),+        }]+    }+}++fn ceil_big_decimal(val: &BigDecimal) -> BigInt {+    let mut maybe_ceiled = val.round(0);+    if &maybe_ceiled < val {+        maybe_ceiled += BigDecimal::one();+    }+    let (ceiled, _) = maybe_ceiled.into_bigint_and_exponent();+    ceiled+}++/// Calculate product of given values+pub fn ceil(values: &[Value], _name: &Tag) -> Result<Value, ShellError> {+    if !values.iter()

This looks good generally. I think the one place that stood out is that you do a check here to make sure all values are an allowed type. For streams that might be very long, or not have an end, this wouldn't terminate.

Instead, you may just want to detect if a value doesn't match at the same time you're doing the mapping over the input stream. If you find something that isn't the right type, emit the error then.

morbatex

comment created time in 5 days

PullRequestReviewEvent

push eventjonathandturner/azure-sdk-for-js

Jonathan Turner

commit sha dbb22d62f9d3db5121d74fc1e10d45d0ee3476f9

Refactor to use an MSAL-specific client

view details

Jonathan Turner

commit sha 1903f19c909b2b9ecf757d4a4d529db057f1dee1

Refactor to use an MSAL-specific client

view details

push time in 6 days

pull request commentnushell/nushell

Add pretty flag to `to md`

Sure, looks good to me

JosephTLyons

comment created time in 6 days

push eventnushell/blog

Jonathan Turner

commit sha a08b1536f296ff2edf0cc1bee87af4cc3eef6b6c

Add 0.21 post

view details

push time in 6 days

push eventjonathandturner/azure-sdk-for-js

Jonathan Turner

commit sha e9342e80c9b44e31d3fb188b16f7436d0eb86ccb

Refactor to use an MSAL-specific client

view details

Jonathan Turner

commit sha d8643d9fd24a35c7812e231d7dc4582aff8ec7f7

Refactor to use an MSAL-specific client

view details

Jonathan Turner

commit sha 2f64d4fbb974804c03a855a3c3126cce903a4174

Refactor to use an MSAL-specific client

view details

push time in 7 days

created tagnushell/nushell

tag0.21.0

A new type of shell

created time in 7 days

delete tag nushell/nushell

delete tag : 0.21.0

delete time in 7 days

created tagnushell/nushell

tag0.21.0

A new type of shell

created time in 7 days

delete tag nushell/nushell

delete tag : 0.21.0

delete time in 7 days

push eventnushell/nushell

Jonathan Turner

commit sha 194782215f9773417b781af51840c036a7cd2310

Update main.wxs Rename the plugins to be the production names

view details

push time in 7 days

created tagnushell/nushell

tag0.21.0

A new type of shell

created time in 7 days

delete tag nushell/nushell

delete tag : 0.21.0

delete time in 7 days

push eventnushell/nushell

Jonathan Turner

commit sha df17d28c0fff4dacd080674dac565a5c3a2cf5d4

Create README.build.txt

view details

push time in 7 days

push eventnushell/nushell

Jonathan Turner

commit sha 5f43c8f024fc3ac679610b1db6e7240f182e1a93

Update lib.rs

view details

push time in 7 days

push eventnushell/nushell

Jonathan Turner

commit sha 1a18734f9ab2035b7b6e7ef2d3988ae763243ee4

Update Cargo.toml

view details

push time in 7 days

push eventnushell/nushell

Jonathan Turner

commit sha 4a70c1ff4f78054f239fe23777f85924bf52c908

Update Cargo.toml Get around the mutual dependency?

view details

push time in 7 days

created tagnushell/nushell

tag0.21.0

A new type of shell

created time in 7 days

delete branch jonathandturner/nushell

delete branch : bump_0_21

delete time in 7 days

push eventnushell/nushell

Jonathan Turner

commit sha 770e5d89f2e414454db1ab73c96628c9ae24049a

Bump to 0.21 (#2663)

view details

push time in 7 days

PR merged nushell/nushell

Bump to 0.21
+201 -201

0 comment

30 changed files

jonathandturner

pr closed time in 7 days

PR opened nushell/nushell

Bump to 0.21
+201 -201

0 comment

30 changed files

pr created time in 7 days

create barnchjonathandturner/nushell

branch : bump_0_21

created branch time in 7 days

push eventnushell/nushell

Wyatt Carss

commit sha cfac8e84dde2bc2a3b72067effe238cfa99ab748

Disable rustyline bracketed paste mode by default (#2659) Multiline pastes wait for the user to hit enter before running, because they enter a special paste mode in rustyline called 'bracketed paste' by default. This commit disables that mode by default for nushell, causing multiline pastes to be executed immediately, treating each new line as a separate command.

view details

push time in 7 days

PR merged nushell/nushell

Disable rustyline bracketed paste mode by default

This should fix https://github.com/nushell/nushell/issues/2596.

Multiline pastes wait for the user to hit enter before running, because they enter a special paste mode in rustyline called 'bracketed paste' by default. This commit disables that mode by default for nushell, causing multiline pastes to be executed immediately, treating each newline as a separate command.

Examples:

Before this PR, pasting this

head -n 1 features.toml
head -n 1 features.toml

results in this:

/workspace/nushell(main)> head -n 1 features.toml
head -n 1 features.toml

|

(| inserted above to represent cursor) and waits for input. After hitting enter, the total exchange looks like this:

/workspace/nushell(main)> head -n 1 features.toml
head -n 1 features.toml


==> features.toml <==
[hintsv1]
head: cannot open 'head' for reading: No such file or directory

==> features.toml <==
[hintsv1]
/workspace/nushell(main)>

Having to hit enter is a little annoying, but from the head: cannot... error message, you can also see the result is incorrect -- each subsequent newline-demarcated command was treated as part of the first command.

After this PR, pasting this:

head -n 1 features.toml
head -n 1 features.toml

results in this:

/workspace/nushell(main)> head -n 1 features.toml
[hintsv1]
/workspace/nushell(main)> head -n 1 features.toml
[hintsv1]
/workspace/nushell(main)>

which matches expectations.

Issues:

  • I'm not sure how to add a test for this
  • pasting multiple echos does not work as expected:
echo "test one"
echo "test two"

results in:

/workspace/nushell(main)> echo "test one"
/workspace/nushell(main)> echo "test two"
/workspace/nushell(main)> 

it seems the output gets overwritten. Investigating that, but it seems like it may be a different issue. It previously would result in the also-wrong:

/workspace/nushell(main)> echo "test one"
echo "test two"


───┬──────────
 0 │ test one 
 1 │ echo     
 2 │ test two 
───┴──────────
/workspace/nushell(main)> 

(after you hit enter post-paste).

+3 -0

2 comments

1 changed file

wcarss

pr closed time in 7 days

issue closednushell/nushell

Hangs when command is followed by a Unix line ending character.

Describe the bug NuShell native and external commands hang when followed by a newline/linefeed character.

To Reproduce Steps to reproduce the behavior:

  1. Open a text editor.
  2. Type ls followed by the Enter key.
  3. Copy paste the entire text including the line return to the command line.
  4. NuShell will try to execute the command immediately but hang and do nothing.
  5. Tested on a variety of commands ls, sys, git clone

Expected behavior NuShell should successfully execute commands that end in a newline character in the same way that other shells like Bash do.

Screenshots

2020-09-23_17-39

Configuration (please complete the following information):

  • OS: Linux -- Manjaro
  • Nu version: v0.20
  • Optional features (if any): default (cargo install nu)

Additional Information

If this is a good beginner bug I'd be happy to take it if someone can point me to the rough area where I should be looking for the problem code. (crates/nu-parser/src/lite_parse.rs?)

closed time in 7 days

samuelvanderwaal

pull request commentnushell/nushell

Disable rustyline bracketed paste mode by default

Thanks for the PR!

wcarss

comment created time in 7 days

pull request commentnushell/nushell

Disable rustyline bracketed paste mode by default

I think we can go ahead and land. I believe the issue you're seeing with the multiple echoes may be an issue with rustyline and the kind of prompts it expects, though I'm not sure. Regardless, I don't think it should block this PR, as it's something we can investigate later.

wcarss

comment created time in 7 days

create barnchjonathandturner/azure-sdk-for-js

branch : msal_wip5

created branch time in 8 days

push eventnushell/nushell

RedlineTriad

commit sha 5770b1527035d4b9f5540e60e249cbc5745dfd42

Use iterator chain instead of string concat. (#2655) * Use iterator chain instead of string concat * Add regression test for multi-value lines

view details

push time in 10 days

PR merged nushell/nushell

Use iterator chain instead of string concat.

This should fix #1470. Previously strings from multiple rows were added together before being split, this changes it so they are separately split and the results added together afterwards. This should make behavior more consistent.

Before this commit:

open foo.json | get first second | lines
───┬───────────
 0 │ firstthis 
 1 │ should    
 2 │ be        
 3 │ separate  
 4 │ lines     
───┴───────────

After this commit:

open foo.json | get first second | lines
───┬──────────
 0 │ first    
 1 │ this     
 2 │ should   
 3 │ be       
 4 │ separate 
 5 │ lines    
───┴──────────

foo.json:

{
  "first": "first",
  "second": "this\nshould\nbe\nseparate\nlines"
}

Disclaimer: I am not very familiar with this code base so I didn't test this very well.

+22 -3

2 comments

3 changed files

RedlineTriad

pr closed time in 10 days

issue closednushell/nushell

`lines` behavior changed recently

Describe the bug

foo.json:

{
  "first": "first",
  "second": "this\nshould\nbe\nseparate\nlines"
}

In master:

$ open foo.json | get first second | lines
───┬───────────
 # │ <value>
───┼───────────
 0 │ firstthis
 1 │ should
 2 │ be
 3 │ separate
 4 │ lines
───┴───────────

previously, was:

───┬──────────
 # │ <value>
───┼──────────
 0 │ first
 1 │ this
 2 │ should
 3 │ be
 4 │ separate
 5 │ lines
───┴──────────

To Reproduce Steps to reproduce the behavior:

  1. Use the example above

Expected behavior The lines command should work across rows.

Note: this will likely be fixed in an upcoming protocol update. Filing this issue as a reminder to add this test case into the test suite as part of the protocol update.

cc @thegedge

closed time in 10 days

jonathandturner

pull request commentnushell/nushell

Use iterator chain instead of string concat.

Looks good!

RedlineTriad

comment created time in 10 days

issue openednushell/nushell

Table wrap of a utf-8 value gives incorrect width

Describe the bug

> echo [[bar]; [$(char rain)] ]
+---+-------------+
| # |     bar     |
+---+-------------+
| 0 | ☔ |
+---+-------------+

To Reproduce Steps to reproduce the behavior:

  1. See above

Expected behavior The above should be able to have the table properly aligned

Screenshots

Screenshot from 2020-10-10 15-51-07

created time in 10 days

pull request commentnushell/nushell

Use iterator chain instead of string concat.

@RedlineTriad - I like this. Can you also add a test case to ensure it keeps working?

RedlineTriad

comment created time in 11 days

push eventnushell/this_week_in_nu

Jonathan Turner

commit sha bfc1537bab3a12c8d5e26ee4f372a0604114f317

Update This week in Nu 59.md

view details

push time in 11 days

push eventnushell/this_week_in_nu

Jonathan Turner

commit sha 26e801ba2e9c68bb9c9d89aee29e7c3864f4e31d

Create This week in Nu 59.md

view details

push time in 11 days

issue closednushell/nushell

Coercion error between bytes and integer

Describe the bug I can't do basic math between file size and integers because there isn't coercion.

To Reproduce

ls **/* | where type == "File" | = $it.size / 1024

Expected behavior size is coerced to integer

https://discordapp.com/channels/601130461678272522/614593951969574961/724675622030409768

closed time in 11 days

johnterickson

issue commentnushell/nushell

Coercion error between bytes and integer

@RedlineTriad good catch.

johnterickson

comment created time in 11 days

issue closednushell/nushell

Documentation for Nu commands (NO programming experience needed)

We need documentation for the following Nu internal commands in any speaking language of your choosing:

If interest in working on a command, please read this first.

Please note: These are Nu commands, they may be the same name as commands you might be familiar from other shells but their usage, flags, and functionality might be different. Please make sure you have latest Nu installation 0.4.0 (you can confirm this by running the version command under Nu).

You can learn more about how a Nu command works by looking at the source code or from Nu itself running help command where command is the command you are interested in documenting.

VERY IMPORTANT you try and experiment with the command using Nu to get ideas. (Updated 18th May, 2020)

  • [ ] autoview
  • [ ] binaryview
  • [ ] clear
  • [ ] cp
  • [ ] describe
  • [ ] drop
  • [ ] each
  • [ ] empty?
  • [ ] keep
  • [ ] keep-until
  • [ ] keep-while
  • [ ] kill
  • [ ] match
  • [ ] merge
  • [ ] mkdir
  • [ ] mv
  • [ ] n
  • [ ] p
  • [ ] parse
  • [ ] post
  • [ ] pwd
  • [ ] range
  • [ ] rm
  • [ ] shuffle
  • [ ] skip-until
  • [ ] split-by
  • [ ] table
  • [ ] textview
  • [ ] touch
  • [ ] tree
  • [ ] with-env

closed time in 11 days

andrasio

issue commentnushell/nushell

Documentation for Nu commands (NO programming experience needed)

Let's go ahead and close this, and we can reopen when we can get a list

andrasio

comment created time in 11 days

push eventnushell/nushell

Chris Gillespie

commit sha 6817b472d0c6d34abd87325514dc9389594e1d64

Handle inf/nan in delimited data (#2652)

view details

push time in 11 days

PR merged nushell/nushell

Handle inf/nan in delimited data
  1. Handle inf/nan in delimited data

I opted to handle this edge case manually. I think it would take a while to get it integrated directly into BigDecimal, but if it is ever does, we can revisit.

Closes #2400

BEFORE:

> echo [[name, stars]; ['nu', inf]] | to csv | from csv
───┬──────┬───────
 # │ name │ stars
───┼──────┼───────
 0 │ nu   │ error

AFTER:

> echo [[name, stars]; ['nu', inf]] | to csv | from csv
───┬──────┬───────
 # │ name │ stars
───┼──────┼───────
 0 │ nu   │ inf
───┴──────┴───────
+41 -7

3 comments

1 changed file

gillespiecd

pr closed time in 11 days

issue closednushell/nushell

Crash on `inf` value in CSV

Describe the bug When the value inf is found in a CSV file, the BigDecimal From<f64> implementation crashes. I haven't finished investigating, but it seems like that crate assumes all f64s can be turned into a BigDecimal. Not sure they accounted for inf values. I was going to open a PR when I found the issue, but now I''m not sure if this is better solved in the BigDecimal crate or in nu_protocol::UntaggedValue::decimal.

To Reproduce Steps to reproduce the behavior:

  1. Create the following CSV file. Name it bad.csv.
1,2
3,inf
  1. Start nushell (nu).
  2. Execute open bad.csv. This step should panic.

Expected behavior I expected it to display the CSV file. It crashes instead.

Screenshots If applicable, add screenshots to help explain your problem.

closed time in 11 days

vlmutolo

pull request commentnushell/nushell

Handle inf/nan in delimited data

Yeah sounds good

gillespiecd

comment created time in 11 days

push eventnushell/blog

Joseph T Lyons

commit sha 6a3664b309fb2ac885a77fe2b934215be0b4fa2d

Trim trailing whitespace in all md files

view details

Jonathan Turner

commit sha 1d95877bdb044201a01dd4d7c2557c2a691ae83d

Merge pull request #29 from JosephTLyons/Trim-trailing-whitespace-in-all-md-files Trim trailing whitespace in all md files

view details

push time in 12 days

push eventnushell/blog

Joseph T Lyons

commit sha 4a6b32e679f2dc2c689c8915bfb5b27ec15e64b7

Fix random integer command

view details

Jonathan Turner

commit sha 319c5537698ac80244e8f8fa5a77cb77926c1032

Merge pull request #28 from JosephTLyons/Fix-random-integer-command Fix random integer command

view details

push time in 12 days

PR merged nushell/blog

Fix random integer command

Changed random int to be random integer, which is the actual command.

+2 -2

1 comment

1 changed file

JosephTLyons

pr closed time in 12 days

pull request commentnushell/blog

Fix random integer command

Thanks!

JosephTLyons

comment created time in 12 days

pull request commentnushell/nushell

Handle inf/nan in delimited data

@gillespiecd - your PR is making me wonder about inf piece. I wonder if we should make special variables for them like we did for $true and $false. Not really part of the PR, but worth considering if we don't already have it.

gillespiecd

comment created time in 12 days

push eventnushell/nushell

Samuel Vanderwaal

commit sha 2b076369e0638a0fc7f1fb3474ac90131bedc0c1

handle duration overflow error (#2616) * handle duration overflow error * handle checked_add_signed result

view details

push time in 12 days

PR merged nushell/nushell

handle duration overflow error

Here's a simple fix for the duration overflow panic #2512 . I think ultimately we will want to refactor compute_value() to return a ShellError or something else but that's a larger refactor I'll open a new issue for.

I'm happy to iterate on this PR if I should be taking a different approach to solving this issue or need to add more tests or whatever. Let me know!

+32 -3

3 comments

2 changed files

samuelvanderwaal

pr closed time in 12 days

pull request commentnushell/nushell

handle duration overflow error

thanks!

samuelvanderwaal

comment created time in 12 days

pull request commentnushell/nushell

handle duration overflow error

@samuelvanderwaal - I've fixed the broken lint issues in the latest main, so I think you'll be fine if you merge main into your branch.

https://github.com/nushell/nushell/pull/2651

samuelvanderwaal

comment created time in 12 days

delete branch jonathandturner/nushell

delete branch : fix_clippy

delete time in 12 days

push eventnushell/nushell

Jonathan Turner

commit sha 1159d3365ad25777961597fdfa19cffe60f1b7db

Fix clippy lints (#2651)

view details

push time in 12 days

PR merged nushell/nushell

Fix clippy lints

Some new lints came with the recent Rust release. Bring us up to date

+32 -70

0 comment

9 changed files

jonathandturner

pr closed time in 12 days

PR opened nushell/nushell

Fix clippy lints

Some new lints came with the recent Rust release. Bring us up to date

+32 -70

0 comment

9 changed files

pr created time in 12 days

create barnchjonathandturner/nushell

branch : fix_clippy

created branch time in 12 days

pull request commentnushell/nushell

handle duration overflow error

That looks better, yeah.

Looks like the latest Rust has some new clippy lints. I'm going to see if I can fix them. Once that lands, I think you'll need to merge main into this branch so that CI can go clean. Take a look now.

samuelvanderwaal

comment created time in 12 days

pull request commentnushell/nushell

LS support for other number formatting

@luccasmmg if you want or you could take what you have and continue to evolve it. When we land it, we'll squash the commits so we'll only see the final set of changes.

luccasmmg

comment created time in 12 days

pull request commentnushell/nushell

LS support for other number formatting

@luccasmmg you could try it as sub-command of format, maybe something like:

ls | format filesize size KiB

and since it's focused on just filesize, then you could have the filesize formats you want to support as part of it. I'd just hardcode them, yeah.

luccasmmg

comment created time in 12 days

pull request commentnushell/nushell

LS support for other number formatting

@luccasmmg - there are a couple things that might help here:

The separate command could take as in put the table, like you're saying. It would be able to update data in that table as it comes into the command so that what goes out has already had the value replaced. This is how the update command works, for example. You could look at that command. You don't even need the block part of update, just the part that updates a value given a path.

If you're talking about converting from the filesize byte value to a string, yes, you'll lose some data. This is also the case for adding a flag. Are you seeing additional places, too? I was thinking this command would be a way to format the table's data for display. We could start it with the filesize functionality you're working on and over time grow from there.

luccasmmg

comment created time in 12 days

pull request commentnushell/nushell

LS support for other number formatting

I was wondering if we might want this to be a more general command, so that other commands (like df for example) could also use it. You could run ls then pass it through your number format command, which updates the output. In the future that combination could then be aliased back to ls and you'd get the end result you want.

luccasmmg

comment created time in 12 days

push eventnushell/nushell

Chris Gillespie

commit sha 152ba32eb764007103e3ddf0a251f78374b42ab9

Debugging tips for contributors (#2647)

view details

push time in 13 days

more