/oid-cli

Tiny little tool to generate mongo ObjectID in the terminal

Primary LanguageJavaScriptMIT LicenseMIT

oid-cli

install size

A tiny little tool only 33K install size, that allow you generate mongo ObjectId direct in you terminal.

Installation

yarn global add oid-cli

usage

oid
# outputs
5ac177bf70d53847e8785eac

with arguments

oid -n5
# outputs
5ac177f250dbba4954955bb9
5ac177f250dbba4954955bba
5ac177f250dbba4954955bbb
5ac177f250dbba4954955bbc
5ac177f250dbba4954955bbd

Usage with VIM + UltiSnips

with single quotes

snippet /[']oid/ "MongoDB ObjectId" r
'`oid`'
endsnippet

whitout quotes

snippet /[.]oid/ "MongoDB ObjectId" r
`oid`
endsnippet

Demo VIM