Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

change git default branch

git config --global init.defaultBranch <defaultBranchName>
Comment

change default branch github

On GitHub, navigate to the main page of the repository.
Under your repository name, click Settings.
In the left menu, click Branches.
Under "Default branch", to the right of the default branch name, click .
Use the drop-down, then click a branch name.
Click Update.
Comment

change default branch github

git branch -m master main

git push -u origin main

git symbolic-ref refs/remotes/origin/HEAD refs/remotes/origin/main

# change default branch on GitHub

git push origin --delete master
Comment

how to change my default branch in git

'settings' >> 'Code and Automation' >> 'Branches' >> 'Default Branch'

On GitHub.com, navigate to the main page of the repository.
Under your repository name, click "Settings".
In the "Code and automation" section of the sidebar, click "Branches".
Under "Default branch", to the right of the default branch name, click.
Use the drop-down, then select a branch name.

source: 'https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/managing-branches-in-your-repository/changing-the-default-branch#changing-the-default-branch'
Comment

Change default branch on git

git branch -m deploy prod
git fetch origin
git branch -u origin/prod prod
git remote set-head origin -a
Comment

change default branch of repo github desktop

// changing default branch of githubDesktop
git remote set-head origin -a
Comment

PREVIOUS NEXT
Code Example
Shell :: install tar files on linux 
Shell :: conda install python image library 
Shell :: powershell array pipe foreach 
Shell :: ubuntu list of users 
Shell :: bash data types 
Shell :: silent install google chrome 
Shell :: add credentials git linux 
Shell :: how to push local code to gitlab 
Shell :: install aws cli version 2 on mac 
Shell :: update metasploit 
Shell :: docker compose up only one service 
Shell :: replace delimiter for enter command 
Shell :: powershell for each loop 
Shell :: apt install jack audio 
Shell :: git log show only merge commits 
Shell :: git pull from commit 
Shell :: install packages rstudio 
Shell :: find linux 
Shell :: mac generate ssh private key 
Shell :: ubuntu take screenshot with cursor 
Shell :: how to install kivy.app 
Shell :: chown: invalid user: ‘www-data:www-data’ 
Shell :: ubuntu delete contents of folder 
Shell :: merging branches in git 
Shell :: git revert pr merge 
Shell :: search package linux 
Shell :: jq starts with 
Shell :: android sdk ubuntu 
Shell :: git stash example 
Shell :: how to clone a specific branch from github that you are not working 
ADD CONTENT
Topic
Content
Source link
Name
3+6 =