Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New option for Get-NAVCumulativeUpdateFile #28

Open
SorenKlemmensen opened this issue Feb 11, 2017 · 13 comments
Open

New option for Get-NAVCumulativeUpdateFile #28

SorenKlemmensen opened this issue Feb 11, 2017 · 13 comments

Comments

@SorenKlemmensen
Copy link
Contributor

Idea to add a CU option for this script so it takes a specific CU and not only the latest. If left blank just download the latest. Again just an idea that would make this much more useful for the majority of developers that are not on the latest version ...

@SorenKlemmensen
Copy link
Contributor Author

I have made this change and will be submitting a pull request shortly.

@waldo1001
Copy link
Owner

Looking forward to it .. because it's not an easy one ;-)

@KristofKlein
Copy link
Contributor

KristofKlein commented Feb 13, 2017

As an Idea:

Of course I love the Blog but with the latest changes by Microsoft to the way to Download the files it could make sense to change the "find the id to just use the ms url?

https://www.microsoft.com/$Language/search/result.aspx?q=

with q=NAV+$Version+Cumulative+$CUVersion+Download
$Language = en-us
$Version = 2017
$CUVersion = 03
--> https://www.microsoft.com/en-us/search/result.aspx?q=NAV+2017+Cumulative+03+Download

and parse the result from thatone into the Downloader?

@waldo1001
Copy link
Owner

That's most certainly a very good idea.
I'll look into it when I have the chance..

@SorenKlemmensen
Copy link
Contributor Author

that sounds very much like what I did. Let me fire up the other computer and send the one I got to you for review. I tested it on several versions and it worked. A few things I made sure of was that if you leave it out as a parameter it works the same as today secondly I do not add the 0 in front of the CU, but if you need CU 2 you put it to 2 and if you need 6 you write 6. The reason is MS doesn't consistently us 02 and 06 but in several cases just write 2 or 6.

@SorenKlemmensen
Copy link
Contributor Author

I just added the file here for now for your testing. I will do a pull request later, but just wanted you to have a look already.

Get-NAVCumulativeUpdateFile.zip

@SorenKlemmensen
Copy link
Contributor Author

Looking closer at your suggestion @KristofKlein I did it with just modifying the title filter that we use for the original filter. Let me know what you think.

@KristofKlein
Copy link
Contributor

Hi,
I think this is also what I suggested at one point directly on waldos blogs :) At that point the XMLNode search looked a bit different:
$blogurl = $feed.SelectNodes(“/rss/channel/item[./category=’NAV $version’ and ./category=’Cumulative Updates’ and ./title=’Cumulative Update $CUVersion for Microsoft Dynamics NAV $version has been released’]”).link | Select-Object -First 1
But does in the end do the same thing and also worked for me (i think it is even more precise as it "marks the spot" where the number is to be expected :P )

And as I called it: it is just an idea to use the MS Search instead of the msdn blog. As it should give you slighty fast what you are searching for as it already includes as the result the ID.
Apart from that: the MS Search a bit more up2date as the blog. So you most likly will find the next CU Update before it is announced on the blog. at least that's what I discovered with CU3 ;)

@waldo1001
Copy link
Owner

@KristofKlein yes you did .. you both are just too fast for me ;-). But I love it!

I'll leave this open to have a look at the MS Search in stead of the blog. The reason why I used the blog is simply because I inherited it from the previous way of working - where the "only" way to get to know a new CU update was that blog.. .

@waldo1001
Copy link
Owner

I tested and approved it, Soren:
#29

But .. @KristofKlein is very right: we need to turn it into searching in the Microsoft-site directly. The blog rss only contains a limited amount of articles .. . As a result, I'm not even able to find CU1 for 2017.. .

@rdebath
Copy link

rdebath commented Mar 6, 2017

Actually, I downloaded (nearly) all the old GB updates using the RSS feeds; the blog software they're using constructs feeds on the fly so something like https://blogs.msdn.microsoft.com/nav/2016/03/feed/ is a feed like page for just that month.

This doesn't apply to 2017CU1 though (eg: https://blogs.msdn.microsoft.com/nav/tag/nav-2017/feed/). Because somebody at microsoft has decided the users are too dumb to have access to it. (NB: I've only downloaded the GB version so I can't get any of the other languages either)

@KristofKlein
Copy link
Contributor

Since the Download Part of this Script is a bit shaky I worked a bit further on what follows. Since we deal with several Customers adressing several languages I always have to fetch 5 Version of the CU Updates.

I made now some code unzipping those, unzip the included zip File, create the PlatformHotfix Folder, parse the Changelog Files for all the Object IDs such that I can create a "FilterFile" [just ID|ID|ID per Object Type] for later user.

Finally: Iso the actual DVD Folder and remove all unneeded Folders and Zipfiles afterwards. The results end up in our IT Departments File Server.

To achive this I use quite some scripts from waldo, but also some home-made code :)

Once Again thx to waldo for this nice toolbox he made here. Makes my live easier and I'm looking forward to see more and hopefully I can contribute on it in the future :)

@waldo1001
Copy link
Owner

Very much welcome - the download is indeed shaky - I hate it :(. Depends too much on Microsoft people.
When I have time, I will try to indeed only depend on the download-site.
thanks for the nice words, and hopefully you'll contribute a lot! :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants