Skip to content
This repository has been archived by the owner on Jun 28, 2024. It is now read-only.

Commit

Permalink
Better pre-release check (#211)
Browse files Browse the repository at this point in the history
Co-authored-by: Seray Uzgur <[email protected]>
  • Loading branch information
BarbossHack and serayuzgur authored Sep 18, 2023
1 parent 471eb17 commit 56e7606
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -1099,7 +1099,7 @@
"format": "esm"
},
"src/core/fetcher.ts": {
"bytes": 3490,
"bytes": 3590,
"imports": [
{
"path": "./Item",
Expand Down Expand Up @@ -1471,7 +1471,7 @@
"bytesInOutput": 1506
},
"src/core/fetcher.ts": {
"bytesInOutput": 1104
"bytesInOutput": 1183
},
"src/providers/autoCompletion.ts": {
"bytesInOutput": 932
Expand Down
1 change: 1 addition & 0 deletions sample/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ inkwell="0.1.0-llvm8sample"
crossbeam-utils="0.8.5"
Inflector = "0.11.4"
block-modes = "0.8.1" # crates: disable-check
jpegxl-sys = "0.8.2"
tracing = "=0.1.37"

[dependencies.clap]
Expand Down
2 changes: 1 addition & 1 deletion src/core/fetcher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ function transformServerResponse(versions: (name: string, indexServerURL: string
return function (item: Item): Promise<Dependency> {
return versions(item.key, indexServerURL).then((crate: any) => {
const versions = crate.versions.reduce((result: any[], item: string) => {
const isPreRelease = !shouldListPreRels && item.indexOf("-") !== -1;
const isPreRelease = !shouldListPreRels && (item.indexOf("-alpha") !== -1 || item.indexOf("-beta") !== -1 || item.indexOf("-rc") !== -1 || item.indexOf("-pre") !== -1);
if (!isPreRelease)
result.push(item);
return result;
Expand Down

0 comments on commit 56e7606

Please sign in to comment.