The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My work

  • My badges

  • Twitter Updates

  • My Flickr Stream

    20140508-Delphi-2007--Project-Options--Cannot-Edit-Application-Title-HelpFile-Icon-Theming

    20140430-Fiddler-Filter-Actions-Button-Run-Filterset-now

    20140424-Windows-7-free-disk-space

    More Photos
  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,757 other followers

Simple download script to get all FREE Microsoft eBooks again! Including: Windows 10, Office 365, Office 2016, Power BI, Azure, Windows 8.1, Office 2013, SharePoint 2016, SharePoint 2013, Dynamics CRM, PowerShell, Exchange Server, System Center, Cloud, SQL Server and more! | Microsoft Director of Sales Excellence – Eric Ligman

Posted by jpluimers on 2016/12/21

I saw a lot of people mention the Eric Ligman, Microsoft Director of Sales Excellence Blog a while ago: FREE! That’s Right, I’m Giving Away MILLIONS of FREE Microsoft eBooks again! Including: Windows 10, Office 365, Office 2016, Power BI, Azure, Windows 8.1, Office 2013, SharePoint 2016, SharePoint 2013, Dynamics CRM, PowerShell, Exchange Server, System Center, Cloud, SQL Server and more! | Microsoft Director of Sales Excellence – Eric Ligman

Even though I make most of my income from the Microsoft World, my main machine is a Mac and I dislike browsing

So I wanted to download them all in one easy go so SpotLight could index them.

Luckily there is a file that has all the download URLs in it: http://ligman.me/29zpthb (it expands to http://www.mssmallbiz.com/ericligman/Key_Shorts/MSFTFreeEbooks.txt and is archived at http://web.archive.org/web/*/http://www.mssmallbiz.com/ericligman/Key_Shorts/MSFTFreeEbooks.txt).

The file is mentioned at How to “Download All” of the FREE eBooks and Resources in My FREE eBooks Giveaway | Microsoft Director of Sales Excellence – Eric Ligman.

It’s very easy to download from there using wget (on Windows get it from https://eternallybored.org/misc/wget/ – the x64 versions work fine).

Be sure to use a “recent” version as 1.12 and lower have no support for the --trust-server-names parameter which makes wget use filenames from the http 301 followed links:

--trust-server-names
     If this is set to on, on a redirect the last component of the redirection URL will be used as the local file name.  By default it is used the last component in the original URL.

This is the script:

wget -m -np --trust-server-names http://ligman.me/29zpthb
wget -m -np --trust-server-names --input-file http://www.mssmallbiz.com/ericligman/Key_Shorts/MSFTFreeEbooks.txt

You might think why not do just wget -m -np --trust-server-names --input-file http://ligman.me/29zpthb  in one go?

Simple answer: like all software, wget occasionally crashes somewhere in the middle of downloading the URLs embedded.

If you restart, then it sees the followed http://ligman.me/29zpthb file has already been downloaded and won’t re-scan its contents.

Bug? I’m not sure. But the two-liner just works.

–jeroen

PS: if you want a script with all the URLs, try these:

https://news.ycombinator.com/item?id=12071552

 

 

2 Responses to “Simple download script to get all FREE Microsoft eBooks again! Including: Windows 10, Office 365, Office 2016, Power BI, Azure, Windows 8.1, Office 2013, SharePoint 2016, SharePoint 2013, Dynamics CRM, PowerShell, Exchange Server, System Center, Cloud, SQL Server and more! | Microsoft Director of Sales Excellence – Eric Ligman”

  1. Gustavo Carreno said

    You explain your 2 liner quite well, but it intrigues me that the 1st line downloads the text file and then the 2nd line does not use the text file just downloaded by line 1.

    Should you not remove the “http://” from that line?

    Cheers,
    Gus

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: