What is this that “ls /d*” returns?












0















I am running Ubuntu Bionic and exploring Bash Refs. This is an amusing but enigmatic output from ls. Is this the file description of the shell?



The command



ls /d*


outputs



autofs           disk         hidraw0    i2c-4     loop1   loop21  loop9               psaux   sda5      stdout  tty19  tty30  tty42  tty54  tty9       ttyS19  ttyS30   vcs    vcsa6
block dri hidraw1 i2c-5 loop10 loop22 loop-control ptmx sda6 tty tty2 tty31 tty43 tty55 ttyprintk ttyS2 ttyS31 vcs1 vfio
bsg drm_dp_aux0 hidraw2 i2c-6 loop11 loop23 mapper ptp0 sg0 tty0 tty20 tty32 tty44 tty56 ttyS0 ttyS20 ttyS4 vcs2 vga_arbiter
btrfs-control drm_dp_aux1 hidraw3 i2c-7 loop12 loop24 mcelog pts sg1 tty1 tty21 tty33 tty45 tty57 ttyS1 ttyS21 ttyS5 vcs3 vhci
bus dvd hidraw4 i2c-8 loop13 loop25 mem random sg2 tty10 tty22 tty34 tty46 tty58 ttyS10 ttyS22 ttyS6 vcs4 vhost-net
cdrom dvdrw hidraw5 i2c-9 loop14 loop26 memory_bandwidth rfkill sg3 tty11 tty23 tty35 tty47 tty59 ttyS11 ttyS23 ttyS7 vcs5 vhost-vsock
cdrw ecryptfs hpet initctl loop15 loop27 mqueue rtc shm tty12 tty24 tty36 tty48 tty6 ttyS12 ttyS24 ttyS8 vcs6 zero
char fb0 hugepages input loop16 loop3 net rtc0 snapshot tty13 tty25 tty37 tty49 tty60 ttyS13 ttyS25 ttyS9 vcsa
console fd hwrng kmsg loop17 loop4 network_latency sda snd tty14 tty26 tty38 tty5 tty61 ttyS14 ttyS26 uhid vcsa1
core full i2c-0 kvm loop18 loop5 network_throughput sda1 sr0 tty15 tty27 tty39 tty50 tty62 ttyS15 ttyS27 uinput vcsa2
cpu fuse i2c-1 lightnvm loop19 loop6 null sda2 sr1 tty16 tty28 tty4 tty51 tty63 ttyS16 ttyS28 urandom vcsa3
cpu_dma_latency fw0 i2c-2 log loop2 loop7 port sda3 stderr tty17 tty29 tty40 tty52 tty7 ttyS17 ttyS29 usb vcsa4
cuse gpiochip0 i2c-3 loop0 loop20 loop8 ppp sda4 stdin tty18 tty3 tty41 tty53 tty8 ttyS18 ttyS3 userio vcsa5









share|improve this question

























  • If you're happy with one or several of the answers, upvote them. If one is solving your issue, accepting it would be the best way of saying "Thank You!" Accepting an answer also indicates to future readers that the answer actually solved the problem.

    – Kusalananda
    Feb 18 at 20:27
















0















I am running Ubuntu Bionic and exploring Bash Refs. This is an amusing but enigmatic output from ls. Is this the file description of the shell?



The command



ls /d*


outputs



