What is the difference between $path and $PATH (lowercase versus uppercase) with zsh?Share aliases and PATH setting between zsh and bashWhat is the difference between PATH and LD_LIBRARY_PATH?What is the key difference between grml zsh config and oh-my-zsh configZSH: What's the difference between `.` and `source`?What is the difference between `autoload` and `autoload -U` in Zsh?In zsh, what's the difference between &! and &|?What is the difference between “echo $PATH” and /etc/paths?what's the difference between /bin/zsh and /usr/bin/zsh?Can't load antigen in zsh - my source command always gets an extra “/bin” appendedWhat is the difference between “…”, '…', $'…', and $“…” quotes?

Character Frequency in a String

Are gangsters hired to attack people at a train station classified as a terrorist attack?

how to add 1 milliseconds on a datetime string?

Why do websites not use the HaveIBeenPwned API to warn users about exposed passwords?

What is a reasonable time for modern human society to adapt to dungeons?

Grid/table with lots of buttons

How to optimize IN query on indexed column

"I you already know": is this proper English?

What to do when you reach a conclusion and find out later on that someone else already did?

Terence Tao - type books in other fields?

Are glider winch launches rarer in the USA than in the rest of the world? Why?

How to write a sincerely religious protagonist without preaching or affirming or judging their worldview?

What does Kasparov mean here?

Determine if a triangle is equilateral, isosceles, or scalene

Film where a boy turns into a princess

How do I run a game when my PCs have different approaches to combat?

What is a Union Word™?

No-cloning theorem does not seem precise

How can I stop myself from micromanaging other PCs' actions?

Memory capability and powers of 2

The seven story archetypes. Are they truly all of them?

Area of parallelogram = Area of square. Shear transform

Is it normal practice to screen share with a client?

What is the purpose of the fuel shutoff valve?



What is the difference between $path and $PATH (lowercase versus uppercase) with zsh?


Share aliases and PATH setting between zsh and bashWhat is the difference between PATH and LD_LIBRARY_PATH?What is the key difference between grml zsh config and oh-my-zsh configZSH: What's the difference between `.` and `source`?What is the difference between `autoload` and `autoload -U` in Zsh?In zsh, what's the difference between &! and &|?What is the difference between “echo $PATH” and /etc/paths?what's the difference between /bin/zsh and /usr/bin/zsh?Can't load antigen in zsh - my source command always gets an extra “/bin” appendedWhat is the difference between “…”, '…', $'…', and $“…” quotes?






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








4















In FreeBSD 12, using the zsh shell, I noticed this difference when looking at $path (lowercase) versus $PATH (uppercase).



echo $path



/sbin /bin /usr/sbin /usr/bin /usr/local/sbin /usr/local/bin /usr/home/freebsd/bin




echo $PATH



/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/home/freebsd/bin




One output is delimited by SPACE character, the other by COLON character.



➥ Why the difference?



Are these two different, separate variables? Or does the lowercase/uppercase trigger some kind of trick or meaning I do not know about?



Is this a zsh feature? Or a feature of FreeBSD?










