Skip to content

Commit ec8af01

Browse files
authored
Users/vivasa/publishsymbol/manifest (#20709)
* Update readme * Update readme * Update task readme * Update readme changes * Updated readme * Update readme for generated files too * Adding build steps for publishsymbols * Update readme and build instructions * Update manifest for symboltask * Update localization resources and manifest validation * Update task.loc.json * update readme
1 parent 75ecf01 commit ec8af01

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+1900
-2941
lines changed

Tasks/PublishSymbolsV2/PublishSymbols.ts

+27-2
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ interface IClientToolOptions {
2626
requestName: string;
2727
sourcePathListFileName: string;
2828
symbolServiceUri: string;
29+
manifest: string;
2930
}
3031

3132
export async function run(clientToolFilePath: string): Promise<void> {
@@ -37,7 +38,16 @@ export async function run(clientToolFilePath: string): Promise<void> {
3738
let AsAccountName = tl.getVariable("ArtifactServices.Symbol.AccountName");
3839
let symbolServiceUri = "https://" + encodeURIComponent(AsAccountName) + ".artifacts.visualstudio.com"
3940
let personalAccessToken = tl.getVariable("ArtifactServices.Symbol.PAT");
40-
const connectedServiceName = tl.getInput("ConnectedServiceName", false);
41+
const connectedServiceName = tl.getInput("ConnectedServiceName", false);
42+
const manifest = tl.getInput("Manifest", false);
43+
if(manifest && !fileExists(manifest)) {
44+
throw new Error(tl.loc("ManifestFileNotFound", manifest));
45+
}
46+
else
47+
{
48+
tl.debug("Manifest file found at: " + manifest);
49+
}
50+
4151
tl.debug("connectedServiceName: " + connectedServiceName);
4252

4353
if(connectedServiceName){
@@ -111,7 +121,8 @@ export async function run(clientToolFilePath: string): Promise<void> {
111121
personalAccessToken,
112122
requestName,
113123
sourcePathListFileName,
114-
symbolServiceUri
124+
symbolServiceUri,
125+
manifest
115126
} as IClientToolOptions;
116127

117128
let toolRunnerOptions = clientToolRunner.getClientToolOptions();
@@ -143,6 +154,15 @@ export async function run(clientToolFilePath: string): Promise<void> {
143154
}
144155
}
145156

157+
function fileExists(filePath: string): boolean {
158+
try {
159+
fs.accessSync(filePath);
160+
return true;
161+
} catch (error) {
162+
return false;
163+
}
164+
}
165+
146166
function publishSymbolsUsingClientTool(
147167
sourcePath: string,
148168
options: IClientToolOptions,
@@ -155,6 +175,11 @@ function publishSymbolsUsingClientTool(
155175
"--directory", sourcePath
156176
);
157177

178+
if (options.manifest) {
179+
command.push("--manifest", options.manifest);
180+
tl.debug("Manifest: " + options.manifest);
181+
}
182+
158183
if (options.expirationInDays) {
159184
command.push("--expirationInDays", options.expirationInDays);
160185
}

Tasks/PublishSymbolsV2/README.md

+2
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ The task requires either Node v16 or Node v20 to run. The task does not support
2424

2525
* **SearchPattern**: The pattern used to discover the pdb files to publish.
2626

27+
* **Manifest**: The path to a file containing more symbol client keys to publish.
28+
2729
* **IndexSources**: Indicates whether to inject source server information into the PDB files. This option is only supported on Windows agents.
2830

2931
* **PublishSymbols**: Indicates whether to publish the symbol files.

Tasks/PublishSymbolsV2/Strings/resources.resjson/de-DE/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
"loc.input.help.SymbolsFolder": "Der Pfad zu dem Ordner, der nach Symboldateien durchsucht wird. Der Standardwert ist \"$(Build.SourcesDirectory)\". Geben Sie andernfalls einen Stammpfad an, z. B.: \"$(Build.BinariesDirectory)/MyProject\".",
99
"loc.input.label.SearchPattern": "Suchmuster",
1010
"loc.input.help.SearchPattern": "Das Muster, das zum Ermitteln der zu veröffentlichenden PDB-Dateien verwendet wird.",
11+
"loc.input.label.Manifest": "",
12+
"loc.input.help.Manifest": "",
1113
"loc.input.label.IndexSources": "Quellen indizieren",
1214
"loc.input.help.IndexSources": "Gibt an, ob Quellserverinformationen in die PDB-Dateien eingefügt werden sollen. Diese Option wird nur auf Windows-Agents unterstützt.",
1315
"loc.input.label.PublishSymbols": "Symbole veröffentlichen",
@@ -71,5 +73,6 @@
7173
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "Die Bibliothek \"dbghelp.dll\" wurde bereits aus einem unerwarteten Pfad geladen. Erwartet: \"{0}\". Tatsächlich: \"{0}\".",
7274
"loc.messages.UnsupportedSourceProvider0": "Nicht unterstützter Quellanbieter \"{0}\" für die Quellindizierung.",
7375
"loc.messages.Win32Error0FromMethod1": "Win32-Fehler \"{0}\" aus der Methode \"{1}\".",
74-
"loc.messages.NodeVersionSupport": "Node v{0} wird ab dem 31.08.2024 nicht mehr unterstützt. Aktualisieren Sie den Pipeline-Agent auf die neueste Version für Node 16 oder höher."
76+
"loc.messages.NodeVersionSupport": "Node v{0} wird ab dem 31.08.2024 nicht mehr unterstützt. Aktualisieren Sie den Pipeline-Agent auf die neueste Version für Node 16 oder höher.",
77+
"loc.messages.ManifestFileNotFound": ""
7578
}

Tasks/PublishSymbolsV2/Strings/resources.resjson/en-US/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010
"loc.input.help.SymbolsFolder": "The path to the folder that is searched for symbol files. The default is $(Build.SourcesDirectory). Otherwise specify a rooted path, for example: $(Build.BinariesDirectory)/MyProject",
1111
"loc.input.label.SearchPattern": "Search pattern",
1212
"loc.input.help.SearchPattern": "The pattern used to discover the pdb files to publish.",
13+
"loc.input.label.Manifest": "Manifest",
14+
"loc.input.help.Manifest": "The path to a file containing more symbol client keys to publish.",
1315
"loc.input.label.IndexSources": "Index sources",
1416
"loc.input.help.IndexSources": "Indicates whether to inject source server information into the PDB files. This option is only supported on Windows agents.",
1517
"loc.input.label.PublishSymbols": "Publish symbols",
@@ -73,5 +75,6 @@
7375
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "Library dbghelp.dll is already loaded from an unexpected path. Expected '{0}'. Actual '{0}'.",
7476
"loc.messages.UnsupportedSourceProvider0": "Unsupported source provider '{0}' for source indexing.",
7577
"loc.messages.Win32Error0FromMethod1": "Encountered Win32 error '{0}' from method '{1}'.",
76-
"loc.messages.NodeVersionSupport": "Node v{0} is no longer supported starting 08/31/2024. Please upgrade pipeline agent to latest version for Node 16 or later."
78+
"loc.messages.NodeVersionSupport": "Node v{0} is no longer supported starting 08/31/2024. Please upgrade pipeline agent to latest version for Node 16 or later.",
79+
"loc.messages.ManifestFileNotFound": "Manifest file not found at '{0}'."
7780
}

Tasks/PublishSymbolsV2/Strings/resources.resjson/es-ES/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
"loc.input.help.SymbolsFolder": "Ruta de acceso a la carpeta en la que se buscan los archivos de símbolos. El valor predeterminado es $(Build.SourcesDirectory). De lo contrario, especifique una ruta de acceso raíz, por ejemplo: $(Build.BinariesDirectory)/MyProject",
99
"loc.input.label.SearchPattern": "Patrón de búsqueda",
1010
"loc.input.help.SearchPattern": "Patrón usado para detectar los archivos pdb que se van a publicar.",
11+
"loc.input.label.Manifest": "",
12+
"loc.input.help.Manifest": "",
1113
"loc.input.label.IndexSources": "Indexar orígenes",
1214
"loc.input.help.IndexSources": "Indique si se debe insertar la información del servidor de origen en los archivos PDB. Esta opción solo se admite en agentes de Windows.",
1315
"loc.input.label.PublishSymbols": "Publicar símbolos",
@@ -71,5 +73,6 @@
7173
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "La biblioteca dbghelp.dll ya está cargada desde una ruta inesperada. Se esperaba '{0}'. Real '{0}'.",
7274
"loc.messages.UnsupportedSourceProvider0": "Proveedor de origen no admitido '{0}' para la indexación de origen.",
7375
"loc.messages.Win32Error0FromMethod1": "Error de Win32 '{0}' del método '{1}'.",
74-
"loc.messages.NodeVersionSupport": "Node v{0} ya no se admite a partir del 31/08/2024. Actualice el agente de canalización a la última versión de Node 16 o posterior."
76+
"loc.messages.NodeVersionSupport": "Node v{0} ya no se admite a partir del 31/08/2024. Actualice el agente de canalización a la última versión de Node 16 o posterior.",
77+
"loc.messages.ManifestFileNotFound": ""
7578
}

Tasks/PublishSymbolsV2/Strings/resources.resjson/fr-FR/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
"loc.input.help.SymbolsFolder": "Chemin du dossier de recherche des fichiers de symboles. La valeur par défaut est $(Build.SourcesDirectory). Sinon, spécifiez un chemin associé à une racine. Exemple : $(Build.BinariesDirectory)/MyProject",
99
"loc.input.label.SearchPattern": "Modèle de recherche",
1010
"loc.input.help.SearchPattern": "Modèle utilisé pour découvrir les fichiers pdb à publier.",
11+
"loc.input.label.Manifest": "",
12+
"loc.input.help.Manifest": "",
1113
"loc.input.label.IndexSources": "Indexer les sources",
1214
"loc.input.help.IndexSources": "Indique s’il faut injecter des informations sur le serveur source dans les fichiers PDB. Cette option est uniquement prise en charge sur les agents Windows.",
1315
"loc.input.label.PublishSymbols": "Publier les symboles",
@@ -71,5 +73,6 @@
7173
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "La bibliothèque dbghelp.dll est déjà chargée à partir d'un chemin inattendu. Le chemin attendu est '{0}'. Le chemin réel est '{0}'.",
7274
"loc.messages.UnsupportedSourceProvider0": "Fournisseur de source '{0}' non pris en charge pour l'indexation des sources.",
7375
"loc.messages.Win32Error0FromMethod1": "Erreur Win32 '{0}' rencontrée dans la méthode '{1}'.",
74-
"loc.messages.NodeVersionSupport": "Le nœud v{0} n’est plus pris en charge à compter du 31/08/2024. Veuillez mettre à niveau l’agent de pipeline vers la dernière version pour le nœud 16 ou version ultérieure."
76+
"loc.messages.NodeVersionSupport": "Le nœud v{0} n’est plus pris en charge à compter du 31/08/2024. Veuillez mettre à niveau l’agent de pipeline vers la dernière version pour le nœud 16 ou version ultérieure.",
77+
"loc.messages.ManifestFileNotFound": ""
7578
}

