tmux and Powerline: working configuration

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP












7














Background



I found very interesting the Powerline project. After several attempts, I managed to get it to work correctly for Vim. Then I did proceed with enabling it for tmux, by pasting the following line in my ~/.tmux.conf.



source 'repository_root/powerline/bindings/tmux/powerline.conf'


It doesn't work as expected. This is the way it looks at the moment (plus the line above I pasted in the configuration file).



tmux and Powerline



Question



How can I get it to work as expected?




Expectation: basically, date and time on the right side.



left side of tmuxright side of tmux



These screenshots come from another project, tmux-powerline, which evolved to Powerline. Therefore I expect the new plugin to have a similar status line organisation. Furthermore, this "expectation" is supported by this configuration file for tmux.




Rewording the question



I'm trying to get Powerline work correctly for tmux. The left part (13 > 1 > bash > 2 > vim >) is fine, the right one (< Sat < 2012-06-16 < 18:51) is missing. About tmux's alternative status bars, I do have already mine, nicely polished ;) My question, here, is only about getting Powerline working properly, otherwise I believe vim-airline would do a better job as a even lighter plug-in.



Further information



Vim version: VIM - Vi IMproved 7.4
tmux version: tmux 1.8










share|improve this question























  • From your screenshot you are editing ./.tmux.conf but it isn't clear what directory you are in. Can you verify that you are in your home directory and not accidentally somewhere else?
    – casey
    Mar 12 '14 at 4:13










  • Sure, :pwd says /home/atcold which is my ~
    – Atcold
    Mar 12 '14 at 4:14










  • Your configuration is working (look at the changed status line). It's different from the screenshot because (1) the screenshot is taken from another program tmux-powerline and (2) that's not the default behavior. You need to add the config from the link in your quote.
    – phunehehe
    Mar 12 '14 at 6:10










  • Ok. I've already pointed (1) out in my question, and (2) I don't really know where/how to add the config (which is installed automatically with the program in ~/local/lib/python2.7/site-packages/powerline/config_files/themes/tmux/default.json and I copied to ~/config/powerline/themes/tmux/default.json as explained here).
    – Atcold
    Mar 12 '14 at 6:20











  • Thank you for your contribution! I've tried airline and quite a few suggestions; for me the real issue is just file name, so something simple such as the solution with the biggest code sample here was quite sufficient. As you've found out I've witnessed how something like tmux can also multiplex the difficulties associated with the terminal configuration.
    – jus cogens prime
    Mar 13 '14 at 0:54
















7














Background



I found very interesting the Powerline project. After several attempts, I managed to get it to work correctly for Vim. Then I did proceed with enabling it for tmux, by pasting the following line in my ~/.tmux.conf.



source 'repository_root/powerline/bindings/tmux/powerline.conf'


It doesn't work as expected. This is the way it looks at the moment (plus the line above I pasted in the configuration file).



tmux and Powerline



Question



How can I get it to work as expected?




Expectation: basically, date and time on the right side.



left side of tmuxright side of tmux



These screenshots come from another project, tmux-powerline, which evolved to Powerline. Therefore I expect the new plugin to have a similar status line organisation. Furthermore, this "expectation" is supported by this configuration file for tmux.




Rewording the question



I'm trying to get Powerline work correctly for tmux. The left part (13 > 1 > bash > 2 > vim >) is fine, the right one (< Sat < 2012-06-16 < 18:51) is missing. About tmux's alternative status bars, I do have already mine, nicely polished ;) My question, here, is only about getting Powerline working properly, otherwise I believe vim-airline would do a better job as a even lighter plug-in.



Further information



Vim version: VIM - Vi IMproved 7.4
tmux version: tmux 1.8










