Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit471cfff

Browse files
committed
feat: use --abbrev-ref to detect current branch
1 parent8d11ad3 commit471cfff

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

‎lib/var/BUILD_BRANCH.js‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,8 @@ const BUILD_BRANCH = () => {
1515

1616
if(!branch){
1717
try{
18-
branch=execSync('gitbranch 2>/dev/null')
18+
branch=execSync('gitrev-parse --abbrev-ref HEAD 2>/dev/null')
1919
.toString()
20-
.match(/\*\s*([^\s]+)\s/)[1]
2120
.trim();
2221
// eslint-disable-next-line no-empty
2322
}catch(error){}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp