I asked Chris for a clarification off-list, he confirmed that he's
initializing the Git repository from within NetBeans, not on the command
line like I do.

I really appreciate that NetBeans shows me with blue and green and red how
files have changed since the last commit. It's something that IntelliJ IDEA
users also take for granted, but which might be a revelation for people
who've only used Eclipse.

But I don't trust any of these IDEs to issue Git commands. And in the case
of NetBeans, it sounds like Chris's issue is yet another case of programs
being slow to adopt the change from master branch to main branch, not
necessarily because of disagreement with the cause (though I'm sure there
are some of those) but simple inertia (which I think is the case with
NetBeans).

So what I would do as a temporary fix is find the project on the command
line,

C:\Users\AL> cd NetBeansProjects\MyProject

then

C:\Users\AL\NetBeansProjects\MyProject> git status

just to be sure, and then

C:\Users\AL\NetBeansProjects\MyProject> git checkout -b main

However, I have never actually used NetBeans for any project with more than
one Git branch (though I have used IntelliJ and Eclipse for such projects).
I believe my suggestion will put NetBeans on the branch you just checked -b
out to. But I have not tested this and don't know what issues you might run
into.

Al

On Sat, Sep 2, 2023 at 1:16 PM Christoforos Korifidis <
christofo...@e-logism.gr> wrote:

> Yes, I am using netbeans for initializing a git repository.
> My problem is that the repository is initialized at "master" branch while
> on github the repository is initialized with "main'' branch.
> I am trying to find where to change the initialization of netbeans from
> "master" to "main'' but I can not find it.
>
>
> με εκτίμηση
> Χριστόφορος Κορυφίδης
>
> κιν./mob. : +30 6932606269
> Διεύθυνση: Κώτσου 9, 34100 Χαλκίδα.
> Address   : Kotsou 9,  34100 Chalkida Greece.
>
>
>
> On Sat, 2 Sept 2023 at 19:42, Alonso Del Arte <alonso.dela...@gmail.com>
> wrote:
>
>> Are you using NetBeans to initialize the Git repository? I use Git itself
>> on the command line and manage the branches with the git branch command.
>>
>> Al
>>
>> On Sat, Sep 2, 2023, 9:01 AM Christoforos Korifidis <
>> christofo...@e-logism.gr> wrote:
>>
>>> Hello,
>>>
>>> When I initialize Github repository for a project it start with master
>>> branch instead of mail.
>>> Is there a way I can change this?
>>>
>>> I could not find this property in setting for Team.
>>> I am using Netbeans 18.
>>>
>>>
>>>
>>> με εκτίμηση
>>> Χριστόφορος Κορυφίδης
>>>
>>> κιν./mob. : +30 6932606269
>>> Διεύθυνση: Κώτσου 9, 34100 Χαλκίδα.
>>> Address   : Kotsou 9,  34100 Chalkida Greece.
>>>
>>>

Reply via email to