FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
browsercode/script/version.ts at main · code2labgit/browsercode · GitHub
code2labgit
/
browsercode
Public
forked from
browser-use/browsercode
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
browsercode
/
script
/
version.ts
Copy path
More file actions
More file actions
Latest commit
History
History
History
executable file
·
36 lines (30 loc) · 1.39 KB
Breadcrumbs
browsercode
/
script
/
version.ts
Copy path
File metadata and controls
executable file
·
36 lines (30 loc) · 1.39 KB
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
35
36
#!/usr/bin/env bun
import
{
Script
}
from
"@opencode-ai/script"
import
{
$
}
from
"bun"
const
output
=
[
`version=
${
Script
.
version
}
`
]
const
sha
=
process
.
env
.
GITHUB_SHA
??
(
await
$
`git rev-parse HEAD`
.
text
(
)
)
.
trim
(
)
if
(
!
Script
.
preview
)
{
await
$
`bun script/changelog.ts --to
${
sha
}
`
.
cwd
(
process
.
cwd
(
)
)
const
file
=
`
${
process
.
cwd
(
)
}
/UPCOMING_CHANGELOG.md`
const
body
=
await
Bun
.
file
(
file
)
.
text
(
)
.
catch
(
(
)
=>
"No notable changes"
)
const
dir
=
process
.
env
.
RUNNER_TEMP
??
"/tmp"
const
notesFile
=
`
${
dir
}
/opencode-release-notes.txt`
await
Bun
.
write
(
notesFile
,
body
)
await
$
`gh release create v
${
Script
.
version
}
-d --target
${
sha
}
--title "v
${
Script
.
version
}
" --notes-file
${
notesFile
}
`
const
release
=
await
$
`gh release view v
${
Script
.
version
}
--json tagName,databaseId`
.
json
(
)
output
.
push
(
`release=
${
release
.
databaseId
}
`
)
output
.
push
(
`tag=
${
release
.
tagName
}
`
)
}
else
if
(
Script
.
channel
===
"beta"
)
{
await
$
`gh release create v
${
Script
.
version
}
-d --title "v
${
Script
.
version
}
" --repo
${
process
.
env
.
GH_REPO
}
`
const
release
=
await
$
`gh release view v
${
Script
.
version
}
--json tagName,databaseId --repo
${
process
.
env
.
GH_REPO
}
`
.
json
(
)
output
.
push
(
`release=
${
release
.
databaseId
}
`
)
output
.
push
(
`tag=
${
release
.
tagName
}
`
)
}
output
.
push
(
`repo=
${
process
.
env
.
GH_REPO
}
`
)
if
(
process
.
env
.
GITHUB_OUTPUT
)
{
await
Bun
.
write
(
process
.
env
.
GITHUB_OUTPUT
,
output
.
join
(
"\n"
)
)
}
process
.
exit
(
0
)
Back
|
FazBrowse Home
|
New Git URL