Skip to content

Conversation

@TravisEz13
Copy link
Member

@TravisEz13 TravisEz13 commented Oct 17, 2017

disallow all other package types for symbols, as this package is no longer intended to be installed.

I run compliance tools on all binaries in this packages and we are getting more issues from the dependencies than from our product binaries.

…ting symbols zip. disallow all other package types for symbols
@TravisEz13
Copy link
Member Author

https://github.com/PowerShell/PowerShell/pull/5145/files?w=1 make this a lot easier to review.

elseif(-not $IncludeSymbols.IsPresent -and $Script:Options.CrossGen) {
$crossGenCorrect = $true
}
elseif ($IncludeSymbols.IsPresent) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So now it's OK to specify -IncludeSymbols while build with -Crossgen?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, the non-publish builds always keep the symbols, unaltered.

log 'setting IncludeSymbols'
$IncludeSymbols = $PSBoundParameters['IncludeSymbols']
}
log "$($IncludeSymbols.IsPresent):$IncludeSymbols"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When -IncludeSymbols is not specified, this log will print just a colon.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll remove... this was troubleshooting...

{
$tempPath = [System.IO.Path]::GetTempPath()

$tempFolder = Join-Path -Path $tempPath -ChildPath ([System.IO.Path]::GetRandomFileName())
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about replace these 2 lines with [System.IO.Path]::GetTempFileName()?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This API creates the file. I want a folder.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know, but you can use that name to create a folder. The two lines of script shown here are doing the same thing.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would have to delete the file before I can create a folder with the name.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see your point. Yeah, please ignore this comment.

Copy link
Member

@adityapatwardhan adityapatwardhan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With minor comment

}
if($IncludeSymbols.IsPresent)
{
Remove-Item -Path $Source -Recurse -Force
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe -ErrorAction SilentlyContinue?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added

@adityapatwardhan
Copy link
Member

@daxian-dbw can you update your review?

Copy link
Member

@daxian-dbw daxian-dbw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved with 2 comments.

{
$tempPath = [System.IO.Path]::GetTempPath()

$tempFolder = Join-Path -Path $tempPath -ChildPath ([System.IO.Path]::GetRandomFileName())
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know, but you can use that name to create a folder. The two lines of script shown here are doing the same thing.

}
if($IncludeSymbols.IsPresent)
{
Remove-Item -Path $Source -Recurse -Force -ErrorAction SilentlyContinue
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be great if you can put a comment here saying that "$Source is point to a temporary folder when -IncludeSymbols is present".

Copy link
Member

@daxian-dbw daxian-dbw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@adityapatwardhan adityapatwardhan merged commit 14af252 into PowerShell:master Oct 23, 2017
@TravisEz13 TravisEz13 deleted the fixCompliancePackage branch December 2, 2017 02:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants