hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Colin Patrick McCabe (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HADOOP-10971) Flag to make `hadoop fs -ls` print filenames only
Date Mon, 18 Aug 2014 20:13:18 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-10971?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14101200#comment-14101200
] 

Colin Patrick McCabe commented on HADOOP-10971:
-----------------------------------------------

Adding {{\-C}} sounds like a good idea.

> Flag to make `hadoop fs -ls` print filenames only
> -------------------------------------------------
>
>                 Key: HADOOP-10971
>                 URL: https://issues.apache.org/jira/browse/HADOOP-10971
>             Project: Hadoop Common
>          Issue Type: Improvement
>          Components: fs
>    Affects Versions: 2.3.0
>            Reporter: Ryan Williams
>
> It would be useful to have a flag that made {{hadoop fs -ls}} only print filenames, instead
of full {{stat}} info. The "{{-C}}" flag from GNU {{ls}} is the closest analog to this behavior
that I've found, so I propose that as the flag.
> Per [this stackoverflow answer|http://stackoverflow.com/a/21574829], I've reluctantly
added a {{hadoop-ls-C}} wrapper that expands to {{hadoop fs -ls "$@" | sed 1d | perl -wlne'print
+(split " ",$_,8)\[7\]'}} to a few projects I've worked on, and it would obviously be nice
to have hadoop save me (and others) from such hackery.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message