autofs           disk         hidraw0    i2c-4     loop1   loop21  loop9               psaux   sda5      stdout  tty19  tty30  tty42  tty54  tty9       ttyS19  ttyS30   vcs    vcsa6
block dri hidraw1 i2c-5 loop10 loop22 loop-control ptmx sda6 tty tty2 tty31 tty43 tty55 ttyprintk ttyS2 ttyS31 vcs1 vfio
bsg drm_dp_aux0 hidraw2 i2c-6 loop11 loop23 mapper ptp0 sg0 tty0 tty20 tty32 tty44 tty56 ttyS0 ttyS20 ttyS4 vcs2 vga_arbiter
btrfs-control drm_dp_aux1 hidraw3 i2c-7 loop12 loop24 mcelog pts sg1 tty1 tty21 tty33 tty45 tty57 ttyS1 ttyS21 ttyS5 vcs3 vhci
bus dvd hidraw4 i2c-8 loop13 loop25 mem random sg2 tty10 tty22 tty34 tty46 tty58 ttyS10 ttyS22 ttyS6 vcs4 vhost-net
cdrom dvdrw hidraw5 i2c-9 loop14 loop26 memory_bandwidth rfkill sg3 tty11 tty23 tty35 tty47 tty59 ttyS11 ttyS23 ttyS7 vcs5 vhost-vsock
cdrw ecryptfs hpet initctl loop15 loop27 mqueue rtc shm tty12 tty24 tty36 tty48 tty6 ttyS12 ttyS24 ttyS8 vcs6 zero
char fb0 hugepages input loop16 loop3 net rtc0 snapshot tty13 tty25 tty37 tty49 tty60 ttyS13 ttyS25 ttyS9 vcsa
console fd hwrng kmsg loop17 loop4 network_latency sda snd tty14 tty26 tty38 tty5 tty61 ttyS14 ttyS26 uhid vcsa1
core full i2c-0 kvm loop18 loop5 network_throughput sda1 sr0 tty15 tty27 tty39 tty50 tty62 ttyS15 ttyS27 uinput vcsa2
cpu fuse i2c-1 lightnvm loop19 loop6 null sda2 sr1 tty16 tty28 tty4 tty51 tty63 ttyS16 ttyS28 urandom vcsa3
cpu_dma_latency fw0 i2c-2 log loop2 loop7 port sda3 stderr tty17 tty29 tty40 tty52 tty7 ttyS17 ttyS29 usb vcsa4
cuse gpiochip0 i2c-3 loop0 loop20 loop8 ppp sda4 stdin tty18 tty3 tty41 tty53 tty8 ttyS18 ttyS3 userio vcsa5









share|improve this question

























  • If you're happy with one or several of the answers, upvote them. If one is solving your issue, accepting it would be the best way of saying "Thank You!" Accepting an answer also indicates to future readers that the answer actually solved the problem.

    – Kusalananda
    Feb 18 at 20:27














0












0








0








I am running Ubuntu Bionic and exploring Bash Refs. This is an amusing but enigmatic output from ls. Is this the file description of the shell?



The command



ls /d*


outputs



autofs           disk         hidraw0    i2c-4     loop1   loop21  loop9               psaux   sda5      stdout  tty19  tty30  tty42  tty54  tty9       ttyS19  ttyS30   vcs    vcsa6
block dri hidraw1 i2c-5 loop10 loop22 loop-control ptmx sda6 tty tty2 tty31 tty43 tty55 ttyprintk ttyS2 ttyS31 vcs1 vfio
bsg drm_dp_aux0 hidraw2 i2c-6 loop11 loop23 mapper ptp0 sg0 tty0 tty20 tty32 tty44 tty56 ttyS0 ttyS20 ttyS4 vcs2 vga_arbiter
btrfs-control drm_dp_aux1 hidraw3 i2c-7 loop12 loop24 mcelog pts sg1 tty1 tty21 tty33 tty45 tty57 ttyS1 ttyS21 ttyS5 vcs3 vhci
bus dvd hidraw4 i2c-8 loop13 loop25 mem random sg2 tty10 tty22 tty34 tty46 tty58 ttyS10 ttyS22 ttyS6 vcs4 vhost-net
cdrom dvdrw hidraw5 i2c-9 loop14 loop26 memory_bandwidth rfkill sg3 tty11 tty23 tty35 tty47 tty59 ttyS11 ttyS23 ttyS7 vcs5 vhost-vsock
cdrw ecryptfs hpet initctl loop15 loop27 mqueue rtc shm tty12 tty24 tty36 tty48 tty6 ttyS12 ttyS24 ttyS8 vcs6 zero
char fb0 hugepages input loop16 loop3 net rtc0 snapshot tty13 tty25 tty37 tty49 tty60 ttyS13 ttyS25 ttyS9 vcsa
console fd hwrng kmsg loop17 loop4 network_latency sda snd tty14 tty26 tty38 tty5 tty61 ttyS14 ttyS26 uhid vcsa1
core full i2c-0 kvm loop18 loop5 network_throughput sda1 sr0 tty15 tty27 tty39 tty50 tty62 ttyS15 ttyS27 uinput vcsa2
cpu fuse i2c-1 lightnvm loop19 loop6 null sda2 sr1 tty16 tty28 tty4 tty51 tty63 ttyS16 ttyS28 urandom vcsa3
cpu_dma_latency fw0 i2c-2 log loop2 loop7 port sda3 stderr tty17 tty29 tty40 tty52 tty7 ttyS17 ttyS29 usb vcsa4
cuse gpiochip0 i2c-3 loop0 loop20 loop8 ppp sda4 stdin tty18 tty3 tty41 tty53 tty8 ttyS18 ttyS3 userio vcsa5









