Skip to content

Commit

Permalink
Fix vercel not being found on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
starscouts committed Aug 3, 2024
1 parent 553ecce commit 38d8d6b
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 13 deletions.
16 changes: 8 additions & 8 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "wishing-star"
version = "2.2.1"
version = "2.2.3"
edition = "2021"

[dependencies]
Expand Down
3 changes: 1 addition & 2 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,7 @@ impl SortedSteamWishlist {
) -> ListConfig {
for (_, (id, data)) in self.0 {
let first_sub = &data.subs[0];
let price_float = first_sub.price.parse::<f32>().unwrap_or(-100.0);
let price_int = (price_float * 10.0) as i32;
let price_int = first_sub.price.parse::<i32>().unwrap_or(-100);

let item = ItemConfig {
_id: Some(id),
Expand Down
2 changes: 1 addition & 1 deletion src/html/items/link.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ pub fn link(inner: Markup, list: &ListConfig, item: &ItemConfig, price: i32, id:
} {
(inner)
}
} else {
} @else {
div data-recommend=(list.recommend) data-list=(list.title)
id={ "item-" (list.title) "-" (id) } data-score="0"
data-price=(price)
Expand Down
2 changes: 1 addition & 1 deletion src/html/modules/faq.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ pub fn faq() -> Markup {
#"faq-4".accordion-collapse.collapse data-bs-parent="#faq" {
.accordion-body {
p {
r#"For items that are available on Steam, Amazon, Google Play, Apple stores and other
r#"For items that are available on Steam, Amazon, Google Play and other
compatible platforms, a gift card would be preferred to prevent issues with delivery.
Steam games must be purchased with gift cards due to regional restrictions. For items
that cannot be bought with a gift card, you will have to order them yourself and enter
Expand Down
8 changes: 8 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,14 @@ fn start() -> Result<(), WishingStarError> {

if config.vercel {
info!("Deploying to Vercel");

#[cfg(windows)]
Command::new("vercel.cmd")
.current_dir("./app")
.arg("--prod")
.status()?;

#[cfg(not(windows))]
Command::new("vercel")
.current_dir("./app")
.arg("--prod")
Expand Down

0 comments on commit 38d8d6b

Please sign in to comment.