Clear screen automatically, how to do this ?

When closing a CLI program the command prompt always appears in the middle of the screen.
How do I avoid that ??
I have a alias cls='clear' in my .bashrc, but how do I make it so the screen clears every time when closing a program ??

Hi,
I thought a bit about it, normally you would use bash's PROMPT_COMMAND, but clearing the prompt after every command would be a bit counter productive. You could use the following small function in your .bashrc though:
clearprompt() {
eval $1
clear
And then just set an alias in your .bashrc for the cli app you want the prompt to clear after its executed, for example:
alias top="clearprompt /usr/bin/top"
you have to use the full path to the command in the alias when you want to give the alias the same name as the command itself otherwise bash segfaults. It's probably a dirty hack I know .
HTH
Last edited by chimeric (2008-02-29 10:53:56)

Similar Messages

  • My iPad 2 only keeps a set number of emails for me to view eventually deleting from the screen. How do stop this as it syncs with my phone and mac book pro neither of which do this?

    My iPad 2 only keeps a set number of emails for me to view eventually deleting from the screen. How do stop this as it syncs with my phone and mac book pro neither of which do this?

    Thanks for that. Much more constructive than the last comment. It's only the restriction code I can't recall, not the access passcode. So I can currently access the device, just not age restricted content. Does that's make a difference? I also wondered if anyone knew how many attempts you get to try to get it right. Now tried 21 times and so far nothing bad has happened but I am concerned I'll eventually be completely locked out of the device. That doesn't seem in the spirit of things though. Surely it's foreseeable that a child could repeatedly try to guess the code so I can't see that it would be right to lock the device down completely in that circumstance, particularly if the access code is being typed in correctly every time.
    Thanks

  • When typing Ff turns it into a foreign language automatically, how to disable this function?

    When typing in Ff turns it into a foreign language like chinese automatically,
    how to disable this function? I am copying and pasting from an outside source in order to fill this info in.
    == This happened ==
    Every time Firefox opened
    == about 3 days ago

    Hi Stefan, thank you for replying, and sorry for the delay.
    Here is an example. https://onedrive.live.com/redir?resid=F3BF58EFEC14E64B!127&authkey=!ABhtu2udead5u-0&ithint=file%2cdocx
    It appears that OneDrive does not show this problem unless you select "edit document" then "edit in word". I have Word 07, and in there it causes the sloppy-looking, different indent sizes I am trying to fix.
    Thank you for any insights you may be able to share.
    Tom

  • Apps upgrade automatically, how to make this stop?

    Just got an LG G2.  My apps upgrade automatically without prompting me to proceed or not, eating up my data limit.  I looked throughout settings for this option or switch, haven't been able to find one.  Anyone know how to change this setting?  Thanks

        crairdan,
    Congratulations on your recent upgrade! We're here to help customize your updating schedule on your new LG G2; I know how important it is important to stay on top of it. The update settings are adjusted in the Play Store app itself. Simply launch Play Store>Menu>Settings>Auto-update Apps>Select your preferred option.
    AdaS_VZW
    Follow us on Twitter at @VZWSupport

  • I am covered by Apple Care, but i have a dent on the corner of my Mac Book Screen. How much does this cost?

    There is a dent in the top left corner, and the screen is a little cracked. I've had my macbook for almost a year and a half. I am covered by the Apple Care Program, not sure how much this costs to fix, or if it's automatically covered... Please help!

    To fix the dent on the screen enclosure the complete unit would need to be replaced. Accidental damages are not covered under the Apple warranties so it would be at your expense. What the cost is only Apple can tell you that. But it would be somewhere around $500. If Retina model more in the $1000 range.

  • My mac is swiping full-screens automatically, how do I stop it?

    My Mac started swiping itself back to the home page automatically, I have tried disabiling the swipe control and it continues. What do I do?

    I have the same issue since this morning. You should check this topic to solve the problem https://discussions.apple.com/message/23672977#23672977

  • Itunes 10.4.1 opens automatically. how to stop this?

    This was never an issue before this last update.  I have always set iTunes to NOT open automatically when I plug in my iPod Touch but now I cannot seem to get it to stop.  Here's what I've tried:
    In the summary tab of my device page in iTunes, the item "Open iTunes when this iPod is connected" is UNCHECKED and GREYED OUT.  But when I connect my iPod to either of my Windows 7 computers, the application starts automatically anyway.
    I did some searching and someone pointed me toward the Preferences pages.  In the "devices" tab I have always checked the box "Prevent iPods, iPhones and iPads from syncing automatically.  Their suggestion was to uncheck this box (which made me nervous).  I did.  When returning to the summary tab of my device page the "Open iTunes when..." was checked.  I unchecked it and hit apply.  It asked me if I really wanted to delete all 114 applications from my iPod.  I chose "cancel".
    I disconnected my iPod and shut down iTunes.
    When I plugged in my iPod again, iTunes started automatically.
    Does this mean I need to delete all my apps and music to get iTunes to NOT start automatically? 
    And to repeat, this was never an issue until I installed the update to 10.4.1.  I had not changed any settings in iTunes.  All I did was install the update and this behaviour began.
    Any help out there?
    Thanks!

    ITunes started opening automatically about every 30 seconds on my P.C. - I realised that the last thing I did when I connected my iPad to my PC (last time using my USB cable connection) was to put a "X" in the box that said "Sync using wifi".  I re-connceted my iPad by the cable  and I unchecked this box,  iTunes stopped opening automatically every 30 seconds.
    My PC was obviously looking for my iPad by wifi every 30 seconds,

  • When opening a new tab, a web page gets opened automatically.How to prevent this?

    ......................

    Hello,
    '''Try Firefox Safe Mode''' to see if the problem goes away. Safe Mode is a troubleshooting mode, which disables most add-ons.
    ''(If you're not using it, switch to the Default theme.)''
    * You can open Firefox 4.0+ in Safe Mode by holding the '''Shift''' key when you open the Firefox desktop or Start menu shortcut.
    * Or open the Help menu and click on the '''Restart with Add-ons Disabled...''' menu item while Firefox is running.
    ''Once you get the pop-up, just select "'Start in Safe Mode"''
    '''''If the issue is not present in Firefox Safe Mode''''', your problem is probably caused by an extension, and you need to figure out which one. Please follow the [[Troubleshooting extensions and themes]] article for that.
    ''To exit the Firefox Safe Mode, just close Firefox and wait a few seconds before opening Firefox for normal use again.''
    If that doesnt work try below before proceeding.
    SCAN with all programs..
    * [http://www.microsoft.com/security/scanner/default.aspx Microsoft Safety Scanner]
    * [http://www.malwarebytes.org/products/malwarebytes_free/ MalwareBytes' Anti-Malware]
    * [http://support.kaspersky.com/faq/?qid=208283363 TDSSKiller - AntiRootkit Utility]
    * [http://www.surfright.nl/en/hitmanpro/ Hitman Pro]
    * [http://www.eset.com/us/online-scanner/ ESET Online Scanner]
    [http://windows.microsoft.com/MSE Microsoft Security Essentials] is a good permanent antivirus for Windows 7/Vista/XP if you don't already have one.
    Further information can be found in the [[Troubleshoot Firefox issues caused by malware]] article.

  • Disk "BLACKBERRY" mounts automatically, how to disable this?

    Very annoying, as it is impossible to just unplug the phone, as one has to "eject" the drive, otherwise the file system on a SD card becomes corrupt.
    Thank you!

    Sorry I use an all new topics option for open threads and missed the MAC forum designator. Let me do a little research and fix my first post.
    Thanks for reminding me to drink at least 3 cups of coffee before posting!
    Bifocals
    Click Accept as Solution for posts that have solved your issue(s)!
    Be sure to click Like! for those who have helped you.
    Install BlackBerry Protect it's a free application designed to help find your lost BlackBerry smartphone, and keep the information on it secure.

  • Billing document is generated automatically How to control ?

    Hi...
       After creating outbound delivery in VL01N  , then the Billing document is also to be generated automatically , How to control this ?
    I want to create the billing document thru VF01 .
    Regards
    Deepa.
    Edited by: Deepa Manian on Jun 27, 2008 5:29 AM

    Dear Deepa,
    Try with this option,
    Check the copying riutines
    Go to transaction VTFL then select your document types then go in to the details of the copy control settings at header level and itemlevel here check the copying routines and logic in volved in those routines.
    As per standard these are copying routines should be
    At header level.
    003-Header/dlv.-related
    At itemlevel
    004 -  Deliv-related item
    007 - Inv.Split (Rec/Div)
    I hope it will help you,
    Regards,
    Murali.

  • Suddenly my homepage Yahoo goes beyond my screen? how do I make it fir my screen?

    I started using Mozilla since Internet Explorer is full of bugs. I've been using it for a few days with no trouble. Suddenly today, Yahoo Homepage became too big for my screen. How to fix this, please?

    Hello,
    Have you tried [[Font size and zoom - increase the size of web pages|Firefox's zoom feature]]? This will help increase the size of web pages.
    * To make things bigger, press '''Ctrl''' and '''&#43''' at the same time.
    * To make things smaller, press '''Ctrl''' and '''-''' at the same time.
    * To reset the size back to normal, press '''Ctrl''' and '''0''' at the same time.

  • When I open iTunes it will automatically go to full screen mode. I can't work out how to turn this off. Only iTunes opens to full screen mode.

    When I open iTunes it will automatically go to full screen mode. I can't work out how to turn this off. Only iTunes opens to full screen mode.

    Go to System Preferences (under the Apple logo in the menu bar).  Choose "General".  Click "Always close windows when quitting an application".
    That should fix it.

  • My iphone 6 turned off while i was using face time and it returns with the screen saying Hello mean its reset automatically how is this possible ? Now it requires an id and password to activate which i do not remember need help ?

    My iphone 6 turned off while i was using face time and it returns with the screen saying Hello mean its reset automatically how is this possible ? Now it requires an id and password to activate which i do not remember need help ? but i do remember the id and password which i was using on itunes and Apple store. please i almoost buy it in 890$ so it will be a big lost please help me.

    shahzadfromlahore wrote:
    Now it requires an id and password to activate which i do not remember need help ? but i do remember the id and password which i was using on itunes and Apple store. please i almoost buy it in 890$ so it will be a big lost please help me
    Who set up the phone? Who's Apple ID was used to activate it?

  • The screen could not rotate automatically while without lock it, how to solve this problem?

    The screen could not rotate automatically while without lock it, how to solve this problem?

    If there isn't a lock symbol at the top of the screen next to the battery indicator then try a soft-reset and see if it rotates after the iPad has restarted : press and hold both the sleep and home buttons for about 10 to 15 seconds (ignore the red slider), after which the Apple logo should appear - you won't lose any content, it's the iPad equivalent of a reboot.

  • Some web sites require you to type words presented in a strange form (Captcha?). The 'Captcha' does not always show up on my screen. How can I fix this?

    I do not know how to make this any more clear. The strange, 'squiggly' words are meant to protect a web site from computerized log ins (I think). If the words are interpreted and entered correctly, you can log in successfully. But since the strangely formed words do not show up on my screen, I cannot continue the process. This does not occur all the time, on some sites the strangely formed words show up, and I can continue the process. Is this a problem with Firefox, my computer, or the web site I am trying to log into?

    If images are missing then check that you aren't blocking images from some domains.
    *Check the permissions for the domain in the current tab in "Tools > Page Info > Permissions"
    *Check that images are enabled: Tools > Options > Content: [X] Load images automatically
    *Check the exceptions in "Tools > Options > Content: Load Images > Exceptions"
    *Check the "Tools > Page Info > Media" tab for blocked images (scroll through all the images with the cursor Down key).
    If an image in the list is grayed and there is a check-mark in the box "<i>Block Images from...</i>" then remove that mark to unblock the images from that domain.
    Make sure that you do not block third-party images permissions.default.images
    *http://kb.mozillazine.org/Images_or_animations_do_not_load
    There are also extensions (Tools > Add-ons > Extensions) and security software (firewall, anti-virus) that can block images.
    Start Firefox in <u>[[Safe Mode]]</u> to check if one of the extensions or if hardware acceleration is causing the problem (switch to the DEFAULT theme: Firefox (Tools) > Add-ons > Appearance/Themes).
    *Don't make any changes on the Safe mode start window.
    *https://support.mozilla.com/kb/Safe+Mode

Maybe you are looking for

  • Problem with CPU Voltage

    Hello I build new PC with: i5-760 Noctua NH-D14 MSI P55-GD65 G.Skill 2x2GB CL7 ECO Antec TruePower New 750W TP-750 TwinTech GF 9600GT I have problem with CPU voltage as even when I set it for example to 1.201v in bios, under load it overshot to 1.256

  • Libvirt-lxc No valid cgroup for machine // systemd-nspawn

    I am getting mad at trying to set up correctly a arch linux container on my guest with libvirt (LXC left me with a broken set up too). Here are some basic info: - custom kernel with user space set - host up-to-date - guest mounted on my root fs /dahl

  • Unable to View Purchase History

    I wanted to view my past purchases so I went to the iTunes stores. Clicked on the view account button and put in my password. I see all of my account information, but there is not a button (like it says in the instructions to view purchase history) t

  • Program to test speed of internal network?

    Hi, Does anyone know of a program that I can use to test the speed of my internal network? A Windows program would be preferable as I am trying to see how much throughput I am getting from my MacBook Pro running Vista over my 802.11n AEBS to my Dell

  • Won't turn on or off and the battery is charg

    I have charged my Zen Micro MP3 via the mains using AC adapter, but I am now unable to turn it on or off by the on/off switch. After charging it remains on, but cannot turn it off unless I remove the battery.</LI> In order to turn it back on I have t