share|improve this question
















I am running Ubuntu Bionic and exploring Bash Refs. This is an amusing but enigmatic output from ls. Is this the file description of the shell?



The command



ls /d*


outputs



autofs           disk         hidraw0    i2c-4     loop1   loop21  loop9               psaux   sda5      stdout  tty19  tty30  tty42  tty54  tty9       ttyS19  ttyS30   vcs    vcsa6
block dri hidraw1 i2c-5 loop10 loop22 loop-control ptmx sda6 tty tty2 tty31 tty43 tty55 ttyprintk ttyS2 ttyS31 vcs1 vfio
bsg drm_dp_aux0 hidraw2 i2c-6 loop11 loop23 mapper ptp0 sg0 tty0 tty20 tty32 tty44 tty56 ttyS0 ttyS20 ttyS4 vcs2 vga_arbiter
btrfs-control drm_dp_aux1 hidraw3 i2c-7 loop12 loop24 mcelog pts sg1 tty1 tty21 tty33 tty45 tty57 ttyS1 ttyS21 ttyS5 vcs3 vhci
bus dvd hidraw4 i2c-8 loop13 loop25 mem random sg2 tty10 tty22 tty34 tty46 tty58 ttyS10 ttyS22 ttyS6 vcs4 vhost-net
cdrom dvdrw hidraw5 i2c-9 loop14 loop26 memory_bandwidth rfkill sg3 tty11 tty23 tty35 tty47 tty59 ttyS11 ttyS23 ttyS7 vcs5 vhost-vsock
cdrw ecryptfs hpet initctl loop15 loop27 mqueue rtc shm tty12 tty24 tty36 tty48 tty6 ttyS12 ttyS24 ttyS8 vcs6 zero
char fb0 hugepages input loop16 loop3 net rtc0 snapshot tty13 tty25 tty37 tty49 tty60 ttyS13 ttyS25 ttyS9 vcsa
console fd hwrng kmsg loop17 loop4 network_latency sda snd tty14 tty26 tty38 tty5 tty61 ttyS14 ttyS26 uhid vcsa1
core full i2c-0 kvm loop18 loop5 network_throughput sda1 sr0 tty15 tty27 tty39 tty50 tty62 ttyS15 ttyS27 uinput vcsa2
cpu fuse i2c-1 lightnvm loop19 loop6 null sda2 sr1 tty16 tty28 tty4 tty51 tty63 ttyS16 ttyS28 urandom vcsa3
cpu_dma_latency fw0 i2c-2 log loop2 loop7 port sda3 stderr tty17 tty29 tty40 tty52 tty7 ttyS17 ttyS29 usb vcsa4
cuse gpiochip0 i2c-3 loop0 loop20 loop8 ppp sda4 stdin tty18 tty3 tty41 tty53 tty8 ttyS18 ttyS3 userio vcsa5






bash ls






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Feb 18 at 20:05









Rui F Ribeiro

41.1k1480138




41.1k1480138










asked Feb 18 at 13:40









Cranberry WaderCranberry Wader

1




1













  • If you're happy with one or several of the answers, upvote them. If one is solving your issue, accepting it would be the best way of saying "Thank You!" Accepting an answer also indicates to future readers that the answer actually solved the problem.

    – Kusalananda
    Feb 18 at 20:27



















  • If you're happy with one or several of the answers, upvote them. If one is solving your issue, accepting it would be the best way of saying "Thank You!" Accepting an answer also indicates to future readers that the answer actually solved the problem.

    – Kusalananda
    Feb 18 at 20:27

















