joyent/node-triton#217 triton volume ls -l
should output a RESOURCE
column
Reviewed by: Trent Mick <trentm@gmail.com> Approved by: Trent Mick <trentm@gmail.com>
This commit is contained in:
parent
a5ab0f686b
commit
c56d0a25da
@ -7,7 +7,8 @@ Known issues:
|
|||||||
|
|
||||||
## not yet released
|
## not yet released
|
||||||
|
|
||||||
(nothing yet)
|
- [joyent/node-triton#217] `triton volume ls -l` should output a `RESOURCE`
|
||||||
|
column.
|
||||||
|
|
||||||
## 5.3.0
|
## 5.3.0
|
||||||
|
|
||||||
|
@ -31,7 +31,7 @@ var validFilters = [
|
|||||||
var columnsDefault = 'shortid,name,size,type,state,age';
|
var columnsDefault = 'shortid,name,size,type,state,age';
|
||||||
|
|
||||||
// columns default with -l
|
// columns default with -l
|
||||||
var columnsDefaultLong = 'id,name,size,type,state,created';
|
var columnsDefaultLong = 'id,name,size,type,resource,state,created';
|
||||||
|
|
||||||
// sort default with -s
|
// sort default with -s
|
||||||
var sortDefault = 'created';
|
var sortDefault = 'created';
|
||||||
@ -98,6 +98,10 @@ function do_list(subcmd, opts, args, callback) {
|
|||||||
|
|
||||||
created = new Date(volume.create_timestamp);
|
created = new Date(volume.create_timestamp);
|
||||||
|
|
||||||
|
if (volume.filesystem_path !== undefined) {
|
||||||
|
volume.resource = volume.filesystem_path;
|
||||||
|
}
|
||||||
|
|
||||||
volume.shortid = volume.id.split('-', 1)[0];
|
volume.shortid = volume.id.split('-', 1)[0];
|
||||||
volume.created = volume.create_timestamp;
|
volume.created = volume.create_timestamp;
|
||||||
volume.age = common.longAgo(created, now);
|
volume.age = common.longAgo(created, now);
|
||||||
@ -142,6 +146,8 @@ do_list.help = [
|
|||||||
'for convenience):',
|
'for convenience):',
|
||||||
' shortid* A short ID prefix.',
|
' shortid* A short ID prefix.',
|
||||||
' age* Approximate time since created, e.g. 1y, 2w.',
|
' age* Approximate time since created, e.g. 1y, 2w.',
|
||||||
|
' resource* A locator usable by clients to make use of the ',
|
||||||
|
' volume\'s resources',
|
||||||
''
|
''
|
||||||
/* END JSSTYLED */
|
/* END JSSTYLED */
|
||||||
].join('\n');
|
].join('\n');
|
||||||
|
Reference in New Issue
Block a user