Environment variable also getting printedls, regexp and environment variableHow to correct a weird bash...

Why is so much ransomware breakable?

Precedent for disabled Kings

How to choose the correct exposure for flower photography?

Very serious stuff - Salesforce bug enabled "Modify All"

Bash Array of Word-Splitting Headaches

Why didn't Daenerys' advisers suggest assassinating Cersei?

Better than Rembrandt

How was the blinking terminal cursor invented?

Why does the U.S military use mercenaries?

Can't think of a good word or term to describe not feeling or thinking

What does it mean for a program to be 32 or 64 bit?

Hotel booking: Why is Agoda much cheaper than booking.com?

In Dutch history two people are referred to as "William III"; are there any more cases where this happens?

How to safely discharge oneself

What were the "pills" that were added to solid waste in Apollo 7?

Richard's Favourite TV Programme

Greek theta instead of lower case þ (Icelandic) in TexStudio

Latin words remembered from high school 50 years ago

Reference for electronegativities of different metal oxidation states

How does the "reverse syntax" in Middle English work?

What is the backup for a glass cockpit, if a plane loses power to the displays/controls?

Why does snapping your fingers activate the Infinity Gauntlet?

What does this 'x' mean on the stem of the voice's note, above the notehead?

How can I prevent Bash expansion from passing files starting with "-" as argument?



Environment variable also getting printed


ls, regexp and environment variableHow to correct a weird bash prompt on a Debian (Squeeze) server?Percent in $PATH environment variableMeaning of before environment variableChange Environment Path Variable OrderBash - shell vs environment variableget environment variable by variable name?Who sets $PATH environment variable?Why would `sudo cp src dst` ignore no clobber rule in /etc?






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







1















While typing any commands one of my environment variables also gets printed.



[root@appdynamics home]# ls
ls
192.168.71.2 192.168.71.50 karti lost+found postgres
printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


How can I solve it for all the commands it is getting printed?



Shell type:Bash



This is what the output of prompt command and prompt vars



[root@appdynamics home]#
echo $PROMPT_COMMAND
echo $PROMPT_COMMAND
printf "33]0 %s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"
printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"



[root@appdynamics home]# echo $promptvars

echo $promptvars

printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


/etc/bashrc:



# are we an interactive shell?
if [ "$PS1" ]; then
if [ -z "$PROMPT_COMMAND" ]; then
case $TERM in
xterm*)
if [ -e /etc/sysconfig/bash-prompt-xterm ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-xterm
else
PROMPT_COMMAND='printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
fi
;;
screen)
if [ -e /etc/sysconfig/bash-prompt-screen ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-screen
else
PROMPT_COMMAND='printf "33]0;%s@%s:%s33\" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
fi
;;
*)
[ -e /etc/sysconfig/bash-prompt-default ] && PROMPT_COMMAND=/etc/sysconfig/bash-prompt-default
;;
esac
fi
# Turn on checkwinsize










share|improve this question

























  • This is what i am getting printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}" along with output for any commands

    – karthik
    Aug 10 '16 at 13:21






  • 1





    It's still very unclear what the issue is here. Do you have files with interesting names? Is the printf displayed after every command? Check your shell init scripts for errors when setting PS1 and/or PROMPT_COMMAND.

    – Kusalananda
    Aug 10 '16 at 13:39






  • 2





    to Kusalananda's point, what is the value of $PROMPT_COMMAND ? At a guess, you're trying to set a custom PS1 prompt but got some quotes/backticks wrong

    – Jeff Schaller
    Aug 10 '16 at 14:09











  • Kusalanada, not with ls eventhough i am giving the command as cd or any other commands i am getting the possible results along with that i am getting this line printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"

    – karthik
    Aug 10 '16 at 17:37


















1















While typing any commands one of my environment variables also gets printed.



[root@appdynamics home]# ls
ls
192.168.71.2 192.168.71.50 karti lost+found postgres
printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


How can I solve it for all the commands it is getting printed?



Shell type:Bash



This is what the output of prompt command and prompt vars



[root@appdynamics home]#
echo $PROMPT_COMMAND
echo $PROMPT_COMMAND
printf "33]0 %s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"
printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"



[root@appdynamics home]# echo $promptvars