If you're happy with one or several of the answers, upvote them. If one is solving your issue, accepting it would be the best way of saying "Thank You!" Accepting an answer also indicates to future readers that the answer actually solved the problem.

– Kusalananda
Feb 18 at 20:27





If you're happy with one or several of the answers, upvote them. If one is solving your issue, accepting it would be the best way of saying "Thank You!" Accepting an answer also indicates to future readers that the answer actually solved the problem.

– Kusalananda
Feb 18 at 20:27










3 Answers
3






active

oldest

votes


















5














This is the contents of the /dev directory.



ls /d*


is expanded by the shell, to



ls /dev


(and nothing else, on most systems), so ls proceeds to show the contents of /dev.



/d* is interpreted as a glob, and means anything starting with “d” in the root directory. If you have multiple matches, ls will list all matching files, then all matching directories with their contents; you can see the latter typically with ls /l*.






share|improve this answer


























  • sorry, that should have been obvious. I need to learn the regex more

    – Cranberry Wader
    Feb 18 at 13:48






  • 2





    No regex in there. That's a shell wildcard. Mixing the two will result in great confusion.

    – telcoM
    Feb 18 at 13:53






  • 1





    Enter ls /d* and press <Tab> to see what it expands to. If there is more than one possible path, then press <Tab> twice. It's not a real regex, but a pattern for pathname expansion.

    – Freddy
    Feb 18 at 13:54








  • 1





    It is a glob, not a regex.

    – ctrl-alt-delor
    Feb 18 at 14:00



















0














* is just a placeholder, similar to any in logic.



For example, if you were to ls /c* it would show the contents of cats, cows and chickens.






share|improve this answer





















  • 1





    Nope. Most likely it will show "ls: cannot access '/c*': No such file or directory" :)

    – Freddy
    Feb 18 at 14:01











  • Why do you assume that people don't have photos of cows, chickens or other farm animals on their production machines?

    – Radu Chirovici
    Feb 18 at 14:10











  • Because "animal" directories or files are very uncommon in the root directory.

    – Freddy
    Feb 18 at 14:22





















0














Your system, will typically have only one file in / starting with d: /dev/



/d* will expand to this file/directory, so



ls /d*, will expand to ls /dev.
ls then shows the content of the directory /dev.






