Install and update pyRevit extension from a private repo

i have exactly the same issue , i tested with password, fine grained personal access token and personal access token classis, and nothing works for a private repo.

i then activated the github trial version of enterprise cloud , and make the repository internal, and create a fake github accoun and invited to my enterprise and tested again with the 3 methods (PW and 2 tokens) and it is not working, receiving the same error with status code : 401

can anyone guide me what i am doing wrong?

What and why it does not work:
The window for the extension management is kind of broken as Github does not accept username+password combinations anymore.
It should be redesigned both on the backend and frontend to take only tokens.

What works:
using the pyrevit cli (that comes installed with pyRevit), you can specify the token with the --token key

to install

pyrevit extend ui yourExtensionName https:\\github.com/user/repo.git --dest="C:/folder" --token=35684ger6384er63t5er635herzsh

to update

pyrevit extensions update yourExtensionName --token=35684ger6384er63t5er635herzsh

while using the cli, if you don’t know what to do with it you can always use: pyrevit **keyword** -h -h will bring the help for the keyword you want to use

when i try as you said above, i got this error, how i can solve this?
(knowing that i renamed my branch to “master” as indicated in the above replies)

Error: Could not load file or assembly 'LibGit2Sharp, Version=0.29.0.0, Culture=neutral, PublicKeyToken=7cb........................' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) Run with "--debug" option to see debug messages

and when i run with --debug, i got this:

C:\Users\XXX>pyrevit extend ui XXX https:XXX.git --dest="C:/XXX" --token=XXX --debug

--token = XXX
extend = True
<extension_name> = XXX
ui = True
<repo_url> = https://XXX.git
Debug: Checking for all: wiki
Debug: Missing: wiki
Debug: Checking for all: blog
Debug: Missing: blog
Debug: Checking for all: docs
Debug: Missing: docs
Debug: Checking for all: source
Debug: Missing: source
Debug: Checking for all: youtube
Debug: Missing: youtube
Debug: Checking for all: support
Debug: Missing: support
Debug: Checking for all: env
Debug: Missing: env
Debug: Checking for all: update
Debug: Missing: update
Debug: Checking for all: clone
Debug: Missing: clone
Debug: Checking for all: clones
Debug: Missing: clones
Debug: Checking for all: attach
Debug: Missing: attach
Debug: Checking for all: detach
Debug: Missing: detach
Debug: Checking for all: attached
Debug: Missing: attached
Debug: Checking for all: switch
Debug: Missing: switch
Debug: Checking for all: extend
Debug: Checking for any: ui,lib
Debug: Matching: ui
Error: Could not load file or assembly 'LibGit2Sharp, Version=0.29.0.0, Culture=neutral, PublicKeyToken=7cb.......XXX....' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) (System.IO.FileLoadException)
   at pyRevitLabs.PyRevit.PyRevitExtensions.InstallExtension(String extensionName, PyRevitExtensionTypes extensionType, String repoPath, String destPath, String branchName, GitInstallerCredentials credentials)
   at pyRevitCLI.PyRevitCLI.ProcessArguments()
   at pyRevitCLI.PyRevitCLI.Main(String[] args)```

This bug has been fixed in some of the latest PR.
try any of the wip installers in the past week or so here:

pyRevitCI · Workflow runs · eirannejad/pyRevit

wip installers instructions

note: you will need a github account to grab the installer

i reinstalled the latest version 4.8.15 instead of 4.8.14 and now it finally works through the CLI :smiley:
Thank you so much for your replies.

But my main goal is to have an easier solution for the users who are not familiar with these commands, which is just replacing the extensions.json file which i will give them that include my repo link inside,
then all they need to do is to go in pyRevit Extension Manager tool inside Revit, and choose the repo and enter username and token, but unfortunately this not working, i get this error do you have any idea?
sorry for asking a lot of questions.

ERROR [Extensions] Error installing package. | remote authentication required but no callback set

Traceback: File "C:\Users\XXX\AppData\Roaming\pyRevit-Master\extensions\pyRevitCore.extension\pyRevit.tab\pyRevit.panel\Extensions.smartbutton\script.py", line 405, in install_ext_pkg extpkgs.install(self.selected_pkg.ext_pkg,

The idea that the token used in the CLI command is working well, but when the same token is used in the pyRevit Extension Manager tool inside Revit, it is not working for authentication issue.
i do not know if it is a token issue or something else maybe.

I will lock this topic @aymansaleh
This is a long enough thread. Please create a new post for your specific query and we will entry to reply.