Skip to content

Commit f2b66f4

Browse files
authored
Merge pull request #251299 from Homebrew/bump-huggingface-cli-1.0.0
huggingface-cli 1.0.0
2 parents aa99c00 + b54cf0b commit f2b66f4

File tree

1 file changed

+49
-47
lines changed

1 file changed

+49
-47
lines changed

Formula/h/huggingface-cli.rb

Lines changed: 49 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -3,16 +3,17 @@ class HuggingfaceCli < Formula
33

44
desc "Client library for huggingface.co hub"
55
homepage "https://huggingface.co/docs/huggingface_hub/guides/cli"
6-
url "https://files.pythonhosted.org/packages/98/63/4910c5fa9128fdadf6a9c5ac138e8b1b6cee4ca44bf7915bbfbce4e355ee/huggingface_hub-0.36.0.tar.gz"
7-
sha256 "47b3f0e2539c39bf5cde015d63b72ec49baff67b6931c3d97f3f84532e2b8d25"
6+
url "https://files.pythonhosted.org/packages/91/8d/91f5aa3ad3f4fa39e6758cc3f6aaeb971bd8b8e1f5b1d6a58074c9edb4bb/huggingface_hub-1.0.0.tar.gz"
7+
sha256 "0cf0c9e841817e1f8e46fc2e00fc242613db383b790a447bf1d6945b3a3fed62"
88
license "Apache-2.0"
9+
head "https://github.com/huggingface/huggingface_hub.git", branch: "main"
910

1011
bottle do
11-
sha256 cellar: :any, arm64_tahoe: "0741652210c26ee364735f173342b875fa4c29a3779c770efab89cd2b7e31840"
12-
sha256 cellar: :any, arm64_sequoia: "8f37d8e1af5ca365ccde89f6f0fdb8f4a259917e79e0681f616749b012974912"
13-
sha256 cellar: :any, arm64_sonoma: "042240642227558c69bf607920eebe2816f4df99858f43ccafe66273f0737681"
14-
sha256 cellar: :any, sonoma: "fd773702a810829715763be07dd5e8ae54be1a4ee75b58dab63b25422aad686a"
15-
sha256 cellar: :any_skip_relocation, x86_64_linux: "4fba2586f04f59ec9e1998d8274101fdc1f7a25c9b13c19e553b7b07d1b81a05"
12+
sha256 cellar: :any, arm64_tahoe: "87e2cb3e0a978bfb715d9fab4e009fde35e0d7550bf056212694f2c04b51a67a"
13+
sha256 cellar: :any, arm64_sequoia: "fe43d06f7030440cf4f9aa96e5e5d62cc1b64afea8eab667485be4f6acb80281"
14+
sha256 cellar: :any, arm64_sonoma: "a4d3a7db40661d241041ca55583218676d09a074e44ee74cd72b42713bb8e451"
15+
sha256 cellar: :any, sonoma: "1ac123a8df526e94943a92b1bee7a74e93d310043a88478c3c98fe104f4f7ae0"
16+
sha256 cellar: :any_skip_relocation, x86_64_linux: "1e4f4f96ad0979ca3749c98c63e900cb91745f52614a2871879761f3bbcfacb8"
1617
end
1718

1819
depends_on "pkgconf" => :build
@@ -30,9 +31,14 @@ class HuggingfaceCli < Formula
3031
pypi_packages package_name: "huggingface_hub[cli]",
3132
exclude_packages: "certifi"
3233

33-
resource "charset-normalizer" do
34-
url "https://files.pythonhosted.org/packages/13/69/33ddede1939fdd074bce5434295f38fae7136463422fe4fd3e0e89b98062/charset_normalizer-3.4.4.tar.gz"
35-
sha256 "94537985111c35f28720e43603b8e7b43a6ecfb2ce1d3058bbe955b73404e21a"
34+
resource "anyio" do
35+
url "https://files.pythonhosted.org/packages/c6/78/7d432127c41b50bccba979505f272c16cbcadcc33645d5fa3a738110ae75/anyio-4.11.0.tar.gz"
36+
sha256 "82a8d0b81e318cc5ce71a5f1f8b5c4e63619620b63141ef8c995fa0db95a57c4"
37+
end
38+
39+
resource "click" do
40+
url "https://files.pythonhosted.org/packages/46/61/de6cd827efad202d7057d93e0fed9294b96952e188f7384832791c7b2254/click-8.3.0.tar.gz"
41+
sha256 "e7b8232224eba16f4ebe410c25ced9f7875cb5f3263ffc93cc3e8da705e229c4"
3642
end
3743

