Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6850181
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T01:05:33+00:00 2026-05-27T01:05:33+00:00

When I do locate 50local.policy | xargs vim, I get the error Vim: Warnung:

  • 0

When I do “locate 50local.policy | xargs vim”, I get the error “Vim: Warnung: Die Eingabe kommt nicht von einem Terminal” (translation: Vim: Warning: The input does not come from a terminal).

I can edit successfully with vim but after I close it my terminal behaves strangely (I can’t type letters and when I hit enter the shell prompt simply gets repeated.
When I do it with “xargs gedit” it does not create those problems.

I use Ubuntu 11.10 with Gnome 3 and Gnome-Terminal 3.0.1.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T01:05:34+00:00Added an answer on May 27, 2026 at 1:05 am

    Vim expects to be connected to a real terminal and sends codes appropriate to that.

    Reset the terminal with

    reset
    

    The easiest workaround:

    locate 50local.policy | xargs gvim
    

    Rationale gui vim doesn’t require a terminal

    Otherwise:

    vim $(locate 50local.policy)
    

    Rationale vim is started directly connected to the terminal (instead of as a child process under xargs which in turn runs in a subshell with stdin/stdout connected to pipes instead of a terminal). It is like saying

    vim /usr/some/dir/50local.policy /usr/local/some/dir/50local.policy
    

    Alternatively

    You can dodge the issue by not starting vim with the arguments, but adding the arguments from vim! Vim is in fact a lot better at running shells than shells are at running vim.

    Whilst in vim:

    :args `locate 50local.policy`
    :rewind
    

    This sets the argument list to the files returned from the shell command between the ticks; :rewind then goes to the first file from that list.
    If you were editing multiple matches, try this:

    :w|next
    

    This sequence of commands (separated by |) writes the current buffer to file, then goes to the next file in the args list.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to locate the source of the error in this trace: org.springframework.web.servlet.handler.AbstractHandlerExceptionResolver logException:
I'm trying to locate an open source business rules engine that has a decent
I'm looking to locate a good resource (book or otherwise) on safety critical systems
im trying to locate the position of the minimum value in a vector, using
How do I locate resources on the classpath in java? Specifically stuff that ends
I am trying to locate an evil plugin that includes a stoneage version of
Need to locate the following pattern: The letter I followed by a space then
I want to centrally locate all of my application settings in the database. I
I need to locate the node within an xml file by its value using
How do I locate the current file in the project structure? (Similar to Visual

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.