share|improve this question























  • From your screenshot you are editing ./.tmux.conf but it isn't clear what directory you are in. Can you verify that you are in your home directory and not accidentally somewhere else?
    – casey
    Mar 12 '14 at 4:13










  • Sure, :pwd says /home/atcold which is my ~
    – Atcold
    Mar 12 '14 at 4:14










  • Your configuration is working (look at the changed status line). It's different from the screenshot because (1) the screenshot is taken from another program tmux-powerline and (2) that's not the default behavior. You need to add the config from the link in your quote.
    – phunehehe
    Mar 12 '14 at 6:10










  • Ok. I've already pointed (1) out in my question, and (2) I don't really know where/how to add the config (which is installed automatically with the program in ~/local/lib/python2.7/site-packages/powerline/config_files/themes/tmux/default.json and I copied to ~/config/powerline/themes/tmux/default.json as explained here).
    – Atcold
    Mar 12 '14 at 6:20











  • Thank you for your contribution! I've tried airline and quite a few suggestions; for me the real issue is just file name, so something simple such as the solution with the biggest code sample here was quite sufficient. As you've found out I've witnessed how something like tmux can also multiplex the difficulties associated with the terminal configuration.
    – jus cogens prime
    Mar 13 '14 at 0:54














7












7








7


2





Background



I found very interesting the Powerline project. After several attempts, I managed to get it to work correctly for Vim. Then I did proceed with enabling it for tmux, by pasting the following line in my ~/.tmux.conf.



source 'repository_root/powerline/bindings/tmux/powerline.conf'


It doesn't work as expected. This is the way it looks at the moment (plus the line above I pasted in the configuration file).



tmux and Powerline



Question



How can I get it to work as expected?




Expectation: basically, date and time on the right side.



left side of tmuxright side of tmux



These screenshots come from another project, tmux-powerline, which evolved to Powerline. Therefore I expect the new plugin to have a similar status line organisation. Furthermore, this "expectation" is supported by this configuration file for tmux.




Rewording the question



I'm trying to get Powerline work correctly for tmux. The left part (13 > 1 > bash > 2 > vim >) is fine, the right one (< Sat < 2012-06-16 < 18:51) is missing. About tmux's alternative status bars, I do have already mine, nicely polished ;) My question, here, is only about getting Powerline working properly, otherwise I believe vim-airline would do a better job as a even lighter plug-in.



Further information



Vim version: VIM - Vi IMproved 7.4
tmux version: tmux 1.8










share|improve this question















Background



I found very interesting the Powerline project. After several attempts, I managed to get it to work correctly for Vim. Then I did proceed with enabling it for tmux, by pasting the following line in my ~/.tmux.conf.



source 'repository_root/powerline/bindings/tmux/powerline.conf'


It doesn't work as expected. This is the way it looks at the moment (plus the line above I pasted in the configuration file).



tmux and Powerline



Question



How can I get it to work as expected?




Expectation: basically, date and time on the right side.



left side of tmuxright side of tmux



These screenshots come from another project, tmux-powerline, which evolved to Powerline. Therefore I expect the new plugin to have a similar status line organisation. Furthermore, this "expectation" is supported by this configuration file for tmux.




Rewording the question



I'm trying to get Powerline work correctly for tmux. The left part (13 > 1 > bash > 2 > vim >) is fine, the right one (< Sat < 2012-06-16 < 18:51) is missing. About tmux's alternative status bars, I do have already mine, nicely polished ;) My question, here, is only about getting Powerline working properly, otherwise I believe vim-airline would do a better job as a even lighter plug-in.



Further information



Vim version: VIM - Vi IMproved 7.4
tmux version: tmux 1.8







tmux plugin






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 13 '14 at 21:11

























asked Mar 12 '14 at 4:09









Atcold

8322815