3844
resource "filelock" do
@@ -45,78 +51,74 @@ class HuggingfaceCli < Formula
4551
sha256 "19fd429483d25d28b65ec68f9f4adc16c17ea2c7c7bf54ec61360d478fb19c19"
4652
end
4753

54+
resource "h11" do
55+
url "https://files.pythonhosted.org/packages/01/ee/02a2c011bdab74c6fb3c75474d40b3052059d95df7e73351460c8588d963/h11-0.16.0.tar.gz"
56+
sha256 "4e35b956cf45792e4caa5885e69fba00bdbc6ffafbfa020300e549b208ee5ff1"
57+
end
58+
4859
resource "hf-xet" do
49-
url "https://files.pythonhosted.org/packages/74/31/feeddfce1748c4a233ec1aa5b7396161c07ae1aa9b7bdbc9a72c3c7dd768/hf_xet-1.1.10.tar.gz"
50-
sha256 "408aef343800a2102374a883f283ff29068055c111f003ff840733d3b715bb97"
60+
url "https://files.pythonhosted.org/packages/5e/6e/0f11bacf08a67f7fb5ee09740f2ca54163863b07b70d579356e9222ce5d8/hf_xet-1.2.0.tar.gz"
61+
sha256 "a8c27070ca547293b6890c4bf389f713f80e8c478631432962bb7f4bc0bd7d7f"
62+
end
63+
64+
resource "httpcore" do
65+
url "https://files.pythonhosted.org/packages/06/94/82699a10bca87a5556c9c59b5963f2d039dbd239f25bc2a63907a05a14cb/httpcore-1.0.9.tar.gz"
66+
sha256 "6e34463af53fd2ab5d807f399a9b45ea31c3dfa2276f15a2c3f00afff6e176e8"
67+
end
68+
69+
resource "httpx" do
70+
url "https://files.pythonhosted.org/packages/b1/df/48c586a5fe32a0f01324ee087459e112ebb7224f646c0b5023f5e79e9956/httpx-0.28.1.tar.gz"
71+
sha256 "75e98c5f16b0f35b567856f597f06ff2270a374470a5c2392242528e3e3e42fc"
5172
end
5273

5374
resource "idna" do
5475
url "https://files.pythonhosted.org/packages/6f/6d/0703ccc57f3a7233505399edb88de3cbd678da106337b9fcde432b65ed60/idna-3.11.tar.gz"
5576
sha256 "795dafcc9c04ed0c1fb032c2aa73654d8e8c5023a7df64a53f39190ada629902"
5677
end
5778

58-
resource "inquirerpy" do
59-
url "https://files.pythonhosted.org/packages/64/73/7570847b9da026e07053da3bbe2ac7ea6cde6bb2cbd3c7a5a950fa0ae40b/InquirerPy-0.3.4.tar.gz"
60-
sha256 "89d2ada0111f337483cb41ae31073108b2ec1e618a49d7110b0d7ade89fc197e"
61-
end
62-
6379
resource "packaging" do
6480
url "https://files.pythonhosted.org/packages/a1/d4/1fc4078c65507b51b96ca8f8c3ba19e6a61c8253c72794544580a7b6c24d/packaging-25.0.tar.gz"
6581
sha256 "d443872c98d677bf60f6a1f2f8c1cb748e8fe762d2bf9d3148b5599295b0fc4f"
6682
end
6783

68-
resource "pfzy" do
69-
url "https://files.pythonhosted.org/packages/d9/5a/32b50c077c86bfccc7bed4881c5a2b823518f5450a30e639db5d3711952e/pfzy-0.3.4.tar.gz"
70-
sha256 "717ea765dd10b63618e7298b2d98efd819e0b30cd5905c9707223dceeb94b3f1"
71-
end
72-
73-
resource "prompt-toolkit" do
74-
url "https://files.pythonhosted.org/packages/a1/96/06e01a7b38dce6fe1db213e061a4602dd6032a8a97ef6c1a862537732421/prompt_toolkit-3.0.52.tar.gz"
75-
sha256 "28cde192929c8e7321de85de1ddbe736f1375148b02f2e17edd840042b1be855"
76-
end
77-
7884
resource "pyyaml" do
7985
url "https://files.pythonhosted.org/packages/05/8e/961c0007c59b8dd7729d542c61a4d537767a59645b82a0b521206e1e25c2/pyyaml-6.0.3.tar.gz"
8086
sha256 "d76623373421df22fb4cf8817020cbb7ef15c725b9d5e45f17e189bfc384190f"
8187
end
8288

