Giter Site home page Giter Site logo

Comments (4)

fdncred avatar fdncred commented on June 1, 2024

I suspect this is because of 2 reasons

  1. --redirect-stdout and --redirect-stderr have been deprecated
  2. all the rest arguments to custom commands need to use the spread operator, not in just one custom command.

from nu_scripts.

AucaCoyan avatar AucaCoyan commented on June 1, 2024

I suspect this was fixed in #799 , is that correct @TeaDrinkingProgrammer ?

from nu_scripts.

TeaDrinkingProgrammer avatar TeaDrinkingProgrammer commented on June 1, 2024

Some errors have been resolved, but --redirect-stdout is still used, so I get depricated warnings for that and the script also doesn't seem to work anymore:

Error: × Deprecated flag
╭─[C:\Users\Stijn\AppData\Roaming\nushell\scripts\git_branch_cleanup.nu:59:16]
58 │ def current_branch [] {
59 │ run-external --redirect-stdout "git" "branch" "--show-current"
· ────────────────────────┬────────────────────────
· ╰── --redirect-stdout is deprecated
60 │ | into string
╰────
help: run-external will now always redirect stdout if there is a pipe | afterwards

Error: × Deprecated flag
╭─[C:\Users\Stijn\AppData\Roaming\nushell\scripts\git_branch_cleanup.nu:88:16]
87 │
88 │ run-external --redirect-stdout "git" "symbolic-ref" $args
· ──────────────────────┬─────────────────────
· ╰── --redirect-stdout is deprecated
89 │ | str trim
╰────
help: run-external will now always redirect stdout if there is a pipe | afterwards

Error: nu::shell::cannot_pass_list_to_external

× Lists are not automatically spread when calling external commands
╭─[C:\Users\Stijn\AppData\Roaming\nushell\scripts\git_branch_cleanup.nu:88:55]
87 │
88 │ run-external --redirect-stdout "git" "symbolic-ref" $args
· ──┬──
· ╰── Spread operator (...) is necessary to spread lists
89 │ | str trim
╰────
help: Either convert the list to a string or use the spread operator, like so: ...$args

from nu_scripts.

AucaCoyan avatar AucaCoyan commented on June 1, 2024

The deprecation warning is because the CI is using latest nushell version 0.92, released Apr-02,
here is a link to the deprecated commands chapter in the blogpost

from nu_scripts.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.