Share via


RegPkg Utility

The RegPkg.exe utility registers a VSPackage with Visual Studio by updating the system registry. Alternately, RegPkg can generate a registry script that can be used to update the registry. RegPkg can generate system registry scripts in several formats. You can incorporate these scripts in deployment projects such as .msi projects or Windows Installer XML Toolset files. For an example, see Tutorial: Simple VSPackage Deployment.

RegPkg runs as part of the build process so that you can build and run a VSPackage in the experimental hive. For more information on experimental builds, see Experimental Build.

RegPkg is typically located at <Visual Studio SDK installation path>\VisualStudioIntegration\Tools\Bin\RegPkg.exe. RegPkg follows this syntax:

RegPkg [/root:<root>] [/regfile:<regfile>] [/rgsfile:<rgsfile> [/rgm]] [/vrgfile:<vrgfile>] [/codebase | /assembly] [/unregister] AssemblyPath
  • /root:root
    Performs registration under the specified

    Visual Studio root.

  • /regfile:FileName
    Creates a .reg file rather than updating the registry. Cannot be used with /vrgfile or /rgsfile or /wixfile.

  • /rgsfile:FileName
    Creates a .rgs file rather than updating the registry. Cannot be used with /vrgfile or /regfile or /wixfile.

  • /vrgfile:FileName
    Creates a .vrg file rather than updating the registry. Cannot be used with /regfile or /rgsfile or /wixfile.

  • /rgm
    Creates a .rgm file in addition to the rgs file. Must be combined with /rgsfile.

  • /wixfile:FileName
    Creates a Windows Installer XML Toolset-compatible file rather than updating the registry. Cannot be used with /regfile or /rgsfile or /vrgfile.

  • /codebase
    Forces registration with CodeBase rather than Assembly.

  • /assembly
    Forces registration with Assembly rather than CodeBase.

  • /unregister
    Unregisters this package. Cannot be used

    with /regfile or /vrgfile or /rgsfile or /wixfile.

  • /RANU
    "Run as normal user". Writes the registration information inside a user-specific registry hive. This can be used to develop VSPackages with a user account that is not the machine administrator.

See Also

Concepts

Troubleshooting RegPkg Package Registration

Other Resources

Releasing a Visual Studio Integration Product