Uploaded image for project: 'MongoDB Shell'
  1. MongoDB Shell
  2. MONGOSH-326

Load script files from command line

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

      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@mongodb.com Anna Henningsen
            Reporter:
            massimiliano.marcon@mongodb.com Massimiliano Marcon
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: