Skip to content

Commit

Permalink
fix getIsMergedTargetBranch
Browse files Browse the repository at this point in the history
  • Loading branch information
saqqdy committed Jan 4, 2023
1 parent 3d2e759 commit 634cdff
Show file tree
Hide file tree
Showing 11 changed files with 11 additions and 13 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# 更新日志

## 2023.01.04 v4.0.2 更新日志
## 2023.01.04 v4.0.3 更新日志

1. 修复`getIsMergedTargetBranch`在 windows 下的兼容问题
2. os-local 降级
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@gitmars/monorepo",
"description": "这是一个git工作流工具",
"version": "4.0.2",
"version": "4.0.3",
"packageManager": "[email protected]",
"main": "index.js",
"files": [
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@gitmars/core",
"description": "gitmars核心程序",
"version": "4.0.2",
"version": "4.0.3",
"private": false,
"main": "./lib/index.js",
"module": "./lib/index.mjs",
Expand Down
1 change: 0 additions & 1 deletion packages/core/src/git/getAheadLogs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ function getAheadLogs(): string[] {
const { stdout } = spawnSync('git', [
'log',
`origin/${current}..${current}`,
'--',
'--pretty',
'format:%p'
])
Expand Down
1 change: 0 additions & 1 deletion packages/core/src/git/getBehindLogs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ function getBehindLogs(): string[] {
const { stdout } = spawnSync('git', [
'log',
`${current}..origin/${current}`,
'--',
'--pretty',
'format:%p'
])
Expand Down
6 changes: 3 additions & 3 deletions packages/core/src/git/getIsMergedTargetBranch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,11 @@ function getIsMergedTargetBranch(
}
const { stdout } = spawnSync('git', [
'log',
noMerges ? '--no-merges' : '',
'--format=%h',
branch,
`^${targetBranch}`,
'--',
noMerges ? '--no-merges' : '',
'--format=%h'
'--'
])
debug('getIsMergedTargetBranch', stdout)
return !stdout || !/[a-zA-Z0-9]+/.test(stdout)
Expand Down
2 changes: 1 addition & 1 deletion packages/docs/changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# 更新日志

## 2023.01.04 v4.0.2 更新日志
## 2023.01.04 v4.0.3 更新日志

1. 修复`getIsMergedTargetBranch`在 windows 下的兼容问题
2. os-local 降级
Expand Down
2 changes: 1 addition & 1 deletion packages/docs/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@gitmars/docs",
"description": "gitmars文档库",
"version": "4.0.2",
"version": "4.0.3",
"private": false,
"files": [
"dist",
Expand Down
2 changes: 1 addition & 1 deletion packages/gitmars/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "gitmars",
"description": "这是一个git工作流工具",
"version": "4.0.2",
"version": "4.0.3",
"private": false,
"bin": {
"gitm": "lib/gitm.mjs"
Expand Down
2 changes: 1 addition & 1 deletion packages/server/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@gitmars/server",
"description": "gitmars可视化界面服务端",
"version": "4.0.2",
"version": "4.0.3",
"private": false,
"type": "module",
"bin": {
Expand Down
2 changes: 1 addition & 1 deletion packages/ui/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@gitmars/ui",
"description": "gitmars可视化界面",
"version": "4.0.2",
"version": "4.0.3",
"private": false,
"bin": {
"gitm-ui": "./index.mjs"
Expand Down

1 comment on commit 634cdff

@vercel
Copy link

@vercel vercel bot commented on 634cdff Jan 4, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.