83-
resource "requests" do
84-
url "https://files.pythonhosted.org/packages/c9/74/b3ff8e6c8446842c3f5c837e9c3dfcfe2018ea6ecef224c710c85ef728f4/requests-2.32.5.tar.gz"
85-
sha256 "dbba0bac56e100853db0ea71b82b4dfd5fe2bf6d3754a8893c3af500cec7d7cf"
89+
resource "shellingham" do
90+
url "https://files.pythonhosted.org/packages/58/15/8b3609fd3830ef7b27b655beb4b4e9c62313a4e8da8c676e142cc210d58e/shellingham-1.5.4.tar.gz"
91+
sha256 "8dbca0739d487e5bd35ab3ca4b36e11c4078f3a234bfce294b0a0291363404de"
92+
end
93+
94+
resource "sniffio" do
95+
url "https://files.pythonhosted.org/packages/a2/87/a6771e1546d97e7e041b6ae58d80074f81b7d5121207425c964ddf5cfdbd/sniffio-1.3.1.tar.gz"
96+
sha256 "f4324edc670a0f49750a81b895f35c3adb843cca46f0530f79fc1babb23789dc"
8697
end
8798

8899
resource "tqdm" do
89100
url "https://files.pythonhosted.org/packages/a8/4b/29b4ef32e036bb34e4ab51796dd745cdba7ed47ad142a9f4a1eb8e0c744d/tqdm-4.67.1.tar.gz"
90101
sha256 "f8aef9c52c08c13a65f30ea34f4e5aac3fd1a34959879d7e59e63027286627f2"
91102
end
92103

104+
resource "typer-slim" do
105+
url "https://files.pythonhosted.org/packages/8e/45/81b94a52caed434b94da65729c03ad0fb7665fab0f7db9ee54c94e541403/typer_slim-0.20.0.tar.gz"
106+
sha256 "9fc6607b3c6c20f5c33ea9590cbeb17848667c51feee27d9e314a579ab07d1a3"
107+
end
108+
93109
resource "typing-extensions" do
94110
url "https://files.pythonhosted.org/packages/72/94/1a15dd82efb362ac84269196e94cf00f187f7ed21c242792a923cdb1c61f/typing_extensions-4.15.0.tar.gz"
95111
sha256 "0cea48d173cc12fa28ecabc3b837ea3cf6f38c6d1136f85cbaaf598984861466"
96112
end
97113

98-
resource "urllib3" do
99-
url "https://files.pythonhosted.org/packages/15/22/9ee70a2574a4f4599c47dd506532914ce044817c7752a79b6a51286319bc/urllib3-2.5.0.tar.gz"
100-
sha256 "3fc47733c7e419d4bc3f6b3dc2b4f890bb743906a30d56ba4a5bfa4bbff92760"
101-
end
102-
103-
resource "wcwidth" do
104-
url "https://files.pythonhosted.org/packages/24/30/6b0809f4510673dc723187aeaf24c7f5459922d01e2f794277a3dfb90345/wcwidth-0.2.14.tar.gz"
105-
sha256 "4d478375d31bc5395a3c55c40ccdf3354688364cd61c4f6adacaa9215d0b3605"
106-
end
107-
108114
def install
109115
virtualenv_install_with_resources
110116
end
111117

112118
test do
113-
whoami_output = shell_output("#{bin}/huggingface-cli whoami")
114-
assert_match "Not logged in", whoami_output
115-
test_cache = testpath/"cache"
116-
test_cache.mkdir
117-
ENV["HUGGINGFACE_HUB_CACHE"] = test_cache.to_s
119+
ENV["HUGGINGFACE_HUB_CACHE"] = testpath
118120
ENV["NO_COLOR"] = "1"
119-
scan_output = shell_output("#{bin}/huggingface-cli scan-cache")
120-
assert_match "Done in 0.0s. Scanned 0 repo(s) for a total of 0.0.", scan_output
121+
assert_match "Not logged in", shell_output("#{bin}/hf auth whoami")
122+
assert_match "No cached repositories found.", shell_output("#{bin}/hf cache ls")
121123
end
122124
end

0 commit comments

Comments
 (0)