mirror of
https://github.com/sst/opencode.git
synced 2025-12-23 10:11:41 +00:00
sync
This commit is contained in:
parent
9a28c67016
commit
a344c8b90c
1 changed files with 2 additions and 2 deletions
|
|
@ -7,12 +7,12 @@ import pkg from "../package.json"
|
|||
|
||||
const snapshot = process.env["OPENCODE_SNAPSHOT"] === "true"
|
||||
let version = process.env["OPENCODE_VERSION"]
|
||||
const tag = process.env["OPENCODE_TAG"] ?? (snapshot ? "snapshot" : "latest")
|
||||
if (!version && snapshot) {
|
||||
version = `0.0.0-${new Date().toISOString().slice(0, 16).replace(/[-:T]/g, "")}`
|
||||
version = `0.0.0-${tag}-${new Date().toISOString().slice(0, 16).replace(/[-:T]/g, "")}`
|
||||
process.env["OPENCODE_VERSION"] = version
|
||||
}
|
||||
if (!version) throw new Error("OPENCODE_VERSION is required")
|
||||
const tag = process.env["OPENCODE_TAG"] ?? (snapshot ? "snapshot" : "latest")
|
||||
|
||||
console.log(`publishing ${version}`)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue