Load script files from command line

XMLWordPrintableJSON

    • Type: Story
    • Resolution: Fixed
    • Priority: Major - P3
    • 0.10.0
    • Affects Version/s: None
    • Component/s: Embedded Shell
    • None
    • Not Needed

      User Story

      As a user,
      I want to run a MongoDB shell script file directly from the command line
      So that I can use mongosh programmatically to execute scripted operations against my servers/clusters.

      Acceptance criteria

      • I can run the script with mongosh ./myscript.js
      • Add support for the --shell CLI argument to provide the user with a shell prompt after a script has been executed.
      • .mongoshrc.js will be interpreted after myscript.js only if --shell is specified

            Assignee:
            Anna Henningsen
            Reporter:
            Massimiliano Marcon
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: