mirror of
https://github.com/denoland/deno.git
synced 2024-11-21 20:38:55 +00:00
build: Allow building 'rc' release from source (#25227)
We're not gonna use it, but this might help distribution tools like Homebrew to also release Deno 2.0 RC releases.
This commit is contained in:
parent
553bd7dec3
commit
044e7c4e63
@ -9,6 +9,8 @@ const TYPESCRIPT: &str = env!("TS_VERSION");
|
|||||||
const CARGO_PKG_VERSION: &str = env!("CARGO_PKG_VERSION");
|
const CARGO_PKG_VERSION: &str = env!("CARGO_PKG_VERSION");
|
||||||
// TODO(bartlomieju): ideally we could remove this const.
|
// TODO(bartlomieju): ideally we could remove this const.
|
||||||
const IS_CANARY: bool = option_env!("DENO_CANARY").is_some();
|
const IS_CANARY: bool = option_env!("DENO_CANARY").is_some();
|
||||||
|
// TODO(bartlomieju): this is temporary, to allow Homebrew to cut RC releases as well
|
||||||
|
const IS_RC: bool = option_env!("DENO_RC").is_some();
|
||||||
|
|
||||||
pub static DENO_VERSION_INFO: Lazy<DenoVersionInfo> = Lazy::new(|| {
|
pub static DENO_VERSION_INFO: Lazy<DenoVersionInfo> = Lazy::new(|| {
|
||||||
let release_channel = libsui::find_section("denover")
|
let release_channel = libsui::find_section("denover")
|
||||||
@ -17,6 +19,8 @@ pub static DENO_VERSION_INFO: Lazy<DenoVersionInfo> = Lazy::new(|| {
|
|||||||
.unwrap_or({
|
.unwrap_or({
|
||||||
if IS_CANARY {
|
if IS_CANARY {
|
||||||
ReleaseChannel::Canary
|
ReleaseChannel::Canary
|
||||||
|
} else if IS_RC {
|
||||||
|
ReleaseChannel::Rc
|
||||||
} else {
|
} else {
|
||||||
ReleaseChannel::Stable
|
ReleaseChannel::Stable
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user