pizza
This file
Path
examples/pizza
29 lines · 786 bytes
Last changed by
Merge pull request #397 from tj/revert-208-feature/descriptions-multiline-supportZhiye Libefore adoption64a5a5d
History of this fileTake it
The walk stopped after 200 commits: lines older than 663b313 point at it.
docsTj Holowaychukbefore adoption663b313
lines 1–10why, one step back1#!/usr/bin/env node23/**4 * Module dependencies.5 */67var program = require('../');89program10 .version('0.0.1')Merge pull request #316 from zhiyelee/updatereadmeZhiye Libefore adoption0b95ea2
line 11why, one step back11 .description('An application for pizzas ordering')docsTj Holowaychukbefore adoption663b313
lines 12–14why, one step back12 .option('-p, --peppers', 'Add peppers')13 .option('-P, --pineapple', 'Add pineapple')14 .option('-b, --bbq', 'Add bbq sauce')Merge pull request #397 from tj/revert-208-feature/descriptions-multiline-supportZhiye Libefore adoption64a5a5d
line 15why, one step back15 .option('-c, --cheese <type>', 'Add the specified type of cheese [marble]')docsTj Holowaychukbefore adoption663b313
lines 16–20why, one step back16 .option('-C, --no-cheese', 'You do not want any cheese')17 .parse(process.argv);1819console.log('you ordered a pizza with:');20if (program.peppers) console.log(' - peppers');Merge pull request #96 from zeMirco/masterTJ Holowaychukbefore adoptione1466b0
line 21why, one step back21if (program.pineapple) console.log(' - pineapple');docsTj Holowaychukbefore adoption663b313
lines 22–24why, one step back22if (program.bbq) console.log(' - bbq');2324var cheese = true === program.cheesemarbleTj Holowaychukbefore adoption05a1816
line 25why, one step back25 ? 'marble'docsTj Holowaychukbefore adoption663b313
lines 26–28why, one step back26 : program.cheese || 'no';2728console.log(' - %s cheese', cheese);Fixed `Commander#args`Tj Holowaychukbefore adoption384ed14
line 29why, one step back29console.log(program.args);