How to launch terminal + cal command?












1















I have an issue in which I was unable to find a solution till now. While I use several scripts to launch specific commands through URXvt:



#!/bin/sh

urxvt -geometry 40x20+990+30 -w 0 -b 0 -e nmtui


when I try to launch the same window with cal command I get.. no urxvt window!



Is there a way to do it?










share|improve this question



























    1















    I have an issue in which I was unable to find a solution till now. While I use several scripts to launch specific commands through URXvt:



    #!/bin/sh

    urxvt -geometry 40x20+990+30 -w 0 -b 0 -e nmtui


    when I try to launch the same window with cal command I get.. no urxvt window!



    Is there a way to do it?










    share|improve this question

























      1












      1








      1








      I have an issue in which I was unable to find a solution till now. While I use several scripts to launch specific commands through URXvt:



      #!/bin/sh

      urxvt -geometry 40x20+990+30 -w 0 -b 0 -e nmtui


      when I try to launch the same window with cal command I get.. no urxvt window!



      Is there a way to do it?










      share|improve this question














      I have an issue in which I was unable to find a solution till now. While I use several scripts to launch specific commands through URXvt:



      #!/bin/sh

      urxvt -geometry 40x20+990+30 -w 0 -b 0 -e nmtui


      when I try to launch the same window with cal command I get.. no urxvt window!



      Is there a way to do it?







      scripts calendar rxvt






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Feb 9 at 9:20









      Giorgos_KappaGiorgos_Kappa

      61




      61






















          1 Answer
          1






          active

          oldest

          votes


















          1














          urxvt has a -hold|+hold option to “not immediately destroy its window when the program executed within it exits” (see man urxvt):



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -hold -e cal


          A different approach would be to spawn a shell (which doesn’t just exit) to keep the window open:



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -e 'cal;sh'





          share|improve this answer


























          • The first command seems to do the trick (the second gives no output/terminal window), however I cannot close the terminal window afterwards unless I kill it (in i3wm its shift+mod+Q)

            – Giorgos_Kappa
            Feb 9 at 11:55











          • @Giorgos_Kappa Kudos for using a WM as great as i3! I changed the second command, please try now. As for the first: Yes, that’s expected. How did you want to close the window?

            – dessert
            Feb 9 at 13:04











          • thank you for your time and effort! The second command is still not working but I am fine with the first one. In short I am using urxvt as a popup-window for some actions in polybar. This one in example is launched uppon left click on the time text and creates a simple dialog window with the current month calendar. I don't want to use gsimplecal or any other gtk derivative so what I try to do is to close this window without killing it xD

            – Giorgos_Kappa
            Feb 9 at 18:28











          • @Giorgos_Kappa Oh, that’s a peculiar use case – I think I’d use osd_cat from the xosd-bin for a thing like that, or maybe yad/zenityor kill the terminal window from the script after some time.

            – dessert
            Feb 10 at 7:41














          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "89"
          };
          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: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          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%2faskubuntu.com%2fquestions%2f1116882%2fhow-to-launch-terminal-cal-command%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









          1














          urxvt has a -hold|+hold option to “not immediately destroy its window when the program executed within it exits” (see man urxvt):



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -hold -e cal


          A different approach would be to spawn a shell (which doesn’t just exit) to keep the window open:



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -e 'cal;sh'





          share|improve this answer


























          • The first command seems to do the trick (the second gives no output/terminal window), however I cannot close the terminal window afterwards unless I kill it (in i3wm its shift+mod+Q)

            – Giorgos_Kappa
            Feb 9 at 11:55











          • @Giorgos_Kappa Kudos for using a WM as great as i3! I changed the second command, please try now. As for the first: Yes, that’s expected. How did you want to close the window?

            – dessert
            Feb 9 at 13:04











          • thank you for your time and effort! The second command is still not working but I am fine with the first one. In short I am using urxvt as a popup-window for some actions in polybar. This one in example is launched uppon left click on the time text and creates a simple dialog window with the current month calendar. I don't want to use gsimplecal or any other gtk derivative so what I try to do is to close this window without killing it xD

            – Giorgos_Kappa
            Feb 9 at 18:28











          • @Giorgos_Kappa Oh, that’s a peculiar use case – I think I’d use osd_cat from the xosd-bin for a thing like that, or maybe yad/zenityor kill the terminal window from the script after some time.

            – dessert
            Feb 10 at 7:41


















          1














          urxvt has a -hold|+hold option to “not immediately destroy its window when the program executed within it exits” (see man urxvt):



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -hold -e cal


          A different approach would be to spawn a shell (which doesn’t just exit) to keep the window open:



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -e 'cal;sh'





          share|improve this answer


























          • The first command seems to do the trick (the second gives no output/terminal window), however I cannot close the terminal window afterwards unless I kill it (in i3wm its shift+mod+Q)

            – Giorgos_Kappa
            Feb 9 at 11:55











          • @Giorgos_Kappa Kudos for using a WM as great as i3! I changed the second command, please try now. As for the first: Yes, that’s expected. How did you want to close the window?

            – dessert
            Feb 9 at 13:04











          • thank you for your time and effort! The second command is still not working but I am fine with the first one. In short I am using urxvt as a popup-window for some actions in polybar. This one in example is launched uppon left click on the time text and creates a simple dialog window with the current month calendar. I don't want to use gsimplecal or any other gtk derivative so what I try to do is to close this window without killing it xD

            – Giorgos_Kappa
            Feb 9 at 18:28











          • @Giorgos_Kappa Oh, that’s a peculiar use case – I think I’d use osd_cat from the xosd-bin for a thing like that, or maybe yad/zenityor kill the terminal window from the script after some time.

            – dessert
            Feb 10 at 7:41
















          1












          1








          1







          urxvt has a -hold|+hold option to “not immediately destroy its window when the program executed within it exits” (see man urxvt):



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -hold -e cal


          A different approach would be to spawn a shell (which doesn’t just exit) to keep the window open:



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -e 'cal;sh'





          share|improve this answer















          urxvt has a -hold|+hold option to “not immediately destroy its window when the program executed within it exits” (see man urxvt):



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -hold -e cal


          A different approach would be to spawn a shell (which doesn’t just exit) to keep the window open:



          urxvt -geometry 40x20+990+30 -w 0 -b 0 -e 'cal;sh'






          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Feb 9 at 12:59

























          answered Feb 9 at 10:59









          dessertdessert

          25.3k673107




          25.3k673107













          • The first command seems to do the trick (the second gives no output/terminal window), however I cannot close the terminal window afterwards unless I kill it (in i3wm its shift+mod+Q)

            – Giorgos_Kappa
            Feb 9 at 11:55











          • @Giorgos_Kappa Kudos for using a WM as great as i3! I changed the second command, please try now. As for the first: Yes, that’s expected. How did you want to close the window?

            – dessert
            Feb 9 at 13:04











          • thank you for your time and effort! The second command is still not working but I am fine with the first one. In short I am using urxvt as a popup-window for some actions in polybar. This one in example is launched uppon left click on the time text and creates a simple dialog window with the current month calendar. I don't want to use gsimplecal or any other gtk derivative so what I try to do is to close this window without killing it xD

            – Giorgos_Kappa
            Feb 9 at 18:28











          • @Giorgos_Kappa Oh, that’s a peculiar use case – I think I’d use osd_cat from the xosd-bin for a thing like that, or maybe yad/zenityor kill the terminal window from the script after some time.

            – dessert
            Feb 10 at 7:41





















          • The first command seems to do the trick (the second gives no output/terminal window), however I cannot close the terminal window afterwards unless I kill it (in i3wm its shift+mod+Q)

            – Giorgos_Kappa
            Feb 9 at 11:55











          • @Giorgos_Kappa Kudos for using a WM as great as i3! I changed the second command, please try now. As for the first: Yes, that’s expected. How did you want to close the window?

            – dessert
            Feb 9 at 13:04











          • thank you for your time and effort! The second command is still not working but I am fine with the first one. In short I am using urxvt as a popup-window for some actions in polybar. This one in example is launched uppon left click on the time text and creates a simple dialog window with the current month calendar. I don't want to use gsimplecal or any other gtk derivative so what I try to do is to close this window without killing it xD

            – Giorgos_Kappa
            Feb 9 at 18:28











          • @Giorgos_Kappa Oh, that’s a peculiar use case – I think I’d use osd_cat from the xosd-bin for a thing like that, or maybe yad/zenityor kill the terminal window from the script after some time.

            – dessert
            Feb 10 at 7:41



















          The first command seems to do the trick (the second gives no output/terminal window), however I cannot close the terminal window afterwards unless I kill it (in i3wm its shift+mod+Q)

          – Giorgos_Kappa
          Feb 9 at 11:55





          The first command seems to do the trick (the second gives no output/terminal window), however I cannot close the terminal window afterwards unless I kill it (in i3wm its shift+mod+Q)

          – Giorgos_Kappa
          Feb 9 at 11:55













          @Giorgos_Kappa Kudos for using a WM as great as i3! I changed the second command, please try now. As for the first: Yes, that’s expected. How did you want to close the window?

          – dessert
          Feb 9 at 13:04





          @Giorgos_Kappa Kudos for using a WM as great as i3! I changed the second command, please try now. As for the first: Yes, that’s expected. How did you want to close the window?

          – dessert
          Feb 9 at 13:04













          thank you for your time and effort! The second command is still not working but I am fine with the first one. In short I am using urxvt as a popup-window for some actions in polybar. This one in example is launched uppon left click on the time text and creates a simple dialog window with the current month calendar. I don't want to use gsimplecal or any other gtk derivative so what I try to do is to close this window without killing it xD

          – Giorgos_Kappa
          Feb 9 at 18:28





          thank you for your time and effort! The second command is still not working but I am fine with the first one. In short I am using urxvt as a popup-window for some actions in polybar. This one in example is launched uppon left click on the time text and creates a simple dialog window with the current month calendar. I don't want to use gsimplecal or any other gtk derivative so what I try to do is to close this window without killing it xD

          – Giorgos_Kappa
          Feb 9 at 18:28













          @Giorgos_Kappa Oh, that’s a peculiar use case – I think I’d use osd_cat from the xosd-bin for a thing like that, or maybe yad/zenityor kill the terminal window from the script after some time.

          – dessert
          Feb 10 at 7:41







          @Giorgos_Kappa Oh, that’s a peculiar use case – I think I’d use osd_cat from the xosd-bin for a thing like that, or maybe yad/zenityor kill the terminal window from the script after some time.

          – dessert
          Feb 10 at 7:41




















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Ask Ubuntu!


          • 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%2faskubuntu.com%2fquestions%2f1116882%2fhow-to-launch-terminal-cal-command%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

          Human spaceflight

          Can not write log (Is /dev/pts mounted?) - openpty in Ubuntu-on-Windows?

          File:DeusFollowingSea.jpg