From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6459 invoked by alias); 16 Feb 2016 10:37:04 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 6438 invoked by uid 89); 16 Feb 2016 10:37:03 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.3 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2 spammy=mintty, UD:ac.uk, sxe, shq X-HELO: plane.gmane.org Received: from plane.gmane.org (HELO plane.gmane.org) (80.91.229.3) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Tue, 16 Feb 2016 10:37:02 +0000 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1aVczp-00064j-PA for cygwin@cygwin.com; Tue, 16 Feb 2016 11:36:42 +0100 Received: from S010690fba62c4bda.cg.shawcable.net ([174.0.238.184]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 16 Feb 2016 11:36:41 +0100 Received: from Brian.Inglis by S010690fba62c4bda.cg.shawcable.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 16 Feb 2016 11:36:41 +0100 To: cygwin@cygwin.com From: Brian Inglis Subject: Re: Unable to use "grep" command in VIM 7.4 Date: Tue, 16 Feb 2016 10:37:00 -0000 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit User-Agent: Loom/3.14 (http://gmane.org/) X-IsSubscribed: yes X-SW-Source: 2016-02/txt/msg00243.txt.bz2 Jeremy Leung email.ulster.ac.uk> writes: > I have recently installed the latest version of Cygwin on my Windows 8 laptop, and everything is working as expected. > However the issue I am having is that when I'm in VIM, and try to use the ":grep" command, it says that the > command is not available in this version. > Why is this the case when I can use grep outside of VIM with no issues, and how could I solve this? Have you updated cygwin base and vim recently? In cygwin mintty window type which vim and check output is: /usr/bin/vim In cygwin mintty window type vim In vim type: :!which grep and check you get: /usr/bin/grep In vim type: :version and check +quickfix is included not -quickfix. In vim type: :set grepprg? grepformat? and check these look like: grepprg=grep -n $* /dev/null grepformat=%f:%l:%m,%f:%l%m,%f %l%m You might have to change grepprg in your ~/.vimrc to :set grepprg=grep -n "$@" /dev/null to handle spaces in arguments properly or type "\ " instead of " ". In vim type: :set sh? shq? sxq? sxe? shcf? srr? stmp? and check these look like: shell=/bin/bash shellquote= shellxquote= shellxescape= shellcmdflag=-c shellredir=>%s 2>&1 shelltemp In vim type your grep command and post that from : and the output for more help. You might also want to try vim ":help grep" and use ":vim" aka ":vim[grep]" instead of ":grep" for searching external files. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple