Skip to content

Commit 1a33f7d

Browse files
docs(common): nuget config file info
1 parent 36cafbb commit 1a33f7d

File tree

1 file changed

+31
-1
lines changed

1 file changed

+31
-1
lines changed

installation/nuget.md

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ This article explains how to add the private Telerik NuGet feed to your system.
2020

2121
To add the Telerik private NuGet feed, follow the steps below:
2222

23-
1. Download the [latest NuGet executable](https://dist.nuget.org/win-x86-commandline/latest/nuget.exe).
23+
1. Download the [latest NuGet executable](https://dist.nuget.org/win-x86-commandline/latest/nuget.exe). If you cannot use the `exe` (for example on Mac or Linux), you can [use a nuget.config](#nuget-config-file) file.
2424
1. Open a Command Prompt and change the path to where the `nuget.exe` is downloaded.
2525
1. Execute the command from the example below.
2626

@@ -59,6 +59,36 @@ NuGet Sources Update -Name "telerik.com" -Source "https://nuget.telerik.com/nuge
5959
-StorePasswordInClearText
6060
```
6161

62+
### Nuget Config File
63+
64+
NuGet feeds and other settings can be stored in a `nuget.config` file. You can read more about it in the [Nuget Config File - Package Sources](https://docs.microsoft.com/en-us/nuget/reference/nuget-config-file#packagesources) article.
65+
66+
Make sure you are familiar with how such configurations work. The [Common NuGet Configurations](https://docs.microsoft.com/en-us/nuget/consume-packages/configuring-nuget-behavior#creating-a-new-config-file) article is a reference document you can use.
67+
68+
To use a `nuget.config` file for the Telerik feed, you need to:
69+
70+
1. Ensure you have the relevant config file. You can create a new one by via the [dotnet new command](https://docs.microsoft.com/en-us/dotnet/core/tools/dotnet-new) by calling `dotnet new nugetconfig`.
71+
72+
2. Add the Telerik feed to it, and make sure to use plain-text credentials, because the .NET Core tooling does not fully support encypted credentials. Here is an example of how your config file can look like:
73+
74+
**nuget.config**
75+
76+
<?xml version="1.0" encoding="utf-8"?>
77+
<configuration>
78+
<packageSources>
79+
<!--To inherit the global NuGet package sources remove the <clear/> line below -->
80+
<clear />
81+
<add key="nuget" value="https://api.nuget.org/v3/index.json" />
82+
<add key="telerik" value="https://nuget.telerik.com/nuget" />
83+
</packageSources>
84+
<packageSourceCredentials>
85+
<telerik>
86+
<add key="Username" value="your telerik account email" />
87+
<add key="ClearTextPassword" value="your plain text password" />
88+
</telerik>
89+
</packageSourceCredentials>
90+
</configuration>
91+
6292
## Next Steps
6393

6494
@[template](/_contentTemplates/common/get-started.md#after-install)

0 commit comments

Comments
 (0)