Skip to content

mv: expose main functionality for nushell #5293

Closed

Description

@tertsdiepraam

Part of: nushell/nushell#10446

nushell wants access to our mv internals. Which means exposing the exec function and Behavior struct. Feel free to rename those to something more sensible for a public API (e.g. move & Options, to match the naming scheme from cp). There should be documentation for all the public items in the API as well.

This is an excellent first issue: feel free to claim this!

We did the same thing for cp already. You could use that PR as a guide: #5152

Activity

  1. kaathewisegit commented on Sep 25, 2023

    @kaathewisegit
    Contributor

    While rm refactoring is being discussed, I wanted to take on this issue.

    I noticed mv uses a Behavior struct for options, whereas other commands use Options. Would it be fine to change its name to Options in the PR?

  2. tertsdiepraam commented on Sep 25, 2023

    @tertsdiepraam
    CollaboratorAuthor

    I think @PThorpe92 was working on this, but didn't mention that here yet. In the meantime, you could try to look at other utils. For example, the ones mentioned here: #5088 (comment). In general though, I think it's nice to make all utils as uniform as possible and I do encourage renaming as part of these PRs. Though more involved refactors should be done separately.

  3. PThorpe92 commented on Sep 25, 2023

    @PThorpe92
    Contributor

    Yeah I'll have a PR in today on this.

  4. kaathewisegit commented on Sep 25, 2023

    @kaathewisegit
    Contributor

    Got it!

  5. moved this from In Progress to Done in nushell integrationon Oct 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions