main
Last change
on this file since d565449 was d565449, checked in by stefan toskovski <stefantoska84@…>, 4 weeks ago |
Update repo after prototype presentation
|
-
Property mode
set to
100644
|
File size:
289 bytes
|
Rev | Line | |
---|
[d565449] | 1 | #!/usr/bin/env node
|
---|
| 2 |
|
---|
| 3 | 'use strict';
|
---|
| 4 |
|
---|
| 5 | var fs = require('fs');
|
---|
| 6 | var name = process.argv[2] || '.';
|
---|
| 7 | var property = process.argv[3] || 'version';
|
---|
| 8 | if (name != '.') name = 'node_modules/' + name;
|
---|
| 9 | var json = JSON.parse(fs.readFileSync(name + '/package.json', 'utf8'));
|
---|
| 10 | console.log(json[property]);
|
---|
Note:
See
TracBrowser
for help on using the repository browser.