share|improve this answer

























    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "106"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: false,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f501345%2fwhat-is-this-that-ls-d-returns%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    3 Answers
    3






    active

    oldest

    votes








    3 Answers
    3






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    5














    This is the contents of the /dev directory.



    ls /d*


    is expanded by the shell, to



    ls /dev


    (and nothing else, on most systems), so ls proceeds to show the contents of /dev.



    /d* is interpreted as a glob, and means anything starting with “d” in the root directory. If you have multiple matches, ls will list all matching files, then all matching directories with their contents; you can see the latter typically with ls /l*.






    share|improve this answer


























    • sorry, that should have been obvious. I need to learn the regex more

      – Cranberry Wader
      Feb 18 at 13:48






    • 2





      No regex in there. That's a shell wildcard. Mixing the two will result in great confusion.

      – telcoM
      Feb 18 at 13:53






    • 1





      Enter ls /d* and press <Tab> to see what it expands to. If there is more than one possible path, then press <Tab> twice. It's not a real regex, but a pattern for pathname expansion.

      – Freddy
      Feb 18 at 13:54








    • 1





      It is a glob, not a regex.

      – ctrl-alt-delor
      Feb 18 at 14:00
















    5














    This is the contents of the /dev directory.



    ls /d*


    is expanded by the shell, to



    ls /dev


    (and nothing else, on most systems), so ls proceeds to show the contents of /dev.



    /d* is interpreted as a glob, and means anything starting with “d” in the root directory. If you have multiple matches, ls will list all matching files, then all matching directories with their contents; you can see the latter typically with ls /l*.






    share|improve this answer


























    • sorry, that should have been obvious. I need to learn the regex more

      – Cranberry Wader
      Feb 18 at 13:48






    • 2





      No regex in there. That's a shell wildcard. Mixing the two will result in great confusion.

      – telcoM
      Feb 18 at 13:53






    • 1





      Enter ls /d* and press <Tab> to see what it expands to. If there is more than one possible path, then press <Tab> twice. It's not a real regex, but a pattern for pathname expansion.

      – Freddy
      Feb 18 at 13:54








    • 1





      It is a glob, not a regex.

      – ctrl-alt-delor
      Feb 18 at 14:00














    5












    5








    5







    This is the contents of the /dev directory.



    ls /d*


    is expanded by the shell, to



    ls /dev


    (and nothing else, on most systems), so ls proceeds to show the contents of /dev.



    /d* is interpreted as a glob, and means anything starting with “d” in the root directory. If you have multiple matches, ls will list all matching files, then all matching directories with their contents; you can see the latter typically with ls /l*.






    share|improve this answer















    This is the contents of the /dev directory.



    ls /d*


    is expanded by the shell, to



    ls /dev


    (and nothing else, on most systems), so ls proceeds to show the contents of /dev.



    /d* is interpreted as a glob, and means anything starting with “d” in the root directory. If you have multiple matches, ls will list all matching files, then all matching directories with their contents; you can see the latter typically with ls /l*.







    share|improve this answer














    share|improve this answer



    share|improve this answer








    edited Feb 18 at 15:40

























    answered Feb 18 at 13:41









    Stephen KittStephen Kitt

    174k24399476




    174k24399476













    • sorry, that should have been obvious. I need to learn the regex more

      – Cranberry Wader
      Feb 18 at 13:48






    • 2





      No regex in there. That's a shell wildcard. Mixing the two will result in great confusion.

      – telcoM
      Feb 18 at 13:53






    • 1





      Enter ls /d* and press <Tab> to see what it expands to. If there is more than one possible path, then press <Tab> twice. It's not a real regex, but a pattern for pathname expansion.

      – Freddy
      Feb 18 at 13:54








    • 1





      It is a glob, not a regex.

      – ctrl-alt-delor
      Feb 18 at 14:00



















    • sorry, that should have been obvious. I need to learn the regex more

      – Cranberry Wader
      Feb 18 at 13:48






    • 2





      No regex in there. That's a shell wildcard. Mixing the two will result in great confusion.

      – telcoM
      Feb 18 at 13:53






    • 1





      Enter ls /d* and press <Tab> to see what it expands to. If there is more than one possible path, then press <Tab> twice. It's not a real regex, but a pattern for pathname expansion.

      – Freddy
      Feb 18 at 13:54








    • 1





      It is a glob, not a regex.

      – ctrl-alt-delor
      Feb 18 at 14:00

















    sorry, that should have been obvious. I need to learn the regex more

    – Cranberry Wader
    Feb 18 at 13:48





    sorry, that should have been obvious. I need to learn the regex more

    – Cranberry Wader
    Feb 18 at 13:48




    2




    2





    No regex in there. That's a shell wildcard. Mixing the two will result in great confusion.

    – telcoM
    Feb 18 at 13:53





    No regex in there. That's a shell wildcard. Mixing the two will result in great confusion.

    – telcoM
    Feb 18 at 13:53




    1




    1





    Enter ls /d* and press <Tab> to see what it expands to. If there is more than one possible path, then press <Tab> twice. It's not a real regex, but a pattern for pathname expansion.

    – Freddy
    Feb 18 at 13:54







    Enter ls /d* and press <Tab> to see what it expands to. If there is more than one possible path, then press <Tab> twice. It's not a real regex, but a pattern for pathname expansion.

    – Freddy
    Feb 18 at 13:54






    1




    1





    It is a glob, not a regex.

    – ctrl-alt-delor
    Feb 18 at 14:00





    It is a glob, not a regex.

    – ctrl-alt-delor
    Feb 18 at 14:00













    0














    * is just a placeholder, similar to any in logic.



    For example, if you were to ls /c* it would show the contents of cats, cows and chickens.






    share|improve this answer





















    • 1





      Nope. Most likely it will show "ls: cannot access '/c*': No such file or directory" :)

      – Freddy
      Feb 18 at 14:01











    • Why do you assume that people don't have photos of cows, chickens or other farm animals on their production machines?

      – Radu Chirovici
      Feb 18 at 14:10











    • Because "animal" directories or files are very uncommon in the root directory.

      – Freddy
      Feb 18 at 14:22


















    0














    * is just a placeholder, similar to any in logic.



    For example, if you were to ls /c* it would show the contents of cats, cows and chickens.






    share|improve this answer





















    • 1





      Nope. Most likely it will show "ls: cannot access '/c*': No such file or directory" :)

      – Freddy
      Feb 18 at 14:01











    • Why do you assume that people don't have photos of cows, chickens or other farm animals on their production machines?

      – Radu Chirovici
      Feb 18 at 14:10











    • Because "animal" directories or files are very uncommon in the root directory.

      – Freddy
      Feb 18 at 14:22
















    0












    0








    0







    * is just a placeholder, similar to any in logic.



    For example, if you were to ls /c* it would show the contents of cats, cows and chickens.






    share|improve this answer















    * is just a placeholder, similar to any in logic.



    For example, if you were to ls /c* it would show the contents of cats, cows and chickens.







    share|improve this answer














    share|improve this answer



    share|improve this answer








    edited Feb 18 at 14:00









    Stéphane Chazelas

    309k57582940




    309k57582940










    answered Feb 18 at 13:59









    Radu ChiroviciRadu Chirovici

    215




    215








    • 1





      Nope. Most likely it will show "ls: cannot access '/c*': No such file or directory" :)

      – Freddy
      Feb 18 at 14:01











    • Why do you assume that people don't have photos of cows, chickens or other farm animals on their production machines?

      – Radu Chirovici
      Feb 18 at 14:10











    • Because "animal" directories or files are very uncommon in the root directory.

      – Freddy
      Feb 18 at 14:22
















    • 1





      Nope. Most likely it will show "ls: cannot access '/c*': No such file or directory" :)

      – Freddy
      Feb 18 at 14:01











    • Why do you assume that people don't have photos of cows, chickens or other farm animals on their production machines?

      – Radu Chirovici
      Feb 18 at 14:10











    • Because "animal" directories or files are very uncommon in the root directory.

      – Freddy
      Feb 18 at 14:22










    1




    1





    Nope. Most likely it will show "ls: cannot access '/c*': No such file or directory" :)

    – Freddy
    Feb 18 at 14:01





    Nope. Most likely it will show "ls: cannot access '/c*': No such file or directory" :)

    – Freddy
    Feb 18 at 14:01













    Why do you assume that people don't have photos of cows, chickens or other farm animals on their production machines?

    – Radu Chirovici
    Feb 18 at 14:10





    Why do you assume that people don't have photos of cows, chickens or other farm animals on their production machines?

    – Radu Chirovici
    Feb 18 at 14:10













    Because "animal" directories or files are very uncommon in the root directory.

    – Freddy
    Feb 18 at 14:22







    Because "animal" directories or files are very uncommon in the root directory.

    – Freddy
    Feb 18 at 14:22













    0














    Your system, will typically have only one file in / starting with d: /dev/



    /d* will expand to this file/directory, so



    ls /d*, will expand to ls /dev.
    ls then shows the content of the directory /dev.






    share|improve this answer






























      0














      Your system, will typically have only one file in / starting with d: /dev/



      /d* will expand to this file/directory, so



      ls /d*, will expand to ls /dev.
      ls then shows the content of the directory /dev.






      share|improve this answer




























        0












        0








        0







        Your system, will typically have only one file in / starting with d: /dev/



        /d* will expand to this file/directory, so



        ls /d*, will expand to ls /dev.
        ls then shows the content of the directory /dev.






        share|improve this answer















        Your system, will typically have only one file in / starting with d: /dev/



        /d* will expand to this file/directory, so



        ls /d*, will expand to ls /dev.
        ls then shows the content of the directory /dev.







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited Feb 18 at 15:43









        Stephen Kitt

        174k24399476




        174k24399476










        answered Feb 18 at 14:03









        ctrl-alt-delorctrl-alt-delor

        11.9k42260




        11.9k42260






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to Unix & Linux Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f501345%2fwhat-is-this-that-ls-d-returns%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            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?