public inbox for cygwin-patches@cygwin.com
 help / color / mirror / Atom feed
From: Corinna Vinschen <corinna-cygwin@cygwin.com>
To: cygwin-patches@cygwin.com
Subject: Re: [PATCH] Cygwin: doc: Update postinstall/preremove scripts
Date: Mon, 13 Mar 2023 10:31:06 +0100	[thread overview]
Message-ID: <ZA7tWpqAmlcKg+v7@calimero.vinschen.de> (raw)
In-Reply-To: <20230308141719.7361-1-jon.turney@dronecode.org.uk>

Hi Jon,

On Mar  8 14:17, Jon Turney wrote:
> Update postinstall/preremove scripts to use CYGWIN_START_MENU_SUFFIX and
> CYGWIN_SETUP_OPTIONS.

It would be great if you could explain your change in the commit
message...

>  winsup/doc/etc.postinstall.cygwin-doc.sh | 19 +++++++++++++++----
>  winsup/doc/etc.preremove.cygwin-doc.sh   |  8 ++++++--
>  2 files changed, 21 insertions(+), 6 deletions(-)
> 
> diff --git a/winsup/doc/etc.postinstall.cygwin-doc.sh b/winsup/doc/etc.postinstall.cygwin-doc.sh
> index 97f88a16d..313c1d3ff 100755
> --- a/winsup/doc/etc.postinstall.cygwin-doc.sh
> +++ b/winsup/doc/etc.postinstall.cygwin-doc.sh
> @@ -36,9 +36,20 @@ do
>  	fi
>  done
>  
> +# setup was run with options not to create startmenu items
> +case ${CYGWIN_SETUP_OPTIONS} in
> +  *no-startmenu*)
> +    exit 0
> +    ;;
> +esac
> +
>  # Cygwin Start Menu directory
> -case $(uname -s) in *-WOW*) wow64=" (32-bit)" ;; esac
> -smpc_dir="$($cygp $CYGWINFORALL -P -U --)/Cygwin${wow64}"
> +if [ ! -v CYGWIN_START_MENU_SUFFIX ]

Isn't -v a bash extension? Ideally the shebang should reflect that.
Otherwise, -z?


Thanks,
Corinna

  reply	other threads:[~2023-03-13  9:31 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-08 14:17 Jon Turney
2023-03-13  9:31 ` Corinna Vinschen [this message]
2023-03-13 14:18   ` Jon Turney
2023-03-13 16:06     ` Corinna Vinschen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZA7tWpqAmlcKg+v7@calimero.vinschen.de \
    --to=corinna-cygwin@cygwin.com \
    --cc=cygwin-patches@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).