Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Building Command Line Interfaces In Node.JS
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
domharrington
May 11, 2012
Programming
400
3
Share
Building Command Line Interfaces In Node.JS
http://lanyrd.com/2012/lnug-april/
domharrington
May 11, 2012
Other Decks in Programming
See All in Programming
Codex CLI でつくる、Issue から merge までの開発フロー
amata1219
0
340
[PHPerKaigi 2026]PHPerKaigi2025の企画CodeGolfが最高すぎて社内で内製して半年運営して得た内製と運営の知見
ikezoemakoto
0
340
ローカルで稼働するAI エージェントを超えて / beyond-local-ai-agents
gawa
2
260
「接続」—パフォーマンスチューニングの最後の一手 〜点と点を結ぶ、その一瞬のために〜
kentaroutakeda
5
2.5k
瑠璃の宝石に学ぶ技術の声の聴き方 / 【劇場版】アニメから得た学びを発表会2026 #エンジニアニメ
mazrean
0
220
TiDBのアーキテクチャから学ぶ分散システム入門 〜MySQL互換のNewSQLは何を解決するのか〜 / tidb-architecture-study
dznbk
1
100
PHP 7.4でもOpenTelemetryゼロコード計装がしたい! / PHPerKaigi 2026
arthur1
1
540
飯MCP
yusukebe
0
490
実践ハーネスエンジニアリング #MOSHTech
kajitack
7
6.1k
Feature Toggle は捨てやすく使おう
gennei
0
510
KagglerがMixSeekを触ってみた
morim
0
370
CursorとClaudeCodeとCodexとOpenCodeを実際に比較してみた
terisuke
1
340
Featured
See All Featured
Agile Leadership in an Agile Organization
kimpetersen
PRO
0
130
The Language of Interfaces
destraynor
162
26k
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
2.6k
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
130
Context Engineering - Making Every Token Count
addyosmani
9
810
The innovator’s Mindset - Leading Through an Era of Exponential Change - McGill University 2025
jdejongh
PRO
1
150
Embracing the Ebb and Flow
colly
88
5k
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
290
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
2.8k
Tell your own story through comics
letsgokoyo
1
890
30 Presentation Tips
portentint
PRO
1
270
How GitHub (no longer) Works
holman
316
150k
Transcript
BUILDING COMMAND LINE INTERFACES IN Node.JS 1 Copyright © 2012
Clock Limited Clock ® is a registered trademark of Clock limited in the EU and other territories Registered in England and Wales No.3457724 VAT Registered No. 706 7654 20
@domharrington 2 WHO AM I? Github: domharrington
'process' module Arguments accessible via 'process.argv' Array of arguments 3
COMMAND- LINE IN NODE
4
Perfectly fine if you only need one argument E.g. accessing
the first argument: process.argv[2] Parsing of options becomes unmanageable 5 PROBLEMS WITH THIS APPROACH
Module to help ease the pain of parsing command-line options
Simple, natural API Auto generated --help and --version 6 COMMANDER.JS https://github.com/visionmedia/commander.js/
7
8
Options don't need to be defined All options are parsed
automatically Also has default values, aliases Many more features 9 NODE-OPTIMIST https://github.com/substack/node-optimist
10
11
aparser cli node-arguments And many more … 12 SOME MORE
LIBRARIES
13 WHERE HAVE I USED IT? https://github.com/domharrington/gitme
14 ANY QUESTIONS?