DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR SHELL
can we store the name of the current branch in a variable in bash
branch_name=$(git branch | sed -n -e 's/^* (.*)/1/p')
PREVIOUS
NEXT
Tagged:
#store
#current
#branch
#variable
#bash
ADD COMMENT
Topic
COMMENT
Name
2+3 =
Submit