From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 66670 invoked by alias); 31 Aug 2017 15:50:53 -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 66552 invoked by uid 89); 31 Aug 2017 15:50:52 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_00,CYGWIN_OWNER_BODY,FREEMAIL_FROM,GIT_PATCH_2,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=ham version=3.3.2 spammy=Michel, Playing, cyg, Bash X-HELO: mail-io0-f179.google.com Received: from mail-io0-f179.google.com (HELO mail-io0-f179.google.com) (209.85.223.179) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 31 Aug 2017 15:50:42 +0000 Received: by mail-io0-f179.google.com with SMTP id 81so736116ioj.5 for ; Thu, 31 Aug 2017 08:50:42 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=BNmhP8HEfG9xzXEb9eO1KMeVkRQldOxV7i+DgiQSwuo=; b=QDgy+UBsl7N4icSNUS+XSzLsAUSB4HhiBPWj6EtS7eiWUAFnWqVKyK11B1F5Fy/k9h N5IQzT7kYUw3yA0l8Mew/3sA0Kef068jRwFhxf8LshaxQSnm5fmfOY/Mz3hSOyMaITL4 2YZ1zSp/zQXMciUUuaYC3x1Pa7jioJxU+TGvnNOq0BNwA2Doh/8R/lvNVCR2ZQ6D6cGM YOR0PI9FXXbFdLOTUIJ6spuysEP/dtxTa0Nk026CkF/FaIkssqw7G3n38QRJ2ZGOIjJv jxd9K40STpg9esAoT8EvFyTH5lab1P7+i0L/9IRqTU8XoRoyxjBW4MsmbRBaHKYZa404 bKzQ== X-Gm-Message-State: AHPjjUh/fKYZH1NQpk2ui1w1CGmCqBHAm1wl3gkkzpfoT/rWQDQmNHz6 H+RZGrxPtHNsrmF9 X-Google-Smtp-Source: ADKCNb7YMSx2tfpPI80dVEOm2SELFAPMisIW0E3seHHFw2fuvTXK//HNNdR6AMt2q47JY2h3bZXsDg== X-Received: by 10.36.130.5 with SMTP id t5mr1199858itd.7.1504194640951; Thu, 31 Aug 2017 08:50:40 -0700 (PDT) Received: from [192.168.0.6] (d4-50-42-50.try.wideopenwest.com. [50.4.50.42]) by smtp.gmail.com with ESMTPSA id o1sm22216iod.6.2017.08.31.08.50.39 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 31 Aug 2017 08:50:40 -0700 (PDT) Subject: Re: Bash monitor mode remains enabled if disabled in .bashrc To: "cygwin@cygwin.com" References: <000701d321e7$6ed52220$4c7f6660$@rogers.com> <54420842-610d-aa87-5000-5c531cf7d2a1@gmail.com> <000601d32265$f9f85880$ede90980$@rogers.com> From: cyg Simple Message-ID: Date: Thu, 31 Aug 2017 15:50:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <000601d32265$f9f85880$ede90980$@rogers.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-IsSubscribed: yes X-SW-Source: 2017-08/txt/msg00277.txt.bz2 Keep responses to the list and not the individual responders. Forwarded on your behalf. On 8/31/2017 10:32 AM, Michel LaBarre wrote: > Thanks for the reply. > > Quick answer (repeated interleaved below): > - my .bash_profile does indeed source .bashrc > - I added an echo to .bashrc to be doubly sure - it displays as expected > >> -----Original Message----- >> From: cygwin-owner@cygwin.com [mailto:cygwin-owner@cygwin.com] On >> Behalf Of cyg Simple >> Sent: August-31-17 8:31 AM >> To: cygwin@cygwin.com >> Subject: Re: Bash monitor mode remains enabled if disabled in .bashrc >> >> On 8/30/2017 7:26 PM, Michel LaBarre wrote: >>> Playing with set -m/+m and shopt -s lastpipe, in an interactive bash shell, >>> I came across a situation >>> which is minor unless it has broader implications for others that I do not >>> know about. >>> >>> Specifically if "set +m" is present in .bashrc, it looks like job control >>> (monitor mode) is off >>> in an interactive shell (as per "echo $-") but it is actually on. >>> >>> I ran into this with "shopt -s lastpipe" behaviour with and without job >>> control. >>> I can also reproduce it with "sleep 25&" then "fg" will fail with "no job >>> control". >>> >>> If I "set +m" within the interactive shell rather than, or in addition to, >>> .bashrc, both the >>> flags ($-) and behaviour (lastpipe and fg) reflect job control being off. >>> >> >> Are you sure that .bashrc is being sourced? The initial start of an >> interactive shell doesn't read .bashrc by default. It reads >> bash_profile when starting interactive mode. Now most likely your >> bash_profile contains lines to check the existence of .bashrc and >> source it but you need to check. >> > My .bash_profile does indeed source .bashrc > I added an echo to .bashrc to be doubly sure - it displays as expected> -- > -- cyg Simple -- 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