Meta tags:
description= You can configure the dotnet command-line interface (CLI) to publish NuGet packages to GitHub Packages and to use packages stored on GitHub Packages as dependencies in a .NET project.;
Headings (most frequently used words):
publishing, package, with, authenticating, github, help, the, nuget, in, this, to, packages, personal, access, token, using, working, registry, article, multiple, same, repository, installing, troubleshooting, further, reading, did, doc, you, us, make, these, docs, great, still, need, github_token, actions, as, your, api, key, config, file,
Text of the page (most frequently used words):
github (95), the (71), #packages (58), package (45), with (33), you (32), repository (29), #access (26), your (26), nuget (24), for (24), and (21), registry (21), token (21), project (20), see (17), personal (17), file (16), version (16), using (15), information (15), publish (14), more (13), dotnet (12), repositoryurl (11), use (11), can (11), enterprise (10), actions (9), classic (9), publishing (9), about (8), api (8), docs (8), this (8), csproj (8), octocatapp (8), com (8), propertygroup (8), packagedescription (8), company (8), authors (8), packageid (8), targetframework (8), outputtype (8), sdk (8), name (8), working (8), config (8), key (8), that (7), authenticate (7), workflow (7), github_token (7), https (7), owner (7), add (7), authenticating (7), server (7), install (6), command (6), octocat (6), microsoft (6), value (6), same (6), account (6), create (6), visibility (6), permissions (6), source (5), private (5), net (5), want (5), which (5), username (5), free (5), help (4), all (4), repositories (4), exe (4), netcoreapp3 (4), adds (4), replace (4), org (4), octo (4), connect (4), release (4), configuration (4), new (4), when (4), authentication (4), cli (4), pro (4), team (4), need (3), within (3), other (3), associated (3), push (3), set (3), restore (3), itemgroup (3), octokittenapp (3), include (3), from (3), installing (3), multiple (3), viewing (3), pack (3), organization (3), must (3), creating (3), line (3), packagesources (3), scopes (3), workflows (3), codespaces (3), accounts (3), container (3), search (3), english (3), contact (2), security (2), privacy (2), 2022 (2), support (2), learn (2), make (2), are (2), pull (2), these (2), policy (2), further (2), reading (2), cannot (2), based (2), different (2), instead (2), scope (2), read (2), nuspec (2), url (2), may (2), fail (2), not (2), troubleshooting (2), packagereference (2), configure (2), field (2), dependencies (2), specifying (2), documentation (2), cats (2), dogs (2), octodogapp (2), octodog (2), example (2), will (2), after (2), view (2), bin (2), nupkg (2), specified (2), number (2), user (2), owns (2), console (2), specify (2), already (2), published (2), control (2), choose (2), independently (2), packagesourcecredentials (2), pkg (2), index (2), json (2), clear (2), interface (2), password (2), ensuring (2), delete (2), available (2), legacy (2), per (2), plans (2), products (2), organizations (2), cloud (2), npm (2), web (2), 2021 (2), blog, training, developer, pricing, status, terms, inc, ask, community, still, how, contribute, contribution, open, something, wrong, unclear, submit, request, great, did, doc, deleting, restoring, than, where, running, generate, pass, secret, ensure, has, element, required, attributes, type, expected, dependency, similar, projects, fields, files, matches, specific, ends, increment, then, your_github_pat, don, have, pat, automatically, connected, linking, connecting, first, default, linked, dependent, change, configuring, stores, allows, associate, whether, inherit, granular, option, cleartextpassword, xml, encoding, utf, directory, under, client, appropriate, used, secrets, store, text, following, hardcoding, give, least, assign, depending, needs, related, internal, public, only, supports, owned, also, since, billed, higher, stored, article, 한국어, русский, français, deutsch, português, brasil, español, 日本語, 简体中文, versions, releases, codeql, electron, desktop, education, pages, building, communities, sponsors, discussions, graphql, rest, developers, copilot, issues, requests, code, site, billing, payments, administrators, profile, get, started, managing, migration, gradle, apache, maven, rubygems, docker, introduction, quickstart, skip, main, content, wayback, machine, http, archive, 20221219025018, timestamps, capture, success, 2023, jan, dec, nov, aug, 2026, 205, captures,
Text of the page (random words):
working with the nuget registry github docs 205 captures 06 may 2021 31 aug 2026 nov dec jan 19 2021 2022 2023 success fail about this capture timestamps the wayback machine http web archive org web 20221219025018 https docs github com en packages working with a github packages registry working with the nuget registry skip to main content github docs all products github packages quickstart learn github packages introduction about permissions access control visibility connect a repository publishing a package viewing packages installing a package delete restore a package working with a github packages registry container registry docker registry rubygems registry npm registry apache maven registry gradle registry nuget registry migration to container registry managing github packages with workflows publish install with actions example workflows packages actions github packages working with a github packages registry nuget registry free pro team english search github docs github docs github packages working with a github packages registry nuget registry github packages get started account and profile authentication repositories enterprise administrators billing and payments site policy organizations code security pull requests github issues github actions github copilot github codespaces github packages search on github developers rest api graphql api github cli github discussions github sponsors building communities github pages education github desktop github support electron codeql npm free pro team free pro team enterprise cloud enterprise server 3 7 enterprise server 3 6 enterprise server 3 5 enterprise server 3 4 enterprise server 3 3 github ae all enterprise server releases about versions english english 简体中文 日本語 español português do brasil deutsch français русский 한국어 search github docs working with the nuget registry in this article authenticating to github packages publishing a package publishing multiple packages to the same repository installing a package troubleshooting further reading you can configure the dotnet command line interface cli to publish nuget packages to github packages and to use packages stored on github packages as dependencies in a net project github packages is available with github free github pro github free for organizations github team github enterprise cloud github enterprise server 3 0 or higher and github ae github packages is not available for private repositories owned by accounts using legacy per repository plans also accounts using legacy per repository plans cannot access the container registry since these accounts are billed by repository for more information see github s products authenticating to github packages github packages only supports authentication using a personal access token classic for more information see creating a personal access token you need an access token to publish install and delete private internal and public packages you can use a personal access token classic to authenticate to github packages or the github api when you create a personal access token classic you can assign the token different scopes depending on your needs for more information about packages related scopes for a personal access token classic see about permissions for github packages to authenticate to a github packages registry within a github actions workflow you can use github_token to publish packages associated with the workflow repository a personal access token classic with at least packages read scope to install packages associated with other private repositories which github_token can t access you can choose to give access permissions to packages independently for github codespaces and github actions for more information see ensuring codespaces access to your package and ensuring workflow access to your package authenticating with github_token in github actions use the following command to authenticate to github packages in a github actions workflow using the github_token instead of hardcoding a personal access token in a nuget config file in the repository dotnet nuget add source username username password secrets github_token store password in clear text name github https nuget pkg github com owner index json for more information about github_token used in github actions workflows see authentication in a workflow authenticating with a personal access token you must use a personal access token classic with the appropriate scopes to publish and install packages in github packages for more information see about github packages to authenticate to github packages with the dotnet command line interface cli create a nuget config file in your project directory specifying github packages as a source under packagesources for the dotnet cli client you must replace username with the name of your personal account on github token with your personal access token classic owner with the name of the user or organization account that owns the package you want to install or to which you want to publish a package xml version 1 0 encoding utf 8 configuration packagesources clear add key github value https nuget pkg github com owner index json packagesources packagesourcecredentials github add key username value username add key cleartextpassword value token github packagesourcecredentials configuration publishing a package you can publish a package to github packages by authenticating with a nuget config file or by using the api key command line option with your github personal access token classic the nuget registry stores packages within your organization or personal account and allows you to associate packages with a repository you can choose whether to inherit permissions from a repository or set granular permissions independently of a repository when you first publish a package the default visibility is private when a package is linked to repository the package visibility is dependent on the repository s visibility to change the visibility or set access permissions see configuring a package s access control and visibility if you specify a repositoryurl in your nuget config file the published package will automatically be connected to the specified repository for more information see publishing a package using a nuget config file for information on linking an already published package to a repository see connecting a repository to a package publishing a package using a github personal access token as your api key if you don t already have a pat to use for your account on github com see creating a personal access token create a new project dotnet new console name octocatapp package the project dotnet pack configuration release publish the package using your personal access token as the api key dotnet nuget push bin release octocatapp 1 0 0 nupkg api key your_github_pat source github after you publish a package you can view the package on github for more information see viewing packages publishing a package using a nuget config file when publishing you need to use the same value for owner in your csproj file that you use in your nuget config authentication file specify or increment the version number in your csproj file then use the dotnet pack command to create a nuspec file for that version for more information on creating your package see create and publish a package in the microsoft documentation authenticate to github packages for more information see authenticating to github packages create a new project dotnet new console name octocatapp add your project s specific information to your project s file which ends in csproj you must replace owner with the name of the user or organization account that owns the repository to which you want to connect your package repository with the name of the repository to which you want to connect your package 1 0 0 with the version number of the package project sdk microsoft net sdk propertygroup outputtype exe outputtype targetframework netcoreapp3 0 targetframework packageid octocatapp packageid version 1 0 0 version authors octocat authors company github company packagedescription this package adds an octocat packagedescription repositoryurl https github com owner repository repositoryurl propertygroup project package the project dotnet pack configuration release publish the package using the key you specified in the nuget config file dotnet nuget push bin release octocatapp 1 0 0 nupkg source github after you publish a package you can view the package on github for more information see viewing packages publishing multiple packages to the same repository to connect multiple packages to the same repository you can include the same github repository url in the repositoryurl fields in all csproj project files github matches the repository based on that field for example the octodogapp and octocatapp projects will publish to the same repository project sdk microsoft net sdk propertygroup outputtype exe outputtype targetframework netcoreapp3 0 targetframework packageid octodogapp packageid version 1 0 0 version authors octodog authors company github company packagedescription this package adds an octodog packagedescription repositoryurl https github com octo org octo cats and dogs repositoryurl propertygroup project project sdk microsoft net sdk propertygroup outputtype exe outputtype targetframework netcoreapp3 0 targetframework packageid octocatapp packageid version 1 0 0 version authors octocat authors company github company packagedescription this package adds an octocat packagedescription repositoryurl https github com octo org octo cats and dogs repositoryurl propertygroup project installing a package using packages from github in your project is similar to using packages from nuget org add your package dependencies to your csproj file specifying the package name and version for more information on using a csproj file in your project see working with nuget packages in the microsoft documentation authenticate to github packages for more information see authenticating to github packages to use a package add itemgroup and configure the packagereference field in the csproj project file replace the octokittenapp value in include octokittenapp with your package dependency and replace the 12 0 2 value in version 12 0 2 with the version you want to use project sdk microsoft net sdk propertygroup outputtype exe outputtype targetframework netcoreapp3 0 targetframework packageid octocatapp packageid version 1 0 0 version authors octocat authors company github company packagedescription this package adds an octocat packagedescription repositoryurl https github com owner repository repositoryurl propertygroup itemgroup packagereference include octokittenapp version 12 0 2 itemgroup project install the packages with the restore command dotnet restore troubleshooting your nuget package may fail to push if the repositoryurl in csproj is not set to the expected repository if you re using a nuspec file ensure that it has a repository element with the required type and url attributes if you re using a github_token to authenticate to a github packages registry within a github actions workflow the token cannot access private repository based packages in a different repository other than where the workflow is running in to access packages associated with other repositories instead generate a personal access token classic with the read packages scope and pass this token in as a secret further reading deleting and restoring a package did this doc help you privacy policy help us make these docs great all github docs are open source see something that s wrong or unclear submit a pull request make a contribution or learn how to contribute still need help ask the github community contact support 2022 github inc terms privacy security status help contact github pricing developer api training blog about
|