8322815











  • From your screenshot you are editing ./.tmux.conf but it isn't clear what directory you are in. Can you verify that you are in your home directory and not accidentally somewhere else?
    – casey
    Mar 12 '14 at 4:13










  • Sure, :pwd says /home/atcold which is my ~
    – Atcold
    Mar 12 '14 at 4:14










  • Your configuration is working (look at the changed status line). It's different from the screenshot because (1) the screenshot is taken from another program tmux-powerline and (2) that's not the default behavior. You need to add the config from the link in your quote.
    – phunehehe
    Mar 12 '14 at 6:10










  • Ok. I've already pointed (1) out in my question, and (2) I don't really know where/how to add the config (which is installed automatically with the program in ~/local/lib/python2.7/site-packages/powerline/config_files/themes/tmux/default.json and I copied to ~/config/powerline/themes/tmux/default.json as explained here).
    – Atcold
    Mar 12 '14 at 6:20











  • Thank you for your contribution! I've tried airline and quite a few suggestions; for me the real issue is just file name, so something simple such as the solution with the biggest code sample here was quite sufficient. As you've found out I've witnessed how something like tmux can also multiplex the difficulties associated with the terminal configuration.
    – jus cogens prime
    Mar 13 '14 at 0:54

















  • From your screenshot you are editing ./.tmux.conf but it isn't clear what directory you are in. Can you verify that you are in your home directory and not accidentally somewhere else?
    – casey
    Mar 12 '14 at 4:13










  • Sure, :pwd says /home/atcold which is my ~
    – Atcold
    Mar 12 '14 at 4:14










  • Your configuration is working (look at the changed status line). It's different from the screenshot because (1) the screenshot is taken from another program tmux-powerline and (2) that's not the default behavior. You need to add the config from the link in your quote.
    – phunehehe
    Mar 12 '14 at 6:10










  • Ok. I've already pointed (1) out in my question, and (2) I don't really know where/how to add the config (which is installed automatically with the program in ~/local/lib/python2.7/site-packages/powerline/config_files/themes/tmux/default.json and I copied to ~/config/powerline/themes/tmux/default.json as explained here).
    – Atcold
    Mar 12 '14 at 6:20











  • Thank you for your contribution! I've tried airline and quite a few suggestions; for me the real issue is just file name, so something simple such as the solution with the biggest code sample here was quite sufficient. As you've found out I've witnessed how something like tmux can also multiplex the difficulties associated with the terminal configuration.
    – jus cogens prime
    Mar 13 '14 at 0:54
















From your screenshot you are editing ./.tmux.conf but it isn't clear what directory you are in. Can you verify that you are in your home directory and not accidentally somewhere else?
– casey
Mar 12 '14 at 4:13




From your screenshot you are editing ./.tmux.conf but it isn't clear what directory you are in. Can you verify that you are in your home directory and not accidentally somewhere else?
– casey
Mar 12 '14 at 4:13












Sure, :pwd says /home/atcold which is my ~
– Atcold
Mar 12 '14 at 4:14




Sure, :pwd says /home/atcold which is my ~
– Atcold
Mar 12 '14 at 4:14












Your configuration is working (look at the changed status line). It's different from the screenshot because (1) the screenshot is taken from another program tmux-powerline and (2) that's not the default behavior. You need to add the config from the link in your quote.
– phunehehe
Mar 12 '14 at 6:10




Your configuration is working (look at the changed status line). It's different from the screenshot because (1) the screenshot is taken from another program tmux-powerline and (2) that's not the default behavior. You need to add the config from the link in your quote.
– phunehehe
Mar 12 '14 at 6:10












Ok. I've already pointed (1) out in my question, and (2) I don't really know where/how to add the config (which is installed automatically with the program in ~/local/lib/python2.7/site-packages/powerline/config_files/themes/tmux/default.json and I copied to ~/config/powerline/themes/tmux/default.json as explained here).
– Atcold
Mar 12 '14 at 6:20





Ok. I've already pointed (1) out in my question, and (2) I don't really know where/how to add the config (which is installed automatically with the program in ~/local/lib/python2.7/site-packages/powerline/config_files/themes/tmux/default.json and I copied to ~/config/powerline/themes/tmux/default.json as explained here).
– Atcold
Mar 12 '14 at 6:20













Thank you for your contribution! I've tried airline and quite a few suggestions; for me the real issue is just file name, so something simple such as the solution with the biggest code sample here was quite sufficient. As you've found out I've witnessed how something like tmux can also multiplex the difficulties associated with the terminal configuration.
– jus cogens prime
Mar 13 '14 at 0:54





Thank you for your contribution! I've tried airline and quite a few suggestions; for me the real issue is just file name, so something simple such as the solution with the biggest code sample here was quite sufficient. As you've found out I've witnessed how something like tmux can also multiplex the difficulties associated with the terminal configuration.
– jus cogens prime
Mar 13 '14 at 0:54











1 Answer
1






active

oldest

votes


















4














From your screenshot it looks like you are running into an issue with your terminal being toe narrow for everything powerline throws into the default tmux config. I ran into something similar recently¹. It seems powerline does not degrade its tmux config for narrow terminals as gracefully as its vim one. There are, however, at least two things you can adjust:



  1. Copy the powerline module configurations to your home directory if you haven't already and modify the theme for tmux. Try dropping some of the modules until what remains will fit on your line.



  2. Change the overall length allotted to the status segments. As these are set in the powerline.conf file you are including, you will need to set them in your .tmux.conf after that include:



    set -g status-left-length 20
    set -g status-right-length 150


    Those are the default values. Try reducing them until something fits.



