FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
sentry-javascript/scripts/get-commit-list.ts at develop · marbemac/sentry-javascript · GitHub
marbemac
/
sentry-javascript
Public
forked from
getsentry/sentry-javascript
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
sentry-javascript
/
scripts
/
get-commit-list.ts
Copy path
More file actions
More file actions
Latest commit
History
History
History
34 lines (26 loc) · 965 Bytes
Breadcrumbs
sentry-javascript
/
scripts
/
get-commit-list.ts
Copy path
File metadata and controls
34 lines (26 loc) · 965 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
import
{
execSync
}
from
'child_process'
;
function
run
(
)
:
void
{
const
commits
=
execSync
(
'git log --format="- %s"'
)
.
toString
(
)
.
split
(
'\n'
)
;
const
lastReleasePos
=
commits
.
findIndex
(
commit
=>
/
-
m
e
t
a
\(
c
h
a
n
g
e
l
o
g
\)
/
i
.
test
(
commit
)
)
;
const
newCommits
=
commits
.
splice
(
0
,
lastReleasePos
)
.
filter
(
commit
=>
{
// Filter out merge commits
if
(
/
M
e
r
g
e
p
u
l
l
r
e
q
u
e
s
t
/
.
test
(
commit
)
)
{
return
false
;
}
// Filter release branch merged
if
(
/
M
e
r
g
e
b
r
a
n
c
h
/
.
test
(
commit
)
)
{
return
false
;
}
// Filter release commit itself
if
(
/
r
e
l
e
a
s
e
:
/
.
test
(
commit
)
)
{
return
false
;
}
return
true
;
}
)
;
newCommits
.
sort
(
(
a
,
b
)
=>
a
.
localeCompare
(
b
)
)
;
const
issueUrl
=
'https://github.com/getsentry/sentry-javascript/pull/'
;
const
newCommitsWithLink
=
newCommits
.
map
(
commit
=>
commit
.
replace
(
/
#
(
\d
+
)
/
,
`[#$1](
${
issueUrl
}
$1)`
)
)
;
// eslint-disable-next-line no-console
console
.
log
(
newCommitsWithLink
.
join
(
'\n'
)
)
;
}
run
(
)
;
Back
|
FazBrowse Home
|
New Git URL