Tasks/PublishSymbolsV2/Strings/resources.resjson/it-IT/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
"loc.input.help.SymbolsFolder": "Percorso della cartella in cui vengono cercati i file di simboli. L'impostazione predefinita è $(Build.SourcesDirectory). In caso contrario, specificare un percorso completo, ad esempio: $(Build.BinariesDirectory)/MyProject",
99
"loc.input.label.SearchPattern": "Criteri di ricerca",
1010
"loc.input.help.SearchPattern": "Criterio usato per individuare i file PDB da pubblicare.",
11+
"loc.input.label.Manifest": "",
12+
"loc.input.help.Manifest": "",
1113
"loc.input.label.IndexSources": "Indicizza origini",
1214
"loc.input.help.IndexSources": "Indica se inserire informazioni sul server di origine nei file PDB. Questa opzione è supportata solo negli agenti Windows.",
1315
"loc.input.label.PublishSymbols": "Pubblica simboli",
@@ -71,5 +73,6 @@
7173
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "La libreria dbghelp.dll è già stata caricata da un percorso imprevisto. Percorso previsto: '{0}'. Percorso effettivo: '{0}'.",
7274
"loc.messages.UnsupportedSourceProvider0": "Il provider di origine '{0}' non è supportato per l'indicizzazione origine.",
7375
"loc.messages.Win32Error0FromMethod1": "È stato rilevato l'errore Win32 '{0}' restituito dal metodo '{1}'.",
74-
"loc.messages.NodeVersionSupport": "Il nodo v{0} non è più supportato a partire dal 31/08/2024. Aggiornare l'agente della pipeline alla versione più recente per Node 16 o versione successiva."
76+
"loc.messages.NodeVersionSupport": "Il nodo v{0} non è più supportato a partire dal 31/08/2024. Aggiornare l'agente della pipeline alla versione più recente per Node 16 o versione successiva.",
77+
"loc.messages.ManifestFileNotFound": ""
7578
}

