joseluisq/gitnow

[Feature-Request]: Add default or main Command to Switch Back to Main/Master Branch

开放

#55 创建于 2024年9月22日

 (1 条评论) (0 个反应) (0 位负责人)Shell (27 个派生)github user discovery
enhancementhelp wanted

仓库指标

星标
 (491 个星标)
PR 合并指标
 (30 天内没有已合并 PR)

描述

Introduction

Adding a new command, default or main, would be beneficial to the gitnow tool that allows users to quickly switch back to the main or master branch of their repository. This command would streamline the workflow for users who frequently switch between feature branches and the main branch.

Suggested Implementation

The new command should:

  1. Detect the default branch name (either main or master).
  2. Switch to the detected default branch.

Example Usage

Command:

 default

or:

 main

Instead of:

git checkout main
# or
git checkout master

This feature would enhance the usability of gitnow by providing a quick and intuitive way to switch back to the main branch, aligning with common git workflows.

贡献者指南