echo $promptvars

printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


/etc/bashrc:



# are we an interactive shell?
if [ "$PS1" ]; then
if [ -z "$PROMPT_COMMAND" ]; then
case $TERM in
xterm*)
if [ -e /etc/sysconfig/bash-prompt-xterm ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-xterm
else
PROMPT_COMMAND='printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
fi
;;
screen)
if [ -e /etc/sysconfig/bash-prompt-screen ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-screen
else
PROMPT_COMMAND='printf "33]0;%s@%s:%s33\" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
fi
;;
*)
[ -e /etc/sysconfig/bash-prompt-default ] && PROMPT_COMMAND=/etc/sysconfig/bash-prompt-default
;;
esac
fi
# Turn on checkwinsize










share|improve this question

























  • This is what i am getting printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}" along with output for any commands

    – karthik
    Aug 10 '16 at 13:21






  • 1





    It's still very unclear what the issue is here. Do you have files with interesting names? Is the printf displayed after every command? Check your shell init scripts for errors when setting PS1 and/or PROMPT_COMMAND.

    – Kusalananda
    Aug 10 '16 at 13:39






  • 2





    to Kusalananda's point, what is the value of $PROMPT_COMMAND ? At a guess, you're trying to set a custom PS1 prompt but got some quotes/backticks wrong

    – Jeff Schaller
    Aug 10 '16 at 14:09











  • Kusalanada, not with ls eventhough i am giving the command as cd or any other commands i am getting the possible results along with that i am getting this line printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"

    – karthik
    Aug 10 '16 at 17:37














1












1








1


0






While typing any commands one of my environment variables also gets printed.



[root@appdynamics home]# ls
ls
192.168.71.2 192.168.71.50 karti lost+found postgres
printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


How can I solve it for all the commands it is getting printed?



Shell type:Bash



This is what the output of prompt command and prompt vars



[root@appdynamics home]#
echo $PROMPT_COMMAND
echo $PROMPT_COMMAND
printf "33]0 %s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"
printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"



[root@appdynamics home]# echo $promptvars

echo $promptvars

printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


/etc/bashrc:



# are we an interactive shell?
if [ "$PS1" ]; then
if [ -z "$PROMPT_COMMAND" ]; then
case $TERM in
xterm*)
if [ -e /etc/sysconfig/bash-prompt-xterm ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-xterm
else
PROMPT_COMMAND='printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
fi
;;
screen)
if [ -e /etc/sysconfig/bash-prompt-screen ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-screen
else
PROMPT_COMMAND='printf "33]0;%s@%s:%s33\" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
fi
;;
*)
[ -e /etc/sysconfig/bash-prompt-default ] && PROMPT_COMMAND=/etc/sysconfig/bash-prompt-default
;;
esac
fi
# Turn on checkwinsize










share|improve this question
















While typing any commands one of my environment variables also gets printed.



[root@appdynamics home]# ls
ls
192.168.71.2 192.168.71.50 karti lost+found postgres
printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


How can I solve it for all the commands it is getting printed?



Shell type:Bash



This is what the output of prompt command and prompt vars



[root@appdynamics home]#
echo $PROMPT_COMMAND
echo $PROMPT_COMMAND
printf "33]0 %s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"
printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"



[root@appdynamics home]# echo $promptvars

echo $promptvars

printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


/etc/bashrc:



# are we an interactive shell?
if [ "$PS1" ]; then
if [ -z "$PROMPT_COMMAND" ]; then
case $TERM in
xterm*)
if [ -e /etc/sysconfig/bash-prompt-xterm ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-xterm
else
PROMPT_COMMAND='printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
fi
;;
screen)
if [ -e /etc/sysconfig/bash-prompt-screen ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-screen
else
PROMPT_COMMAND='printf "33]0;%s@%s:%s33\" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"'
fi
;;
*)
[ -e /etc/sysconfig/bash-prompt-default ] && PROMPT_COMMAND=/etc/sysconfig/bash-prompt-default
;;
esac
fi
# Turn on checkwinsize







shell command-line






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Aug 11 '16 at 4:43







karthik

















asked Aug 10 '16 at 12:46









karthikkarthik

65113




