Replies: 4 comments 1 reply
-
|
Thanks for openning discussion! I am noticing that it's matter of default branch's name, and like you said, we need that package.json file's path. But default branch name could be anything, other than |
Beta Was this translation helpful? Give feedback.
-
|
First of all, I was trying to fix it with minimal code modifications, so I wanted to make it work as much as possible without touching the code you guys have already put together! Please know this! I fixed access to the main, master, and custom branch paths, whether organized or not, but when I tested with other custom branch paths a while back, there were a few custom branch paths that didn't work. It worked for So I tried something new: look at the It would be best to get the default branch information and work around it, but if that's not possible, how about this approach? |
Beta Was this translation helpful? Give feedback.
-
|
That would be good approach, but can we get default branch with But putting my comment aside, this is quite good approach, so I think we need @userJu 's opinion with using |
Beta Was this translation helpful? Give feedback.
-
|
I was trying to use the github API, I thought HEAD pointed to the branch you most recently committed to! If HEAD always points to the default branch, regardless of the recent commit history, I think your method is BEST! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
In this discussion, I want to propose a new approach.
I have tested some GitHub repository links and found that I couldn't access some of the repository links. (Whether the link is a public repository or an Organization repository)
The issues are as follows:
For public repository links:
main, we can get the package.json.masterbranch.For repository links belonging to an organization:
main, we can get the package.json.masterbranch.Regardless of whether the default branch is
mainormaster, we need to access the repository and get the package.json file.Beta Was this translation helpful? Give feedback.
All reactions