@echo off : -------------------------------------------------------------------- : run this script as an member of local administrators group : Edit this script per the 'MANUAL STEP' hints. : -------------------------------------------------------------------- : -------------------------------------------------------------------- : Synopsis: cygwin initial install -- minimal package list : -------------------------------------------------------------------- : Usage: ourname : No switches, you edit the script itself to customize. : -------------------------------------------------------------------- : ==================================================================== : Copyright (c) 2013 Tom Rodman : -------------------------------------------------------------------- : -- Software License -- : This program is free software: you can redistribute it and/or modify : it under the terms of the GNU General Public License as published by : the Free Software Foundation, either version 3 of the License, or : (at your option) any later version. : : This program is distributed in the hope that it will be useful, : but WITHOUT ANY WARRANTY; without even the implied warranty of : MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the : GNU General Public License for more details. : : You should have received a copy of the GNU General Public License : along with this program. If not, see . : --- set AUT_PATH_DOS=d:\aut : AUT == destination install dir for auxillary utilities, not limited to cygwin. : MANUAL STEP: edit AUT_PATH_DOS as desired. mkdir %AUT_PATH_DOS% set birth=%AUT_PATH_DOS%\birth\cygsetup : birth == installer tools and packages : cygwin install related files and download cache here. : MANUAL STEP: mkdir %birth%, then copy the files below to %birth% dir: : - latest cygwin setup.exe ( http://www.cygwin.com/setup.exe ) : - setacl.exe (download for free from http://helgeklein.com/setacl/ ) : setacl.exe is suggested so the install dir get's permissions that have : worked in the past for me, but not required. set CYGROOTBN=cyg2 : DOS basename for cygwin's root mount dir. : Cygwin to be installed below %AUT_PATH_DOS%\%CYGROOTBN%. : : You may serially maintain more than one cygwin root on a host. : MANUAL STEP: edit CYGROOTBN as wanted : -------------------------------------------------------------------- : define cygwin groups and packages to install : -------------------------------------------------------------------- set package_specs_minimal=-C Admin,Base,System,Perl -P autoconf,autoconf2.1,automake,automake1.10,bash,bash-completion,bc,bind,binutils,bzip2,csih,cygutils,cygwin-doc,dash,diffutils,ed,expect,file,gawk,ipcalc,keychain,libiconv,lynx,ncurses,m4,make,man,mksh,msmtp,netcat,nttcp,openldap,openssh,par,patch,patchutils,p-info,ping,procps,rcs,readline,rebase,rxvt,screen,ssmtp,sysvinit,termcap,time,ttcp,unzip,util-linux,vim,wdiff,wget,which,whois,zip : MANUAL STEP: edit package_specs_minimal as wanted. : Package names are defined in cygwin's setup.ini. : setup.ini will be found after the install in a subdir below %cygwin_downloads_dir%. : -------------------------------------------------------------------- : MANUAL STEPs all done : -------------------------------------------------------------------- set cygroot=%AUT_PATH_DOS%\%CYGROOTBN% : cygwin setup.exe will create this set PATH=%PATH%;%birth% : build dacl.cmd echo setacl -on %%1 -ot file -actn list -lst f:tab;w:o,g,d,s;i:y;s:n > %birth%\dacl.cmd set cygwin_downloads_dir=%birth%\cygdl : will be used during cygwin "install-from-Internet" install as cache if NOT EXIST %cygwin_downloads_dir% ( mkdir %cygwin_downloads_dir% ) echo pls ensure cygwin setup.exe is here: dir %birth% pause @echo. if EXIST %birth%\setacl.exe (goto setacl) else (goto post_setacl) :setacl setacl -on %AUT_PATH_DOS% -ot file -actn clear -clr dacl -actn setprot -op "dacl:p_nc" -actn ace -ace "n:administrators;p:full;i:so,sc;w:dacl" -actn ace -ace "n:everyone;p:read_ex;i:so,sc;w:dacl" @echo. echo about to show perms on AUT_PATH_DOS: pause cmd /c dacl %AUT_PATH_DOS% @echo. :post_setacl @echo. @echo ### echo cygwin GUI installer will use [%cygroot%] for cygwin root dir. @echo. echo Next step runs cygwin installer. It should select packages set by this batch file. @echo. echo You must interact in the GUI to confirm/start the install. You may have to echo pick a mirror site to download from, but in general you may keep clicking on echo 'next', accepting the defaults until the install starts. @echo. pause : #################################################################### : run the install : #################################################################### %birth%\setup -R %cygroot% --no-desktop -l %cygwin_downloads_dir% %package_specs_minimal% : --no-desktop => no desktop shortcuts : could add: -q ( for unattended mode )