Tasks/PublishSymbolsV2/Strings/resources.resjson/ja-JP/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
"loc.input.help.SymbolsFolder": "シンボル ファイルを検索するソース フォルダーへのパス。既定値は $(Build.SourcesDirectory) です。それ以外の場合は、$(Build.BinariesDirectory)/MyProject などのルート指定のパスを指定してください",
99
"loc.input.label.SearchPattern": "検索パターン",
1010
"loc.input.help.SearchPattern": "発行する PDB ファイルの検出に使用するパターン。",
11+
"loc.input.label.Manifest": "",
12+
"loc.input.help.Manifest": "",
1113
"loc.input.label.IndexSources": "ソースのインデックスを作成する",
1214
"loc.input.help.IndexSources": "PDB ファイルにソース サーバー情報を挿入するかどうかを示します。このオプションは Windows エージェントでのみサポートされています。",
1315
"loc.input.label.PublishSymbols": "シンボルを発行する",
@@ -71,5 +73,6 @@
7173
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "ライブラリ dbghelp.dll は予期しないパスから既に読み込まれています。必要なパス '{0}'。実際のパス '{0}'。",
7274
"loc.messages.UnsupportedSourceProvider0": "ソースのインデックス作成のサポートされていないソース プロバイダー '{0}'。",
7375
"loc.messages.Win32Error0FromMethod1": "メソッド '{1}' から Win32 エラー '{0}' が発生しました。",
74-
"loc.messages.NodeVersionSupport": "ノード v{0} は、2024 年 8 月 31 日からサポートされなくなりました。ノード 16 以降のパイプライン エージェントを最新バージョンにアップグレードしてください。"
76+
"loc.messages.NodeVersionSupport": "ノード v{0} は、2024 年 8 月 31 日からサポートされなくなりました。ノード 16 以降のパイプライン エージェントを最新バージョンにアップグレードしてください。",
77+
"loc.messages.ManifestFileNotFound": ""
7578
}

