Skip to content

Commit

Permalink
updated scripts - not important.
Browse files Browse the repository at this point in the history
  • Loading branch information
waldo1001 committed Oct 30, 2017
1 parent 0d38b42 commit 1d045c9
Show file tree
Hide file tree
Showing 10 changed files with 131 additions and 6 deletions.
@@ -1,7 +1,7 @@
$ZipFIle = "D:\Installs\Dynamics.100.NA.2087283.DVD.zip"
$TmpLocation = 'D:\Temp2'
$ISOName = 'NAV_10_RTM_NA'
$IsoFileName = 'D:\Installs' + "\$ISOName.iso"
$ZipFIle = "C:\_Downloads\Dynamics.100.DE.2087085.DVD.zip"
$TmpLocation = 'C:\TmpIsoCreation\2017'
$ISOName = 'NAV_10_DE_RTM'
$IsoFileName = '\\waldonas2\public\Software\$Microsoft\Dynamics NAV\NAV 2017' + "\$ISOName.iso"


IF (Test-Path $TmpLocation){
Expand Down
17 changes: 17 additions & 0 deletions PSScripts/NAV Developer Tools/PrepareAzureVM.ps1
@@ -0,0 +1,17 @@
#Install Git
$GitExec = 'C:\DOWNLOAD\Git.exe'
$GitDownloadURL = 'https://github.com/git-for-windows/git/releases/download/v2.11.0.windows.3/Git-2.11.0.3-64-bit.exe'

Invoke-WebRequest $GitDownloadURL -OutFile $GitExec
Start-Process -FilePath $GitExec -ArgumentList "/VERYSILENT"


#CopyDropboxFolder
$ALSamplesOnDropbox = 'https://dl-web.dropbox.com/installer?authenticode_sign=True&build_no=18.4.32&juno=True&juno_use_program_files=True&plat=win&tag=eyJUQUdTIjoiREJQUkVBVVRIOjptc2llOjplSndOeThFS2drQVFBTkJma1RsSHpPek83RXpkbzhKQUNJeHVJcmpRR21td2R0RG8zX1AtM2hmYXpfUm9wdkVaQjlnWFVNMzNLcjNyVjMyODNsbzd4ZEtsODZGY3VNT0wwdExQVzJJVFZRMUJZRk5BamptbmNXaFN0MlpDSmxYeEVsZ0M3dGlSOTJhQ3F6WW5HSlNkaU5qdkR3OXpJQkV-QE1FVEEifQ&tag_token=AFwGRXyc0r87R2jXxKHV74_pLsMkSRfyOO1l6k8V--vw0A'
$DropboxExec = 'C:\DOWNLOAD\Dropbox.exe'
Invoke-WebRequest $ALSamplesOnDropbox -OutFile $DropboxExec
Start-Process -FilePath $DropboxExec


#Install waldo's modules
Find-Module | where author -eq 'waldo' | Install-Module
13 changes: 13 additions & 0 deletions PSScripts/NAV Extensions v2/ExecuteObjects.ps1
@@ -0,0 +1,13 @@
import-navmodules

find-module | where author -eq 'waldo' | Update-Module

$AppJson = Get-ObjectFromJSON '.\app.json'
$LaunchJson = Get-ObjectFromJSON '.\.vscode\launch.json'

Start-NAVApplicationObjectInWebClient `
-WebServerInstance $LaunchJson. `
-WebClientType Web `
-ObjectType Page `
-ObjectID 70050000

11 changes: 11 additions & 0 deletions PSScripts/NAV Extensions v2/Removeextension.ps1
@@ -0,0 +1,11 @@
import-module 'C:\Program Files\Microsoft Dynamics NAV\100\Service\NavAdminTool.ps1'

$AppJson = Get-ObjectFromJSON '.\app.json'

Get-NAVAppInfo -ServerInstance navision_main -Tenant default |
where Publisher -eq $AppJson.publisher |
Uninstall-NAVApp

Get-NAVAppInfo -ServerInstance navision_main |
where Publisher -like $AppJson.publisher |
Unpublish-NAVApp
2 changes: 1 addition & 1 deletion PSScripts/NAV Installation/2017/FullInstallNAV2017.ps1
@@ -1,4 +1,4 @@
$Name = 'NAV_10_15140_W1_CU03'
$Name = 'NAV_10_18197_W1_CU10'
$isofile = "C:\_Installs\$Name.iso"
$ConfigFile = join-path $PSScriptRoot 'FullInstallNAV2017_ReplaceDB.xml'
$Licensefile = "C:\Users\Administrator\Dropbox\Dynamics NAV\Licenses\5230132_003 and 004 IFACTO_NAV2017_BELGIUM_2016 10 24.flf"
Expand Down
2 changes: 1 addition & 1 deletion PSScripts/NAV Installation/2018/FullInstallNAV2018.ps1
@@ -1,4 +1,4 @@
$Name = 'NAV_11_CTP1'
$Name = 'NAV_11_CTP08'
$isofile = "C:\_Installs\$Name.iso"
$ConfigFile = join-path $PSScriptRoot 'FullInstallNAV2018.xml'
$Licensefile = "C:\Users\Administrator\Dropbox\Dynamics NAV\Licenses\2017 DEV License.flf"
Expand Down
25 changes: 25 additions & 0 deletions PSScripts/NAV Languages/ExportAllEncodings.ps1
@@ -0,0 +1,25 @@
$Object = 'TAB37.txt'
$Encoding = 'ASCII'
$Encoding = 'BigEndianUnicode'
$Encoding = 'Default'
$Encoding = 'OEM'
$Encoding = 'Unicode'
$Encoding = 'UTF32'
$Encoding = 'UTF7'
$Encoding = 'UTF8'
$Encoding = 'NoEncodingParam'

if (-not(Test-path "C:\_Workingfolder\TestLanguages\$Encoding\")){
New-Item "C:\_Workingfolder\TestLanguages\$Encoding\" -ItemType directory
}

Export-NAVApplicationObjectLanguage ` -Source (join-path 'C:\_Workingfolder\TestLanguages\Distri93\' $Object) ` -Destination "C:\_Workingfolder\TestLanguages\$Encoding\Distri93_Languages.txt" ` -LanguageId ENU,NLB,FRB ` -Force ` #-Encoding $Encoding

Export-NAVApplicationObjectLanguage ` -Source (join-path 'C:\_Workingfolder\TestLanguages\NAV_9_46290_BE\' $Object) ` -Destination "C:\_Workingfolder\TestLanguages\$Encoding\NAV_9_46290_BE_Languages.txt" ` -LanguageId ENU,NLB,FRB ` -Force ` #-Encoding $Encoding

Export-NAVApplicationObjectLanguage ` -Source (join-path 'C:\_Workingfolder\TestLanguages\NAV_10_RTM_BE\' $Object) ` -Destination "C:\_Workingfolder\TestLanguages\$Encoding\NAV_10_RTM_BE_Languages.txt" ` -LanguageId ENU,NLB,FRB ` -Force ` #-Encoding $Encoding

Export-NAVApplicationObjectLanguage ` -Source (join-path 'C:\_Workingfolder\TestLanguages\MergeResult\' $Object) ` -Destination "C:\_Workingfolder\TestLanguages\Encoding_$Encoding\MergeResult_Languages.txt" ` -LanguageId ENU,NLB,FRB ` -Force ` -Encoding $Encoding

#& 'C:\Program Files\Araxis\Araxis Merge\Merge.exe' "C:\_Workingfolder\TestLanguages\$Encoding\NAV_9_46290_BE_Languages.txt" "c:\_Workingfolder\TestLanguages\$Encoding\Distri93_Languages.txt" "C:\_Workingfolder\TestLanguages\$Encoding\NAV_10_RTM_BE_Languages.txt"

Expand Down
15 changes: 15 additions & 0 deletions PSScripts/NAV Upgrades/Conflicts/AnalyzeConflicts.ps1
@@ -0,0 +1,15 @@
$ConflictFiles = Get-ChildItem 'C:\Users\waldo\Dropbox\GitHub\iFacto.Products.Distri\Upgrade_Distri92_NAV2017CTP27\Conflicts'

$Conflicts = @()
foreach($ConflictFile in $ConflictFiles){
Write-host $ConflictFile.BaseName
$ObjectConflictHints = @()
$ObjectConflictHints = (Get-Content $ConflictFile.FullName | Where-Object {$_ -like '*ConflictHint*'}).TrimStart()

foreach ($ObjectConflictHint in $ObjectConflictHints){
$Conflict = New-Object PSObject
$Conflict | Add-Member -MemberType NoteProperty -Name 'Object' -Value $ConflictFile.BaseName
$Conflict | Add-Member -MemberType NoteProperty -Name 'ConflictHint' -Value $ObjectConflictHint
$Conflicts += $Conflict
}
}
39 changes: 39 additions & 0 deletions PSScripts/NAV Upgrades/Conflicts/RemoveAllButModifiedConflicts.ps1
@@ -0,0 +1,39 @@
$InterestingFiles = Get-ChildItem (join-path $MergeResult.Mergeresultfolder ConflictModified)

#ConflictFiles
$ConflictFiles = Get-ChildItem (join-path $MergeResult.Mergeresultfolder '*.CONFLICT')
foreach ($ConflictFile in $ConflictFiles){
if (-not($InterestingFiles.BaseName.Contains($ConflictFile.BaseName))){
Write-Host "Deleted conflictfile $($ConflictFile.Name)"
Remove-Item $ConflictFile.FullName
}
}

#OriginalFiles
$OriginalFiles = Get-ChildItem (join-path $MergeResult.Mergeresultfolder 'ConflictOriginal')
foreach ($OriginalFile in $OriginalFiles){
if (-not($InterestingFiles.BaseName.Contains($OriginalFile.BaseName))){
Write-Host "Deleted Original File $($OriginalFile.Name)"
Remove-Item $OriginalFile.FullName
}
}

#TargetFiles
$TargetFiles = Get-ChildItem (join-path $MergeResult.Mergeresultfolder 'ConflictTarget')
foreach ($TargetFile in $TargetFiles){
if (-not($InterestingFiles.BaseName.Contains($TargetFile.BaseName))){
Write-Host "Deleted Target File $($TargetFile.Name)"
Remove-Item $TargetFile.FullName
}
}

#ResultFiles
<#
$ResultFiles = Get-ChildItem $MergeResult.Mergeresultfolder
foreach ($ResultFile in $ResultFiles){
if (-not($InterestingFiles.BaseName.Contains($ResultFile.BaseName))){
Write-Host "Deleted Result File $($ResultFile.Name)"
Remove-Item $ResultFile.FullName
}
}
#>
5 changes: 5 additions & 0 deletions PSScripts/NAV Upgrades/UpgradeDatabase.ps1
Expand Up @@ -47,6 +47,11 @@ if (!$MergeResult) {$MergeResult = Import-Clixml -Path "$WorkingFolder\MergeResu

$FilteredMergeResultFolder = Copy-NAVChangedMergedResultFiles -MergeResultObjects $MergeResult.MergeResult


#break here, just because in the majority of times I don't need to execute any further
break


$FobFile =
New-NAVUpgradeFobFromMergedText `
-TargetServerInstance $TargetServerInstance `
Expand Down

0 comments on commit 1d045c9

Please sign in to comment.