Usage instructions and get-it-all script

Usage instructions and get-it-all script

Postby hbuhrmester » 20.12.2015, 16:25

Much of the parameter processing for the script wsusoffline/sh/ is actually done by the sourced file There is even a helpful function printusage() in it, but there is no way, how this function could ever be called:

  • If the script is called without any parameters, it will start the interactive setup of parameters.
  • If the script is called with wrong parameters, it will only show short error messages like:

    Code: Select all
    system o2k16 does not exist.
    language glb does not exist.

If the function printusage() could actually be called, its output would look like:

Code: Select all
Usage: [system] [language] [parameter]

Supported systems:
w60 w60-x64 w61 w61-x64 w62 w62-x64 w63 w63-x64 w100 w100-x64 all-x86 all-x64 o2k7 o2k10 o2k13 ofc all-61 all-62 all-63 all-100

Supported languages:
enu deu nld esn fra ptg ptb ita rus plk ell csy dan nor sve fin jpn kor chs cht hun trk ara heb

/excludesp - do not download servicepacks
/dotnet    - download .NET framework
/msse      - download Microsoft Security Essentials files
/wddefs    - download Windows Defender definition files
/nocleanup - do not cleanup client directory
/wle       - download Essentials
/proxy     - define proxy server (/proxy http://[username:password@]<server>:<port>)
/makeiso   - create ISO image

Example: bash w61 deu /dotnet /excludesp

You can verify this yourself, if you create a small helper script "" with only two instructions in it:

Code: Select all

source ./

Then call it with:

Code: Select all
$ ./

Some remarks:

The language for Windows Vista and higher is supposed to be "glb", but this is not supported as a command line parameter. Instead, the function evaluateparams() in the file sets two language variables, dependent on the system:

Code: Select all
case $sys in
#    echo "Setting language to glb..."

So, there are two variables with language settings:

  • $Origlang as set on the command line
  • $lang as set by evaluateparams()

Of course, the case switch should include Windows 10.0 (w100*) as well.

The optional parameter /wddefs is treated internally as /msse for Windows 8. This is the same approach as in the Windows script DownloadUpdates.cmd.

Code: Select all
if grep -q /wddefs <<< $Cmdline ; then
    case $sys in

Again, the case switch should also include Windows 8.1 (w63*) and Windows 10.0 (w100*).

According to these rules, a simple script to download all updates for all systems, using German and English as default languages, could look like:

Code: Select all

for update in w60 w60-x64; do
    for language in deu enu; do
        ./ ${update} ${language} /dotnet /msse /wddefs /wle

for update in w61 w61-x64; do
    for language in deu enu; do
        ./ ${update} ${language}

for update in w62 w62-x64 w63 w63-x64 w100 w100-x64; do
    ./ ${update} deu

for update in o2k7 o2k10 o2k13; do
    for language in deu enu; do
        ./ ${update} ${language}


The optional downloads like /dotnet should only be added once, otherwise they will be processed repeatedly.

Using the original language could actually be useful to include localized installers for:

  • Internet Explorer 8 and higher for Windows Vista
  • Internet Explorer 9 and higher for Windows 7
  • .NET Frameworks
  • Microsoft Security Essentials
  • Windows Essentials 2012 (Windows Live Essentials)

But I don't know, if the script uses the original language this way.

For Windows 8, 8.1 and 10.0 the language parameter should not make any difference, but the script still won't accept "glb" as command line parameter.
Posts: 482
Joined: 11.10.2013, 20:59

Return to Linux

Who is online

Users browsing this forum: No registered users and 1 guest