Skip to content

Commit cc85bf3

Browse files
(DOCSP-11133): Add callout to mongosh
1 parent 33b9ffc commit cc85bf3

File tree

8 files changed

+57
-2
lines changed

8 files changed

+57
-2
lines changed

conf.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,8 @@ def has(self, *args):
7171
'.. |branch| replace:: ``{0}``'.format(conf.git.branches.current),
7272
'.. |bi| replace:: MongoDB Connector for BI',
7373
'.. |version| replace:: {0}'.format(version),
74-
'.. |compass| replace:: MongoDB Compass'
74+
'.. |compass| replace:: MongoDB Compass',
75+
'.. |mdb-shell| replace:: MongoDB Shell'
7576
])
7677

7778
source_constants = {
@@ -101,6 +102,7 @@ def has(self, *args):
101102
'mms-home': ('https://www.mongodb.com/cloud/cloud-manager%s', ''),
102103
'opsmgr': ('https://docs.opsmanager.mongodb.com/current%s', ''),
103104
'atlas': ('https://docs.atlas.mongodb.com%s',''),
105+
'mongosh': ('https://docs.mongodb.com/mongodb-shell%s', ''),
104106
'products': ('https://www.mongodb.com/products%s', ''),
105107
'wtdocs': ('https://source.wiredtiger.com/mongodb-3.4%s', ''),
106108
'perl-api': ('https://metacpan.org/pod/MongoDB::%s', ''),

source/core/shell-types.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ Data Types in the ``mongo`` Shell
1010
:depth: 2
1111
:class: singlecol
1212

13+
.. include:: /includes/fact-mongosh-callout.rst
14+
1315
MongoDB :term:`BSON` provides support for additional data types than
1416
:term:`JSON`. :ecosystem:`Drivers </drivers>` provide native
1517
support for these data types in host languages and the
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
.. note::
2+
3+
The following document pertains to the :binary:`~bin.mongo` shell
4+
included in the
5+
`MongoDB Server Download
6+
<https://www.mongodb.com/try/download/community?tck=docs_server>`__.
7+
For information on the new MongoDB Shell, ``mongosh``, refer to the
8+
:mongosh:`mongosh Documentation </>`.
9+
10+
To understand the differences between the two shells, see
11+
:ref:`compare-mongosh-mongo`.

source/mongo.txt

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ The :binary:`~bin.mongo` shell is an interactive JavaScript interface to
1414
MongoDB. You can use the :binary:`~bin.mongo` shell to query and update
1515
data as well as perform administrative operations.
1616

17+
.. include:: /includes/fact-mongosh-callout.rst
18+
1719
Download the ``mongo`` Shell
1820
----------------------------
1921

@@ -395,10 +397,41 @@ Exit the Shell
395397

396398
To exit the shell, type ``quit()`` or use the ``<Ctrl-C>`` shortcut.
397399

400+
.. _compare-mongosh-mongo:
401+
402+
Comparison of the ``mongo`` Shell and ``mongosh``
403+
-------------------------------------------------
404+
405+
.. note::
406+
407+
:mongosh:`mongosh </>` is currently available as a
408+
**Beta** release. The product, its features, and the corresponding
409+
documentation may change during the Beta stage.
410+
411+
The new MongoDB Shell, :mongosh:`mongosh </>`, offers numerous
412+
advantages over the :binary:`~bin.mongo` shell, such as:
413+
414+
- Improved syntax highlighting.
415+
416+
- Improved command history.
417+
418+
- Improved logging.
419+
420+
During the beta stage, ``mongosh`` supports a subset of the
421+
:binary:`~bin.mongo` shell methods. Achieving feature parity between
422+
``mongosh`` and the ``mongo`` shell is an ongoing effort.
423+
424+
To maintain backwards compatibility, the methods that ``mongosh``
425+
supports use the same syntax as the corresponding methods in the
426+
:binary:`~bin.mongo` shell. To see the complete list of methods
427+
supported by ``mongosh``, see
428+
:mongosh:`MongoDB Shell Methods </reference/methods>`
429+
398430
.. seealso::
399431

400432
- :gettingstarted:`Getting Started Guide </shell>`
401433
- :binary:`~bin.mongo` Reference Page
434+
- :mongosh:`mongosh Documentation </>`
402435

403436
.. class:: hidden
404437

source/reference/mongo-shell.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010
:depth: 1
1111
:class: singlecol
1212

13+
.. include:: /includes/fact-mongosh-callout.rst
14+
1315
``mongo`` Shell Command History
1416
-------------------------------
1517

source/tutorial/access-mongo-shell-help.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ Access the ``mongo`` Shell Help
1212
:depth: 1
1313
:class: twocols
1414

15+
.. include:: /includes/fact-mongosh-callout.rst
16+
1517
In addition to the documentation in the :doc:`MongoDB Manual
1618
</index>`, the :binary:`~bin.mongo` shell provides some additional
1719
information in its "online" help system. This document provides an
@@ -174,4 +176,3 @@ shell, such as ``BinData()``, type ``help misc`` in the
174176
help misc
175177

176178
.. seealso:: :doc:`/reference/method`
177-

source/tutorial/configure-mongo-shell.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ Configure the ``mongo`` Shell
1010
:depth: 1
1111
:class: singlecol
1212

13+
.. include:: /includes/fact-mongosh-callout.rst
14+
1315
.. _shell-use-a-custom-prompt:
1416

1517
Customize the Prompt

source/tutorial/write-scripts-for-the-mongo-shell.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ Write Scripts for the ``mongo`` Shell
1010
:depth: 1
1111
:class: singlecol
1212

13+
.. include:: /includes/fact-mongosh-callout.rst
14+
1315
You can write scripts for the :binary:`~bin.mongo` shell in JavaScript that
1416
manipulate data in MongoDB or perform administrative operation.
1517

0 commit comments

Comments
 (0)