Create a Private NuGet Feed in Azure DevOps Pipelines

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hi everyone today i'm going to show you how to publish your private package third the reason why you need to publish on your private new back packets as some situation you need to do it like when you want to share your package or your dolls on between the project or between your company and you don't want to use the public public public nougat fit to do it you want to public your own using your own in your own internal company that when you going to need to use the nuget packet private uh there's some re it often happens especially when you working on the lego legacy system and says a lot of old dol and still in use but it's not really like you can find some somewhere else and you need to publish this and it not really [Music] work well with the new tool like visual studio there's different way to to to you to publish your new web package um there are a couple of ways like you can publish straight away from visual studio but today i'm going to show you how to publish your dol uh especially the audio the legacy one to your private repo in using the azure deck of artifacts let's get started so at first you head up to your agile portal and go to the artifact so here's a my artifact actually i got a package already created but you can create a new fit here by input your name let's say you're going to put like my private uh fit one and then click click create you're going to let's say yeah so you got the blind fit like this and then the next step is you're going to try to connect the face click connect to the face and choose visual studio here so that's the information here you need to note down like the name and the source of the package which you're going to use later on okay let's go to um step two step two you head up to download uh packet uh nougat packet explosive um that link i'm going to put in the description below you head up to the nougat package browser github or the better way get it from microsoft store so go to microsoft store um without link and get the new get packet applause entirely little program is very useful once you got that installed the install site is really easy you once you get that insole you come back to your argue that off and get the some information you're going to use later on go to the icon on the top right user setting and click person asset tokens and then you can create your new token uh let's say i'm going to create the token name nuget fit token and then select the cotton b5 and select the maximum time for it that means i select the next year 2022 um july and then give it full access when i click the create you're going to generate the token 4g you click the copy to clipboard to copy it and save it somewhere and here in order to use later so that's good you got the token so you got the token here you get fit and the next step is going to okay next step is going to create the package to prepare for public so if you go open the nougat packet manager something like that so you got the nuget packet manager and then you add the new packet uh right click on the right hand side athlete folder uh i'm using the dot net core for this sample so going to add the dot net file net netflix.0 as my sample for the netcode application [Music] but sometimes if you using your.net standard you can not next using.net framework you can do like this like dotnet five four one so it's showing like the minimum um version.net if 4.51 uh upgrade it can work from 4.51 up to 4.8 so if you want to have the the dll work for all your platform user put it load version.net here is that means for 0.51 you can do subscribe you can do this right like after a new folder and then he put the net for five one here it still work so especially with the old system you often using.net 4.1 rather than using the the net call so if and then do that drop your doll in here and change some information let me [Music] change the information process so let's say if i got and i turn is one for 0.3 and they then i can publish my package and the reason i pour our photo 1.003 because i already published some some nougat package on my artifact here so i got the version up to 1.002 so the next version going to 1.003 um okay so let's click save button and click save and then click publish so when you click publish you need to input your public url is a way where you find this one is the public url is when you go to private fit and then you connect to the feet and then choose visual studio you got the information here that sort is your job url using in public url here so either copy it copy that on to your notepad and then also copy the name of it because we're going to use it later so on your nougat packet explosion you put the url in here and you put your uh public key in here the path in here which you create and before i think the path is something like that you already copied and then paste it in in here and then click publish so and wait i think around 10 seconds yeah what a bit publishing package oh it take a bit of time really take a long time this one know what's wrong with my still publishing uh there's something wrong with it i don't know maybe some connection normally it takes around like a few seconds to public package but this one it takes a bit longer let me close it and try to do it again publish there's something wrong with my it not success because i already got 1.0.3 i mean i already sucked it's a public that fit before but somehow it doesn't showing yeah i got a succeed here it should have the success button um like you already succeed to publish a nougat package but anyway let's try to do another one like or anyway yeah let's move to the next next step because uh if that you already succeeded public the 1.0.3 try to to consume it so head up to your visual studio so if you go to visual studio and then before you can use it you need to add the fit into the video studio first go to option and then go to nuget packet manager package source um and then you add the new package shot like that with the information you you already save it before so let's say my private feed and then the link for it the link for it here and then click ok um yeah okay but i i already got this one so um i'm not going to to add a new one in so i just delete it because i got my private fit here with the information i put in click ok and go to project and look at package manager you got us the the screen like that bro and then you can see john's private feed appear in here so let's say if you go to your private fit and you can proceed the map router packet already public the latest one it was 0 1 0 0 3 0.3 here you can click install it and then it's going to install the package for you like you normally normally do with the another new web package so you can see here it installed my my router here that's a the message here using saying i should use a net framework 4.8 uh instead of framework the net core 5.0 because uh this application is done at call but i use that as a sample but in your application maybe you don't need framework you're not going to see that the arrow let me try to publish another one and then you could we can see how we can update the package that lighter way we do with the nougat packet manager so this time we're going to create a dot code 5.0 and then i drag my dol in again and then remember you need to keep your name consistent otherwise going to public another another one so one point zero zero point and click save and then click publish okay and wait again yeah this time if uh successfully quite quick you got the head up to your arju artifact to see what it looked like so go to private feeds so related 1.00.4 yeah you can see here 1.0.4 that's good you even can use a command in zones of this packet by copy that command and go to the packet manager console here and uh pits like command in and can run but i'll show you using the visual tool so it's easier so go to you'll get packet manager again it open up go to update and then yeah refresh so we can see the latest one on the current version 1.0.3 the the newer version we are publishing 1.0.4 and let's take it and click update we're going to uninstall our version and install the new version on yeah that done this time is using the dot net core so no arrow messages here but um basically this uh video is more useful when you work with the legacy system like.net 4.5 or 4.8 not a framework rather than the newer system line.net core because the network you got [Music] another different way to to do is as well so but with a legacy system this way very good uh using the nougat packet and uh explosive it's really good with uh work very well with the old system and i think that's all for today i think i showed you how to publish your private nuget packet to share between your organization in the different projects i hope you enjoy it and it can save you some time happy coding thank you for watching
Info
Channel: KS - Happy Coding!
Views: 532
Rating: undefined out of 5
Keywords: private nuget feed, azure, artifacts, how to share dlls between projects, nuget, c#, .net
Id: iYI0aQwBxHk
Channel Id: undefined
Length: 20min 11sec (1211 seconds)
Published: Sat Jul 10 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.