65113













  • This is what i am getting printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}" along with output for any commands

    – karthik
    Aug 10 '16 at 13:21






  • 1





    It's still very unclear what the issue is here. Do you have files with interesting names? Is the printf displayed after every command? Check your shell init scripts for errors when setting PS1 and/or PROMPT_COMMAND.

    – Kusalananda
    Aug 10 '16 at 13:39






  • 2





    to Kusalananda's point, what is the value of $PROMPT_COMMAND ? At a guess, you're trying to set a custom PS1 prompt but got some quotes/backticks wrong

    – Jeff Schaller
    Aug 10 '16 at 14:09











  • Kusalanada, not with ls eventhough i am giving the command as cd or any other commands i am getting the possible results along with that i am getting this line printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"

    – karthik
    Aug 10 '16 at 17:37



















  • This is what i am getting printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}" along with output for any commands

    – karthik
    Aug 10 '16 at 13:21






  • 1





    It's still very unclear what the issue is here. Do you have files with interesting names? Is the printf displayed after every command? Check your shell init scripts for errors when setting PS1 and/or PROMPT_COMMAND.

    – Kusalananda
    Aug 10 '16 at 13:39






  • 2





    to Kusalananda's point, what is the value of $PROMPT_COMMAND ? At a guess, you're trying to set a custom PS1 prompt but got some quotes/backticks wrong

    – Jeff Schaller
    Aug 10 '16 at 14:09











  • Kusalanada, not with ls eventhough i am giving the command as cd or any other commands i am getting the possible results along with that i am getting this line printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"

    – karthik
    Aug 10 '16 at 17:37

















This is what i am getting printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}" along with output for any commands

– karthik
Aug 10 '16 at 13:21





This is what i am getting printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}" along with output for any commands

– karthik
Aug 10 '16 at 13:21




1




1





It's still very unclear what the issue is here. Do you have files with interesting names? Is the printf displayed after every command? Check your shell init scripts for errors when setting PS1 and/or PROMPT_COMMAND.

– Kusalananda
Aug 10 '16 at 13:39





It's still very unclear what the issue is here. Do you have files with interesting names? Is the printf displayed after every command? Check your shell init scripts for errors when setting PS1 and/or PROMPT_COMMAND.

– Kusalananda
Aug 10 '16 at 13:39




2




2





to Kusalananda's point, what is the value of $PROMPT_COMMAND ? At a guess, you're trying to set a custom PS1 prompt but got some quotes/backticks wrong

– Jeff Schaller
Aug 10 '16 at 14:09





to Kusalananda's point, what is the value of $PROMPT_COMMAND ? At a guess, you're trying to set a custom PS1 prompt but got some quotes/backticks wrong

– Jeff Schaller
Aug 10 '16 at 14:09













Kusalanada, not with ls eventhough i am giving the command as cd or any other commands i am getting the possible results along with that i am getting this line printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"

– karthik
Aug 10 '16 at 17:37





Kusalanada, not with ls eventhough i am giving the command as cd or any other commands i am getting the possible results along with that i am getting this line printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"

– karthik
Aug 10 '16 at 17:37










3 Answers
3






active

oldest

votes


















1














printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


This comes when you use the command bash -v. To get rid of it give the exit command.