Tasks/PublishSymbolsV2/Strings/resources.resjson/ko-KR/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
"loc.input.help.SymbolsFolder": "기호 파일을 검색할 폴더의 경로입니다. 기본값은 $(Build.SourcesDirectory)입니다. 그렇지 않으면 루트 경로를 지정하세요(예: $(Build.BinariesDirectory)/MyProject).",
99
"loc.input.label.SearchPattern": "검색 패턴",
1010
"loc.input.help.SearchPattern": "게시할 pdb 파일을 검색하는 데 사용된 패턴입니다.",
11+
"loc.input.label.Manifest": "",
12+
"loc.input.help.Manifest": "",
1113
"loc.input.label.IndexSources": "소스 인덱싱",
1214
"loc.input.help.IndexSources": "원본 서버 정보를 PDB 파일에 주입할지 여부를 나타냅니다. 이 옵션은 Windows 에이전트에서만 지원됩니다.",
1315
"loc.input.label.PublishSymbols": "기호 게시",
@@ -71,5 +73,6 @@
7173
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "라이브러리 dbghelp.dll이 예기치 않은 경로에서 이미 로드되었습니다. 예상된 경로: '{0}'. 실제 경로: '{0}'.",
7274
"loc.messages.UnsupportedSourceProvider0": "소스 인덱싱에 대해 지원되지 않는 원본 공급자 '{0}'입니다.",
7375
"loc.messages.Win32Error0FromMethod1": "메서드 '{1}'에서 Win32 오류 '{0}'이(가) 발생했습니다.",
74-
"loc.messages.NodeVersionSupport": "Node v{0}은(는) 2024/08/31부터 더 이상 지원되지 않습니다. 파이프라인 에이전트를 노드 16 이상의 최신 버전으로 업그레이드하세요."
76+
"loc.messages.NodeVersionSupport": "Node v{0}은(는) 2024/08/31부터 더 이상 지원되지 않습니다. 파이프라인 에이전트를 노드 16 이상의 최신 버전으로 업그레이드하세요.",
77+
"loc.messages.ManifestFileNotFound": ""
7578
}