share|improve this question






























    4















    In FreeBSD 12, using the zsh shell, I noticed this difference when looking at $path (lowercase) versus $PATH (uppercase).



    echo $path



    /sbin /bin /usr/sbin /usr/bin /usr/local/sbin /usr/local/bin /usr/home/freebsd/bin




    echo $PATH



    /sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/home/freebsd/bin




    One output is delimited by SPACE character, the other by COLON character.



    ➥ Why the difference?



    Are these two different, separate variables? Or does the lowercase/uppercase trigger some kind of trick or meaning I do not know about?



    Is this a zsh feature? Or a feature of FreeBSD?










    share|improve this question


























      4












      4








      4








      In FreeBSD 12, using the zsh shell, I noticed this difference when looking at $path (lowercase) versus $PATH (uppercase).



      echo $path



      /sbin /bin /usr/sbin /usr/bin /usr/local/sbin /usr/local/bin /usr/home/freebsd/bin




      echo $PATH



      /sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/home/freebsd/bin




      One output is delimited by SPACE character, the other by COLON character.



      ➥ Why the difference?



      Are these two different, separate variables? Or does the lowercase/uppercase trigger some kind of trick or meaning I do not know about?



      Is this a zsh feature? Or a feature of FreeBSD?










      share|improve this question
















      In FreeBSD 12, using the zsh shell, I noticed this difference when looking at $path (lowercase) versus $PATH (uppercase).



      echo $path



      /sbin /bin /usr/sbin /usr/bin /usr/local/sbin /usr/local/bin /usr/home/freebsd/bin




      echo $PATH



      /sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/home/freebsd/bin




      One output is delimited by SPACE character, the other by COLON character.



      ➥ Why the difference?



      Are these two different, separate variables? Or does the lowercase/uppercase trigger some kind of trick or meaning I do not know about?



      Is this a zsh feature? Or a feature of FreeBSD?







      zsh variable path array






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited 8 hours ago









      Gilles

      566k136 gold badges1163 silver badges1673 bronze badges




      566k136 gold badges1163 silver badges1673 bronze badges










      asked 8 hours ago









      Basil BourqueBasil Bourque

      4264 silver badges15 bronze badges




      4264 silver badges15 bronze badges




















          1 Answer
          1






          active

          oldest

          votes


















          6














          That's a feature of zsh inherited from csh/tcsh.



          The $path array variable is tied to the $PATH scalar (string) variable. Any modification on one is reflected in the other.



          In zsh (contrary to (t)csh), you can tie other variables beside $PATH with typeset -T. It's conventional, but not mandatory, to use an uppercase name for the colon-separated scalar and the same name in lowercase for the array. While colon is the default separator, other separators can be used (for instance newline to tie a multi-line string to an array, or comma to tie a csv row to an array)



          In recent versions of zsh, typeset -p PATH or typeset -p path shows the link between the two variables:



          % typeset -p path
          typeset -aT PATH path=( /home/chazelas/bin /usr/local/bin /usr/bin /bin )


          That's useful in that it makes it easier to add remove components or loop over them.



          Doing a typeset -U path to make the elements unique also helps keeping the $PATH variable clean (something similar can be achieved in tcsh with set -f).






          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%2f532148%2fwhat-is-the-difference-between-path-and-path-lowercase-versus-uppercase-with%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            6














            That's a feature of zsh inherited from csh/tcsh.



            The $path array variable is tied to the $PATH scalar (string) variable. Any modification on one is reflected in the other.



            In zsh (contrary to (t)csh), you can tie other variables beside $PATH with typeset -T. It's conventional, but not mandatory, to use an uppercase name for the colon-separated scalar and the same name in lowercase for the array. While colon is the default separator, other separators can be used (for instance newline to tie a multi-line string to an array, or comma to tie a csv row to an array)



            In recent versions of zsh, typeset -p PATH or typeset -p path shows the link between the two variables:



            % typeset -p path
            typeset -aT PATH path=( /home/chazelas/bin /usr/local/bin /usr/bin /bin )


            That's useful in that it makes it easier to add remove components or loop over them.



            Doing a typeset -U path to make the elements unique also helps keeping the $PATH variable clean (something similar can be achieved in tcsh with set -f).






            share|improve this answer





























              6














              That's a feature of zsh inherited from csh/tcsh.



              The $path array variable is tied to the $PATH scalar (string) variable. Any modification on one is reflected in the other.



              In zsh (contrary to (t)csh), you can tie other variables beside $PATH with typeset -T. It's conventional, but not mandatory, to use an uppercase name for the colon-separated scalar and the same name in lowercase for the array. While colon is the default separator, other separators can be used (for instance newline to tie a multi-line string to an array, or comma to tie a csv row to an array)



              In recent versions of zsh, typeset -p PATH or typeset -p path shows the link between the two variables:



              % typeset -p path
              typeset -aT PATH path=( /home/chazelas/bin /usr/local/bin /usr/bin /bin )


              That's useful in that it makes it easier to add remove components or loop over them.



              Doing a typeset -U path to make the elements unique also helps keeping the $PATH variable clean (something similar can be achieved in tcsh with set -f).






              share|improve this answer



























                6












                6








                6







                That's a feature of zsh inherited from csh/tcsh.



                The $path array variable is tied to the $PATH scalar (string) variable. Any modification on one is reflected in the other.



                In zsh (contrary to (t)csh), you can tie other variables beside $PATH with typeset -T. It's conventional, but not mandatory, to use an uppercase name for the colon-separated scalar and the same name in lowercase for the array. While colon is the default separator, other separators can be used (for instance newline to tie a multi-line string to an array, or comma to tie a csv row to an array)



                In recent versions of zsh, typeset -p PATH or typeset -p path shows the link between the two variables:



                % typeset -p path
                typeset -aT PATH path=( /home/chazelas/bin /usr/local/bin /usr/bin /bin )


                That's useful in that it makes it easier to add remove components or loop over them.



                Doing a typeset -U path to make the elements unique also helps keeping the $PATH variable clean (something similar can be achieved in tcsh with set -f).






                share|improve this answer















                That's a feature of zsh inherited from csh/tcsh.



                The $path array variable is tied to the $PATH scalar (string) variable. Any modification on one is reflected in the other.



                In zsh (contrary to (t)csh), you can tie other variables beside $PATH with typeset -T. It's conventional, but not mandatory, to use an uppercase name for the colon-separated scalar and the same name in lowercase for the array. While colon is the default separator, other separators can be used (for instance newline to tie a multi-line string to an array, or comma to tie a csv row to an array)



                In recent versions of zsh, typeset -p PATH or typeset -p path shows the link between the two variables:



                % typeset -p path
                typeset -aT PATH path=( /home/chazelas/bin /usr/local/bin /usr/bin /bin )


                That's useful in that it makes it easier to add remove components or loop over them.



                Doing a typeset -U path to make the elements unique also helps keeping the $PATH variable clean (something similar can be achieved in tcsh with set -f).







                share|improve this answer














                share|improve this answer



                share|improve this answer








                edited 7 hours ago

























                answered 8 hours ago









                Stéphane ChazelasStéphane Chazelas

                326k57 gold badges634 silver badges1001 bronze badges




                326k57 gold badges634 silver badges1001 bronze badges



























                    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%2f532148%2fwhat-is-the-difference-between-path-and-path-lowercase-versus-uppercase-with%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

                    ParseJSON using SSJSUsing AMPscript with SSJS ActivitiesHow to resubscribe a user in Marketing cloud using SSJS?Pulling Subscriber Status from Lists using SSJSRetrieving Emails using SSJSProblem in updating DE using SSJSUsing SSJS to send single email in Marketing CloudError adding EmailSendDefinition using SSJS

                    Кампала Садржај Географија Географија Историја Становништво Привреда Партнерски градови Референце Спољашње везе Мени за навигацију0°11′ СГШ; 32°20′ ИГД / 0.18° СГШ; 32.34° ИГД / 0.18; 32.340°11′ СГШ; 32°20′ ИГД / 0.18° СГШ; 32.34° ИГД / 0.18; 32.34МедијиПодациЗванични веб-сајту

                    19. јануар Садржај Догађаји Рођења Смрти Празници и дани сећања Види још Референце Мени за навигацијуу