diff -Nru cygwin/bin/mkzsh cygwin/bin/mkzsh --- cygwin/bin/mkzsh 1970-01-01 09:00:00.000000000 +0900 +++ cygwin/bin/mkzsh 2020-06-04 05:26:04.926454800 +0900 @@ -0,0 +1,73 @@ +#!/bin/zsh + +ME=`basename $0` +batfile=/zsh.bat +iconpath=/cygwin.ico +shortcutname="Cygwin Zsh" + +all_opt="" +do_desktop="" +do_menu="" + +#rootpath=`regtool get '/machine/SOFTWARE/Cygnus Solutions/Cygwin/mounts v2/\//native'` +rootpath=`mount | grep ' / ' | awk '{ print $1 }' | tr / '\\\\'` +rootdrive=`echo "$rootpath" | sed 's/\(.:\).*/\1/'` + +CreateZshBat() +{ + echo "Creating $batfile ..." +# Create the zsh.bat file + + cat > $batfile </): +# gid is not in /etc/group +# uid is in /etc/passwd +# pgsid is in /etc/group (and does not match gid) +# mkgroup: +# gid is not in /etc/group +# uid is in /etc/passwd +# pgsid is not in /etc/group +# +# If this message keeps appearing and you are sure it's a mistake (ie, don't +# email about it!), comment out the test below. +case "$(/usr/bin/id -ng)" in +mkpasswd ) + echo "Your group is currently \"mkpasswd\". This indicates that your" + echo "gid is not in /etc/group and your uid is not in /etc/passwd." + echo + echo "The /etc/passwd (and possibly /etc/group) files should be rebuilt." + echo "See the man pages for mkpasswd and mkgroup then, for example, run" + echo + echo "mkpasswd -l [-d] > /etc/passwd" + echo "mkgroup -l [-d] > /etc/group" + echo + echo "Note that the -d switch is necessary for domain users." + ;; +passwd/group_GID_clash* ) + echo "Your group is currently \"passwd/group_GID_clash(gid/pgsid)\". This" + echo "indicates that your gid is not in /etc/group, but the pgsid (primary " + echo "group associated with your SID) is in /etc/group." + echo + echo "The /etc/passwd (and possibly /etc/group) files should be rebuilt." + echo "See the man pages for mkpasswd and mkgroup then, for example, run" + echo + echo "mkpasswd -l [-d] > /etc/passwd" + echo "mkgroup -l [-d] > /etc/group" + echo + echo "Note that the -d switch is necessary for domain users." + ;; +mkgroup ) + echo "Your group is currently \"mkgroup\". This indicates that neither" + echo "your gid nor your pgsid (primary group associated with your SID)" + echo "is in /etc/group." + echo + echo "The /etc/group (and possibly /etc/passwd) files should be rebuilt." + echo "See the man pages for mkpasswd and mkgroup then, for example, run" + echo + echo "mkpasswd -l [-d] > /etc/passwd" + echo "mkgroup -l [-d] > /etc/group" + echo + echo "Note that the -d switch is necessary for domain users." + ;; +esac