Tasks/PublishSymbolsV2/Strings/resources.resjson/ru-RU/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
"loc.input.help.SymbolsFolder": "Путь к папке, в которой ищутся файлы символов. По умолчанию используется папка $(Build.SourcesDirectory). В противном случае можно указать корневой путь, (например, $(Build.BinariesDirectory)/MyProject).",
99
"loc.input.label.SearchPattern": "Шаблон поиска",
1010
"loc.input.help.SearchPattern": "Шаблон, используемый для обнаружения файлов PDB для публикации.",
11+
"loc.input.label.Manifest": "",
12+
"loc.input.help.Manifest": "",
1113
"loc.input.label.IndexSources": "Индексация источников",
1214
"loc.input.help.IndexSources": "Указывает, следует ли внедрять сведения об исходном сервере в PDB-файлы. Этот параметр поддерживается только в агентах Windows.",
1315
"loc.input.label.PublishSymbols": "Публикация символов",
@@ -71,5 +73,6 @@
7173
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "Библиотека dbghelp.dll уже загружена из непредвиденного пути. Ожидается — \"{0}\". Фактический — \"{0}\".",
7274
"loc.messages.UnsupportedSourceProvider0": "Неподдерживаемый поставщик источника \"{0}\" для индексации источника.",
7375
"loc.messages.Win32Error0FromMethod1": "Произошла ошибка Win32 \"{0}\" из метода \"{1}\".",
74-
"loc.messages.NodeVersionSupport": "Начиная с 31.08.2024, Node v{0} больше не поддерживается. Обновите агент конвейера до последней версии для Node 16 или более поздней версии."
76+
"loc.messages.NodeVersionSupport": "Начиная с 31.08.2024, Node v{0} больше не поддерживается. Обновите агент конвейера до последней версии для Node 16 или более поздней версии.",
77+
"loc.messages.ManifestFileNotFound": ""
7578
}

Tasks/PublishSymbolsV2/Strings/resources.resjson/zh-CN/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
"loc.input.help.SymbolsFolder": "在其中搜索符号文件的文件夹的路径。默认为 $(Build.SourcesDirectory)。在其他情况下,指定根路径。例如: $(Build.BinariesDirectory)/MyProject",
99
"loc.input.label.SearchPattern": "搜索模式",
1010
"loc.input.help.SearchPattern": "用于发现要发布的 pdb 文件的模式。",
11+
"loc.input.label.Manifest": "",
12+
"loc.input.help.Manifest": "",
1113
"loc.input.label.IndexSources": "编制源索引",
1214
"loc.input.help.IndexSources": "指示是否将源服务器信息注入 PDB 文件。此选项仅在 Windows 代理上受支持。",
1315
"loc.input.label.PublishSymbols": "发布符号",
@@ -71,5 +73,6 @@
7173
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "已从异常路径加载库 dbghelp.dll。应为“{0}”。实际为“{0}”。",
7274
"loc.messages.UnsupportedSourceProvider0": "不受源索引编制支持的源提供程序“{0}”。",
7375
"loc.messages.Win32Error0FromMethod1": "在方法“{1}”中遇到 Win32 错误“{0}”。",
74-
"loc.messages.NodeVersionSupport": "从 2024 年 8 月 31 日起不再支持 Node v{0}。请将管道代理升级到最新版本以使用 Node 16 或更高版本。"
76+
"loc.messages.NodeVersionSupport": "从 2024 年 8 月 31 日起不再支持 Node v{0}。请将管道代理升级到最新版本以使用 Node 16 或更高版本。",
77+
"loc.messages.ManifestFileNotFound": ""
7578
}

Tasks/PublishSymbolsV2/Strings/resources.resjson/zh-TW/resources.resjson

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
"loc.input.help.SymbolsFolder": "搜尋符號檔案所在資料夾的路徑。預設值為 $(Build.SourcesDirectory)。否則請指定根路徑。例如: $(Build.BinariesDirectory)/MyProject",
99
"loc.input.label.SearchPattern": "搜尋模式",
1010
"loc.input.help.SearchPattern": "探索要發行之 pdb 檔案使用的模式。",
11+
"loc.input.label.Manifest": "",
12+
"loc.input.help.Manifest": "",
1113
"loc.input.label.IndexSources": "索引來源",
1214
"loc.input.help.IndexSources": "指出是否要將來源伺服器資訊插入 PDB 檔案。只有 Windows 代理程式支援此選項。",
1315
"loc.input.label.PublishSymbols": "發行符號",
@@ -71,5 +73,6 @@
7173
"loc.messages.UnexpectedDbghelpdllExpected0Actual1": "已從未預期的路徑載入程式庫 dbghelp.dll。預期為 '{0}'。實際為 '{0}'。",
7274
"loc.messages.UnsupportedSourceProvider0": "來源索引編製作業不支援來源提供者 '{0}'。",
7375
"loc.messages.Win32Error0FromMethod1": "方法 '{1}' 遇到 Win32 錯誤 '{0}'。",
74-
"loc.messages.NodeVersionSupport": "自 2024 年 8 月 31 日起將不再支援 Node v{0}。請將管線代理程式升級為 Node 16 以上的最新版本。"
76+
"loc.messages.NodeVersionSupport": "自 2024 年 8 月 31 日起將不再支援 Node v{0}。請將管線代理程式升級為 Node 16 以上的最新版本。",
77+
"loc.messages.ManifestFileNotFound": ""
7578
}

0 commit comments

Comments
 (0)