What means ls -d? [duplicate]












0
















This question already has an answer here:




  • Why `ls -d` only demonstrate `.`?

    2 answers




When I use the -d, I only have the . that is displayed on the standard output. However, I also have other files in the current directory.










share|improve this question















marked as duplicate by Jeff Schaller, Jesse_b, ilkkachu, roaima, Stephen Harris Feb 20 at 23:26


This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.























    0
















    This question already has an answer here:




    • Why `ls -d` only demonstrate `.`?

      2 answers




    When I use the -d, I only have the . that is displayed on the standard output. However, I also have other files in the current directory.










    share|improve this question















    marked as duplicate by Jeff Schaller, Jesse_b, ilkkachu, roaima, Stephen Harris Feb 20 at 23:26


    This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.





















      0












      0








      0









      This question already has an answer here:




      • Why `ls -d` only demonstrate `.`?

        2 answers




      When I use the -d, I only have the . that is displayed on the standard output. However, I also have other files in the current directory.










      share|improve this question

















      This question already has an answer here:




      • Why `ls -d` only demonstrate `.`?

        2 answers




      When I use the -d, I only have the . that is displayed on the standard output. However, I also have other files in the current directory.





      This question already has an answer here:




      • Why `ls -d` only demonstrate `.`?

        2 answers








      ls






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Feb 20 at 21:09









      Jesse_b

      13.3k23369




      13.3k23369










      asked Feb 20 at 21:07









      7hsk7hsk

      1




      1




      marked as duplicate by Jeff Schaller, Jesse_b, ilkkachu, roaima, Stephen Harris Feb 20 at 23:26


      This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.









      marked as duplicate by Jeff Schaller, Jesse_b, ilkkachu, roaima, Stephen Harris Feb 20 at 23:26


      This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
























          2 Answers
          2






          active

          oldest

          votes


















          2














          The -d option says:



          -d, --directory
          list directories themselves, not their contents


          This is showing you . because that is your current directory. This could be used in combination with -l if you simply wanted to see the permissions/ownership of the directory, among other things.






          share|improve this answer































            1














            The -d switch lists the directory itself and not the contents. In your case, that means the current directory. If you run ls -ld, it will show the permissions, ownership, last changed time, etc of the current directory.



            If you run ls -d another_directory then it will show the same for whatever directory you specify.






            share|improve this answer






























              2 Answers
              2






              active

              oldest

              votes








              2 Answers
              2






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              2














              The -d option says:



              -d, --directory
              list directories themselves, not their contents


              This is showing you . because that is your current directory. This could be used in combination with -l if you simply wanted to see the permissions/ownership of the directory, among other things.






              share|improve this answer




























                2














                The -d option says:



                -d, --directory
                list directories themselves, not their contents


                This is showing you . because that is your current directory. This could be used in combination with -l if you simply wanted to see the permissions/ownership of the directory, among other things.






                share|improve this answer


























                  2












                  2








                  2







                  The -d option says:



                  -d, --directory
                  list directories themselves, not their contents


                  This is showing you . because that is your current directory. This could be used in combination with -l if you simply wanted to see the permissions/ownership of the directory, among other things.






                  share|improve this answer













                  The -d option says:



                  -d, --directory
                  list directories themselves, not their contents


                  This is showing you . because that is your current directory. This could be used in combination with -l if you simply wanted to see the permissions/ownership of the directory, among other things.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Feb 20 at 21:11









                  Jesse_bJesse_b

                  13.3k23369




                  13.3k23369

























                      1














                      The -d switch lists the directory itself and not the contents. In your case, that means the current directory. If you run ls -ld, it will show the permissions, ownership, last changed time, etc of the current directory.



                      If you run ls -d another_directory then it will show the same for whatever directory you specify.






                      share|improve this answer




























                        1














                        The -d switch lists the directory itself and not the contents. In your case, that means the current directory. If you run ls -ld, it will show the permissions, ownership, last changed time, etc of the current directory.



                        If you run ls -d another_directory then it will show the same for whatever directory you specify.






                        share|improve this answer


























                          1












                          1








                          1







                          The -d switch lists the directory itself and not the contents. In your case, that means the current directory. If you run ls -ld, it will show the permissions, ownership, last changed time, etc of the current directory.



                          If you run ls -d another_directory then it will show the same for whatever directory you specify.






                          share|improve this answer













                          The -d switch lists the directory itself and not the contents. In your case, that means the current directory. If you run ls -ld, it will show the permissions, ownership, last changed time, etc of the current directory.



                          If you run ls -d another_directory then it will show the same for whatever directory you specify.







                          share|improve this answer












                          share|improve this answer



                          share|improve this answer










                          answered Feb 20 at 21:13









                          Nasir RileyNasir Riley

                          2,812249




                          2,812249















                              Popular posts from this blog

                              How to reconfigure Docker Trusted Registry 2.x.x to use CEPH FS mount instead of NFS and other traditional...

                              is 'sed' thread safe

                              How to make a Squid Proxy server?