share|improve this answer

































    0














    Evidently something is wrong in your prompt settings. Check your shell configuration file; that's .bashrc for bash, .kshrc for ksh, .zshrc for zsh (always in your home directory). It's also possible that the configuration is in some system-wide file like /etc/bash.bashrc or /etc/zshrc. It's also possible that the configuration is misplaced, e.g. in ~/.profile or ~/.bash_profile or /etc/profile.



    What you're seeing as the prompt looks like a command that's meant to be executed by the shell to construct the prompt. Maybe this is bash and someone wrote PS1='printf …' meaning PROMPT_COMMAND='printf …'. But that's only one possibility among many. Check the configuration files to see how the PS1 variable is defined, and other shell-dependent settings, such as the PROMPT_COMMAND variable and the promptvars option in bash.



    If you can't figure it out, post your shell configuration files. And be sure to say which shell you're using! If you don't tell us exactly what's in your configuration, we can only speculate.






    share|improve this answer
























    • Gilles,I have updated the mentioned variables output.Do you want me to post my configuration files too(bashrc,/etc/profile,~/.bash_profile)

      – karthik
      Aug 11 '16 at 4:37











    • @karthikraj Yes. The problem is not in the part you posted. Post the whole files.

      – Gilles
      Aug 11 '16 at 7:51





















    0














    Quite simply, you simply exit the current shell using multiple exits





    share








    New contributor



    xdwd is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.




















      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%2f302551%2fenvironment-variable-also-getting-printed%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









      1














      printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


      This comes when you use the command bash -v. To get rid of it give the exit command.






      share|improve this answer






























        1














        printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


        This comes when you use the command bash -v. To get rid of it give the exit command.






        share|improve this answer




























          1












          1








          1







          printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


          This comes when you use the command bash -v. To get rid of it give the exit command.






          share|improve this answer















          printf "33]0;%s@%s:%s07" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}"


          This comes when you use the command bash -v. To get rid of it give the exit command.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Feb 20 '18 at 0:08









          llogan

          53428




          53428










          answered Sep 25 '17 at 17:38









          user252822user252822

          211




          211

























              0














              Evidently something is wrong in your prompt settings. Check your shell configuration file; that's .bashrc for bash, .kshrc for ksh, .zshrc for zsh (always in your home directory). It's also possible that the configuration is in some system-wide file like /etc/bash.bashrc or /etc/zshrc. It's also possible that the configuration is misplaced, e.g. in ~/.profile or ~/.bash_profile or /etc/profile.



              What you're seeing as the prompt looks like a command that's meant to be executed by the shell to construct the prompt. Maybe this is bash and someone wrote PS1='printf …' meaning PROMPT_COMMAND='printf …'. But that's only one possibility among many. Check the configuration files to see how the PS1 variable is defined, and other shell-dependent settings, such as the PROMPT_COMMAND variable and the promptvars option in bash.



              If you can't figure it out, post your shell configuration files. And be sure to say which shell you're using! If you don't tell us exactly what's in your configuration, we can only speculate.






              share|improve this answer
























              • Gilles,I have updated the mentioned variables output.Do you want me to post my configuration files too(bashrc,/etc/profile,~/.bash_profile)

                – karthik
                Aug 11 '16 at 4:37











              • @karthikraj Yes. The problem is not in the part you posted. Post the whole files.

                – Gilles
                Aug 11 '16 at 7:51


















              0














              Evidently something is wrong in your prompt settings. Check your shell configuration file; that's .bashrc for bash, .kshrc for ksh, .zshrc for zsh (always in your home directory). It's also possible that the configuration is in some system-wide file like /etc/bash.bashrc or /etc/zshrc. It's also possible that the configuration is misplaced, e.g. in ~/.profile or ~/.bash_profile or /etc/profile.



              What you're seeing as the prompt looks like a command that's meant to be executed by the shell to construct the prompt. Maybe this is bash and someone wrote PS1='printf …' meaning PROMPT_COMMAND='printf …'. But that's only one possibility among many. Check the configuration files to see how the PS1 variable is defined, and other shell-dependent settings, such as the PROMPT_COMMAND variable and the promptvars option in bash.



              If you can't figure it out, post your shell configuration files. And be sure to say which shell you're using! If you don't tell us exactly what's in your configuration, we can only speculate.






              share|improve this answer
























              • Gilles,I have updated the mentioned variables output.Do you want me to post my configuration files too(bashrc,/etc/profile,~/.bash_profile)

                – karthik
                Aug 11 '16 at 4:37











              • @karthikraj Yes. The problem is not in the part you posted. Post the whole files.

                – Gilles
                Aug 11 '16 at 7:51
















              0












              0








              0







              Evidently something is wrong in your prompt settings. Check your shell configuration file; that's .bashrc for bash, .kshrc for ksh, .zshrc for zsh (always in your home directory). It's also possible that the configuration is in some system-wide file like /etc/bash.bashrc or /etc/zshrc. It's also possible that the configuration is misplaced, e.g. in ~/.profile or ~/.bash_profile or /etc/profile.



              What you're seeing as the prompt looks like a command that's meant to be executed by the shell to construct the prompt. Maybe this is bash and someone wrote PS1='printf …' meaning PROMPT_COMMAND='printf …'. But that's only one possibility among many. Check the configuration files to see how the PS1 variable is defined, and other shell-dependent settings, such as the PROMPT_COMMAND variable and the promptvars option in bash.



              If you can't figure it out, post your shell configuration files. And be sure to say which shell you're using! If you don't tell us exactly what's in your configuration, we can only speculate.






              share|improve this answer













              Evidently something is wrong in your prompt settings. Check your shell configuration file; that's .bashrc for bash, .kshrc for ksh, .zshrc for zsh (always in your home directory). It's also possible that the configuration is in some system-wide file like /etc/bash.bashrc or /etc/zshrc. It's also possible that the configuration is misplaced, e.g. in ~/.profile or ~/.bash_profile or /etc/profile.



              What you're seeing as the prompt looks like a command that's meant to be executed by the shell to construct the prompt. Maybe this is bash and someone wrote PS1='printf …' meaning PROMPT_COMMAND='printf …'. But that's only one possibility among many. Check the configuration files to see how the PS1 variable is defined, and other shell-dependent settings, such as the PROMPT_COMMAND variable and the promptvars option in bash.



              If you can't figure it out, post your shell configuration files. And be sure to say which shell you're using! If you don't tell us exactly what's in your configuration, we can only speculate.







              share|improve this answer












              share|improve this answer



              share|improve this answer










              answered Aug 11 '16 at 0:55









              GillesGilles

              553k13311341643




              553k13311341643













              • Gilles,I have updated the mentioned variables output.Do you want me to post my configuration files too(bashrc,/etc/profile,~/.bash_profile)

                – karthik
                Aug 11 '16 at 4:37











              • @karthikraj Yes. The problem is not in the part you posted. Post the whole files.

                – Gilles
                Aug 11 '16 at 7:51





















              • Gilles,I have updated the mentioned variables output.Do you want me to post my configuration files too(bashrc,/etc/profile,~/.bash_profile)

                – karthik
                Aug 11 '16 at 4:37











              • @karthikraj Yes. The problem is not in the part you posted. Post the whole files.

                – Gilles
                Aug 11 '16 at 7:51



















              Gilles,I have updated the mentioned variables output.Do you want me to post my configuration files too(bashrc,/etc/profile,~/.bash_profile)

              – karthik
              Aug 11 '16 at 4:37





              Gilles,I have updated the mentioned variables output.Do you want me to post my configuration files too(bashrc,/etc/profile,~/.bash_profile)

              – karthik
              Aug 11 '16 at 4:37













              @karthikraj Yes. The problem is not in the part you posted. Post the whole files.

              – Gilles
              Aug 11 '16 at 7:51







              @karthikraj Yes. The problem is not in the part you posted. Post the whole files.

              – Gilles
              Aug 11 '16 at 7:51













              0














              Quite simply, you simply exit the current shell using multiple exits





              share








              New contributor



              xdwd is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
              Check out our Code of Conduct.
























                0














                Quite simply, you simply exit the current shell using multiple exits





                share








                New contributor



                xdwd is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.






















                  0












                  0








                  0







                  Quite simply, you simply exit the current shell using multiple exits





                  share








                  New contributor



                  xdwd is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                  Check out our Code of Conduct.









                  Quite simply, you simply exit the current shell using multiple exits






                  share








                  New contributor



                  xdwd is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                  Check out our Code of Conduct.







                  share


                  share






                  New contributor



                  xdwd is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                  Check out our Code of Conduct.








                  answered 4 mins ago









                  xdwdxdwd

                  1




                  1




                  New contributor



                  xdwd is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                  Check out our Code of Conduct.




                  New contributor




                  xdwd is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                  Check out our Code of Conduct.
































                      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%2f302551%2fenvironment-variable-also-getting-printed%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

                      Hudson River Historic District Contents Geography History The district today Aesthetics Cultural...

                      The number designs the writing. Feandra Aversely Definition: The act of ingrafting a sprig or shoot of one...

                      Ayherre Geografie Demografie Externe links Navigatiemenu43° 23′ NB, 1° 15′ WL43° 23′ NB, 1°...