Skip to content

Commit c5c77ea

Browse files
authored
Merge pull request Homebrew#241590 from Homebrew/qianwen-1.2.3
qianwen 1.2.3
2 parents 78b312a + 8959770 commit c5c77ea

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

Casks/q/qianwen.rb

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,22 @@
11
cask "qianwen" do
2-
version "1.2.2,2512042113"
3-
sha256 "ec4d592ec55283a3955547ebf1a65c9320a1a7421cca87a326928b75ce58f2e1"
2+
version "1.2.3,2512151438"
3+
sha256 "70569e8c828eb677c0a1bedc114c48d505d0cd6807137d480c3b40c0ba204784"
44

5-
url "https://qianwen-portal-cdn.tongyi.com/native/app/#{version.csv.first}/darwin/universal/qwenclient_setup_#{version.csv.first}.#{version.csv.second}.dmg"
5+
url "https://qianwen-portal-cdn.tongyi.com/native/app/#{version.csv.first}/darwin/universal/qwenclient_setup_#{version.csv.first}#{".#{version.csv.second}" if version.csv.second}.dmg",
6+
verified: "qianwen-portal-cdn.tongyi.com/native/app/"
67
name "qianwen"
78
name "千问"
89
desc "AI assistant and chatbot powered by Alibaba's Qwen model"
9-
homepage "https://www.tongyi.com/qianwen"
10+
homepage "https://www.qianwen.com/qianwen"
1011

1112
livecheck do
12-
url "https://www.tongyi.com/qianwen"
13-
regex(%r{"mac":"https://qianwen-portal-cdn\.tongyi\.com/native/app/([\d.]+)/darwin/universal/qwenclient_setup_[\d.]+\.(\d+)\.dmg"})
13+
url :homepage
14+
regex(%r{/v?(\d+(?:\.\d+)+)/darwin/universal/qwenclient[._-]setup[._-]\1(?:\.(\d+))?\.dmg}i)
1415
strategy :page_match do |page, regex|
1516
match = page.match(regex)
16-
"#{match[1]},#{match[2]}" if match
17+
next unless match
18+
19+
match[2].present? ? "#{match[1]},#{match[2]}" : match[1]
1720
end
1821
end
1922

0 commit comments

Comments
 (0)