-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update yarn and pkg. Fixes Dashlane/dashlane-cli#215
- Loading branch information
Corentin Mors
authored
May 20, 2024
1 parent
4322eb8
commit 71e6b66
Showing
1 changed file
with
10 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,17 +3,21 @@ | |
class DashlaneCli < Formula | ||
desc "Command-line interface for Dashlane" | ||
homepage "https://dashlane.com" | ||
url "https://github.com/Dashlane/dashlane-cli/archive/refs/tags/v6.2416.0.tar.gz" | ||
sha256 "595026a52f8c8021078d0ab166fb50c920ef5fbe35cd539844c387621fe7c91c" | ||
url "https://github.com/Dashlane/dashlane-cli/archive/refs/tags/v6.2421.0.tar.gz" | ||
sha256 "e196f6bcad521bf92f64cdf5975d62aa9d9b8c2e20d1f1d4531ea1e7c6e7a531" | ||
license "Apache-2.0" | ||
|
||
livecheck do | ||
url :stable | ||
strategy :github_latest | ||
end | ||
|
||
option 'with-corepack', 'Use yarn from corepack instead of installing it' | ||
|
||
depends_on "node@18" => :build | ||
depends_on "yarn" => :build | ||
|
||
depends_on 'yarn' if !build.with?('corepack') | ||
depends_on 'corepack' if build.with?('corepack') | ||
|
||
on_macos do | ||
# macos 12+ only | ||
|
@@ -23,13 +27,13 @@ class DashlaneCli < Formula | |
def install | ||
Language::Node.setup_npm_environment | ||
platform = OS.linux? ? "linux" : "macos" | ||
system "yarn", "set", "version", "4.0.2" | ||
system "yarn", "set", "version", "4.2.2" | ||
system "yarn", "install", "--frozen-lockfile" | ||
system "yarn", "run", "build" | ||
system "yarn", "workspaces", "focus", "--production" | ||
system "yarn", "dlx", "@yao-pkg/[email protected].1", ".", | ||
system "yarn", "dlx", "@yao-pkg/[email protected].5", ".", | ||
"-t", "node18-#{platform}-#{Hardware::CPU.arch}", "-o", "bin/dcli", | ||
"--no-bytecode", "--public", "--public-packages", "tslib,thirty-two" | ||
"--no-bytecode", "--public", "--public-packages", "tslib,thirty-two,node-hkdf-sync,vows" | ||
bin.install "bin/dcli" | ||
end | ||
|
||
|