Save-PSResource & Install-PSResource do not include empty files & folders

オープン
#1,819 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
csharp, powershell
領域
tooling

調査の方向性

Save-PSResource と Install-PSResource を使用して fileshare リポジトリで問題を再現し、公開された .nupkg の内容をインストール済みモジュールと照合して確認します。空のファイルとフォルダーについて、インストールまたはデプロイの経路を追跡します。空のフォルダーとファイルがインストール後も保持され、Import-Module ContosoTools が内部パスの欠落を報告しなくなれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Area-Install Issue-Bug
Prerequisites
  • Write a descriptive title.
  • Make sure you are able to repro it on the latest released version
  • Search the existing issues.
Steps to reproduce

Tested against a fileshare based repository

Empty folders and empty files - and empty folders containing nothing but empty files - are not installed / deployed.
Manually unwrapping the .nupkg files proves they were correctly included in the publishing and only go AWOL on install/deployment.

If a module is then built on a template that also includes empty folders, where files within are dynamically included at import (if any), and published, it will generate an error in import, as it tries to enumerate a folder that does not exist.

Expected behavior
Install-Module ContosoTools -Repository local
Import-Module ContosoTools
#-> No errors
Actual behavior
Install-Module ContosoTools -Repository local
Import-Module ContosoTools
# Error: Get-ChildItem: Cannot find path '<documents>\PowerShell\Modules\ContosoTools\1.0.0\internal\'
Error details

Environment data
ModuleType Version    PreRelease Name                                ExportedCommands
---------- -------    ---------- ----                                ----------------
Binary     1.1.1                 Microsoft.PowerShell.PSResourceGet  {Compress-PSResource, Find-PSResource, Get-Install…


Name                           Value
----                           -----
PSVersion                      7.5.1
PSEdition                      Core
GitCommitId                    7.5.1
OS                             Microsoft Windows 10.0.26100
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0
Visuals

No response

主要言語
C#
スター
576
フォーク
114
平均マージ
23時間 17分
マージ済み PR(30日)
8

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

PowerShell/PSResourceGet のほかの issue

PowerShell/PSResourceGet の issue をすべて見る

似ている issue

C# の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。