public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* installing/updating silently
@ 2023-04-20 13:22 Thomas Schweikle
  0 siblings, 0 replies; only message in thread
From: Thomas Schweikle @ 2023-04-20 13:22 UTC (permalink / raw)
  To: cygwin


[-- Attachment #1.1.1: Type: text/plain, Size: 1527 bytes --]

Hi!

Trying to install or upgrade cygwin silently. Calling a newly downloaded 
setup-x86_64.exe (Power Shell-snipplets):

$URL = "https://www.cygwin.com/setup-x86_64.exe"
$dlp = "C:\INSTALL\Apps\c\cygwin"
$nsf = "$dlp\setup-x86_64.new"
$isf = "$dlp\setup-x86_64.exe"
$isl = "$dlp\setup-x86_64.log"
$ise = "$dlp\setup-x86_64.err"
$cll = "$dlp\setup-x86_64.cll"

$ProgressPreference = 'SilentlyContinue'
Invoke-WebRequest -Uri $URL -OutFile $nsf

$ProgressPreference = 'Continue'
if (Test-Path -Path $isf -PathType Leaf) {
     Remove-Item -Path $isf
}
Rename-Item -Path $nsf -NewName $isf

$SetupOpts = @{
     FilePath = $isf
     ArgumentList = @(
         "--verbose",
         "--delete-orphans",
         "--upgrade-also",
         "--quiet-mode",
         "--wait",
         "--no-desktop",
         "--local-package-dir", "`"$localDir`"",
         "--proxy", "`"<proxy>:8080`"",
         "--root", "`"C:\cygwin`""
     )
     WindowStyle = "Hidden"
     PassThru = $True
     Wait = $True
     RedirectStandardOutput = "$isl"
     RedirectStandardError = "$ise"
}
$proc = Start-Process @SetupOpts

Setup starts, but then does nothing. It does create the logs, but they 
do not contain anything. They stay empty. Anything missing from the options?

Calling the power shell script from an elevated prompt directly seems to 
work as expected. It bails out if it is not an elevated prompt. Calling 
it remotely it hangs and nothing happens. Any idea? Any hint?
-- 
Thomas


[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 2521 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 321 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-04-20 13:22 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-20 13:22 installing/updating silently Thomas Schweikle

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).