Note due to the width settings as noted above, if I narrow the terminal below a few more columns, the right status segment will disappear altogether leaving just the left and window pane name segments:



tmux powerline sample



Edit: I just noticed that your tmux version is 1.8. I don't know for sure if that will effect you but I do know there were major changes to the way status bars are configured going into 1.9 and a quick look through the powerline source shows they are doing version checking for < 1.9 and using a degraded feature set for earlier versions. It looks like you should still get a right status of some sort, but that might be complicating your debug process. I highly recommend upgrading to the latest tmux.



¹ I just recently implemented powerline across my zsh, vim, tmux, and awesome configs, spent a week with it, and yesterday abandoned it. It was just too much pain for too little gain, especially with having to work across multiple distros and OSes. I have, however, implemented basically the same thing without the bulk. My tmux config for example is basically a rip-off of the output of powerline in plain tmux values that are ealies to get working on different hosts. For vim I went with airline; for my zsh prompt I wrote my own theme for prezto that uses powerline-ish features.






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%2f119251%2ftmux-and-powerline-working-configuration%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









    4














    From your screenshot it looks like you are running into an issue with your terminal being toe narrow for everything powerline throws into the default tmux config. I ran into something similar recently¹. It seems powerline does not degrade its tmux config for narrow terminals as gracefully as its vim one. There are, however, at least two things you can adjust:



    1. Copy the powerline module configurations to your home directory if you haven't already and modify the theme for tmux. Try dropping some of the modules until what remains will fit on your line.



    2. Change the overall length allotted to the status segments. As these are set in the powerline.conf file you are including, you will need to set them in your .tmux.conf after that include:



      set -g status-left-length 20
      set -g status-right-length 150


      Those are the default values. Try reducing them until something fits.



    Note due to the width settings as noted above, if I narrow the terminal below a few more columns, the right status segment will disappear altogether leaving just the left and window pane name segments:



    tmux powerline sample



    Edit: I just noticed that your tmux version is 1.8. I don't know for sure if that will effect you but I do know there were major changes to the way status bars are configured going into 1.9 and a quick look through the powerline source shows they are doing version checking for < 1.9 and using a degraded feature set for earlier versions. It looks like you should still get a right status of some sort, but that might be complicating your debug process. I highly recommend upgrading to the latest tmux.



    ¹ I just recently implemented powerline across my zsh, vim, tmux, and awesome configs, spent a week with it, and yesterday abandoned it. It was just too much pain for too little gain, especially with having to work across multiple distros and OSes. I have, however, implemented basically the same thing without the bulk. My tmux config for example is basically a rip-off of the output of powerline in plain tmux values that are ealies to get working on different hosts. For vim I went with airline; for my zsh prompt I wrote my own theme for prezto that uses powerline-ish features.






    share|improve this answer



























      4














      From your screenshot it looks like you are running into an issue with your terminal being toe narrow for everything powerline throws into the default tmux config. I ran into something similar recently¹. It seems powerline does not degrade its tmux config for narrow terminals as gracefully as its vim one. There are, however, at least two things you can adjust:



      1. Copy the powerline module configurations to your home directory if you haven't already and modify the theme for tmux. Try dropping some of the modules until what remains will fit on your line.



      2. Change the overall length allotted to the status segments. As these are set in the powerline.conf file you are including, you will need to set them in your .tmux.conf after that include:



        set -g status-left-length 20
        set -g status-right-length 150


        Those are the default values. Try reducing them until something fits.



      Note due to the width settings as noted above, if I narrow the terminal below a few more columns, the right status segment will disappear altogether leaving just the left and window pane name segments:



      tmux powerline sample



      Edit: I just noticed that your tmux version is 1.8. I don't know for sure if that will effect you but I do know there were major changes to the way status bars are configured going into 1.9 and a quick look through the powerline source shows they are doing version checking for < 1.9 and using a degraded feature set for earlier versions. It looks like you should still get a right status of some sort, but that might be complicating your debug process. I highly recommend upgrading to the latest tmux.



      ¹ I just recently implemented powerline across my zsh, vim, tmux, and awesome configs, spent a week with it, and yesterday abandoned it. It was just too much pain for too little gain, especially with having to work across multiple distros and OSes. I have, however, implemented basically the same thing without the bulk. My tmux config for example is basically a rip-off of the output of powerline in plain tmux values that are ealies to get working on different hosts. For vim I went with airline; for my zsh prompt I wrote my own theme for prezto that uses powerline-ish features.






      share|improve this answer

























        4












        4








        4






        From your screenshot it looks like you are running into an issue with your terminal being toe narrow for everything powerline throws into the default tmux config. I ran into something similar recently¹. It seems powerline does not degrade its tmux config for narrow terminals as gracefully as its vim one. There are, however, at least two things you can adjust:



        1. Copy the powerline module configurations to your home directory if you haven't already and modify the theme for tmux. Try dropping some of the modules until what remains will fit on your line.



        2. Change the overall length allotted to the status segments. As these are set in the powerline.conf file you are including, you will need to set them in your .tmux.conf after that include:



          set -g status-left-length 20
          set -g status-right-length 150


          Those are the default values. Try reducing them until something fits.



        Note due to the width settings as noted above, if I narrow the terminal below a few more columns, the right status segment will disappear altogether leaving just the left and window pane name segments:



        tmux powerline sample



        Edit: I just noticed that your tmux version is 1.8. I don't know for sure if that will effect you but I do know there were major changes to the way status bars are configured going into 1.9 and a quick look through the powerline source shows they are doing version checking for < 1.9 and using a degraded feature set for earlier versions. It looks like you should still get a right status of some sort, but that might be complicating your debug process. I highly recommend upgrading to the latest tmux.



        ¹ I just recently implemented powerline across my zsh, vim, tmux, and awesome configs, spent a week with it, and yesterday abandoned it. It was just too much pain for too little gain, especially with having to work across multiple distros and OSes. I have, however, implemented basically the same thing without the bulk. My tmux config for example is basically a rip-off of the output of powerline in plain tmux values that are ealies to get working on different hosts. For vim I went with airline; for my zsh prompt I wrote my own theme for prezto that uses powerline-ish features.






        share|improve this answer














        From your screenshot it looks like you are running into an issue with your terminal being toe narrow for everything powerline throws into the default tmux config. I ran into something similar recently¹. It seems powerline does not degrade its tmux config for narrow terminals as gracefully as its vim one. There are, however, at least two things you can adjust:



        1. Copy the powerline module configurations to your home directory if you haven't already and modify the theme for tmux. Try dropping some of the modules until what remains will fit on your line.



        2. Change the overall length allotted to the status segments. As these are set in the powerline.conf file you are including, you will need to set them in your .tmux.conf after that include:



          set -g status-left-length 20
          set -g status-right-length 150


          Those are the default values. Try reducing them until something fits.



        Note due to the width settings as noted above, if I narrow the terminal below a few more columns, the right status segment will disappear altogether leaving just the left and window pane name segments:



        tmux powerline sample



        Edit: I just noticed that your tmux version is 1.8. I don't know for sure if that will effect you but I do know there were major changes to the way status bars are configured going into 1.9 and a quick look through the powerline source shows they are doing version checking for < 1.9 and using a degraded feature set for earlier versions. It looks like you should still get a right status of some sort, but that might be complicating your debug process. I highly recommend upgrading to the latest tmux.



        ¹ I just recently implemented powerline across my zsh, vim, tmux, and awesome configs, spent a week with it, and yesterday abandoned it. It was just too much pain for too little gain, especially with having to work across multiple distros and OSes. I have, however, implemented basically the same thing without the bulk. My tmux config for example is basically a rip-off of the output of powerline in plain tmux values that are ealies to get working on different hosts. For vim I went with airline; for my zsh prompt I wrote my own theme for prezto that uses powerline-ish features.







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited Jun 6 '14 at 7:21

























        answered Jun 6 '14 at 7:03









        Caleb

        50.3k9146191




        50.3k9146191



























            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.





            Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


            Please pay close attention to the following guidance:


            • 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%2f119251%2ftmux-and-powerline-working-configuration%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 check contact read email or not when send email to Individual?

            Displaying single band from multi-band raster using QGIS

            How many registers does an x86_64 CPU actually have?