Branches
Introduction
Branches in Fustak allow you to create and manage multiple development environments within your project. Each branch serves as an independent workspace, enabling you to work on different features or test changes without impacting the main environment.
Usage
To manage the branches you should use the branch command. This command has several subcommands that allow you to create, delete, and list branches, as well as retrieve the name, token, and URL of a branch.
fustak branch <COMMAND>
Commands:
- − create: Creates a new branch.
- − current: Retrieves the name of the current branch.
- − delete: Deletes a branch.
- − list: Lists all existing branches.
- − token: Retrieves the token associated with a branch.
- − url: Retrieves the URL associated with a branch.
- − help: Displays the command's help message or help for specific subcommands.
Create a Branch
Create a new branch with the specified name.
Usage:
fustak branch create <BRANCH_NAME>
Arguments:
- − <​BRANCH_NAME​>: The name of the branch to create.
Example:
fustak branch create new-branch
Delete a Branch
Delete an existing branch with the specified name.
Usage:
fustak branch delete <BRANCH_NAME>
Arguments:
- <​BRANCH_NAME​>: The name of the branch to delete.
Example:
fustak branch delete old-branch
List Branches
List all existing branches.
Usage:
fustak branch list
Current Branch Name
Retrieve the name of the current branch. The current branch name is stored in the .fustak/.token file.
Usage:
fustak branch current
These branch-related commands enable you to manage and navigate between different environments in your project, facilitating development and testing in separate contexts.