ghdl 0.4.8__py3-none-any.whl → 0.4.9__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
ghdl/__init__.py CHANGED
@@ -1,3 +1,3 @@
1
- __version__ = "0.4.8"
1
+ __version__ = "0.4.9"
2
2
 
3
3
  from ghdl.main import main, set_dry, set_single
ghdl/config.hy CHANGED
@@ -31,10 +31,9 @@
31
31
 
32
32
  (setv record.asset-filter (get info "asset_filter"))
33
33
 
34
- (if (not (in "name" info))
35
- (setv record.name
36
- (-> record.repo (.split "/") (get 1)))
37
- (setv record.name (get info "name")))
34
+ (if (in "name" info)
35
+ (setv record.name (get info "name"))
36
+ (setv record.name (-> record.repo (.split "/") (get 1))))
38
37
 
39
38
  (setv record.release-filter (.get info "release_filter" None))
40
39
 
ghdl/main.hy CHANGED
@@ -30,7 +30,7 @@
30
30
  (for [[asset url] url_data]
31
31
  (when (f asset)
32
32
  (return url))))
33
-
33
+
34
34
  (if (isinstance asset-filter str)
35
35
  (do
36
36
  (setv pattern (re.compile asset-filter re.IGNORECASE))
@@ -71,7 +71,7 @@
71
71
  (setv record.toUpdate? False))))
72
72
 
73
73
 
74
- (defn check-single [repo]
74
+ (defn skip-single [repo]
75
75
  (as-> Config.single it
76
76
  (and it (!= repo it))))
77
77
 
@@ -88,7 +88,7 @@
88
88
 
89
89
 
90
90
  (defn :async fetch-remote-local-metadata-1 [record client]
91
- (when (check-single record.repo) (return))
91
+ (when (skip-single record.repo) (return))
92
92
  (when (and record.pin (not (= (platform.machine) record.pin))) (return))
93
93
 
94
94
  (await (add-remote-metadata record client))
@@ -98,7 +98,7 @@
98
98
 
99
99
  (defn process-loop [records]
100
100
  (for [record records]
101
- (when (check-single record.repo) (continue))
101
+ (when (skip-single record.repo) (continue))
102
102
  (when (and record.pin (not (= (platform.machine) record.pin))) (continue))
103
103
 
104
104
  (when record.toUpdate?
@@ -142,6 +142,7 @@
142
142
  (setv Config.dry-run True))
143
143
 
144
144
 
145
+ ;; If a repo is deleted from config, then running this just deletes entry from DB
145
146
  (defn set-single [repo]
146
147
  (local-db.delete-row repo)
147
148
  (setv Config.single repo))
ghdl/remote.hy CHANGED
@@ -20,13 +20,13 @@
20
20
  (-> timestring (dateutil.parser.parse) (.strftime "%s") (int)))
21
21
 
22
22
 
23
- (defn find-matching-release [resp release-filter]
23
+ (defn find-matching-release [resp record]
24
+ (setv pattern (re.compile record.release-filter))
24
25
  (for [release resp]
25
- (setv name (get release "name"))
26
- (setv pattern (re.compile release-filter))
27
- (when (bool (re.search pattern name))
26
+ (when (and (bool (re.search pattern (get release "name")))
27
+ (= (get release "prerelease") record.pre-release?))
28
28
  (return release)))
29
- (print f"No matching release found for: {release-filter}")
29
+ (print f"No matching release found for: {record.release-filter}")
30
30
  (raise NoMatchingReleaseException))
31
31
 
32
32
 
@@ -37,7 +37,7 @@
37
37
  (setv resp (.json (await (client.get api :headers headers))))
38
38
  (cond
39
39
  record.pre-release? (get resp 0)
40
- record.release-filter (find-matching-release resp record.release-filter)
40
+ record.release-filter (find-matching-release resp record)
41
41
  True resp))
42
42
 
43
43
 
@@ -4,10 +4,10 @@
4
4
 
5
5
  Usage:
6
6
  ghdl
7
- ghdl (-f <repo> | --force <repo>)
8
7
  ghdl [-n | --dry-run]
9
8
  ghdl (-h | --help)
10
9
  ghdl (-v | --version)
10
+ ghdl [-n] (-f <repo> | --force <repo>)
11
11
 
12
12
  Options:
13
13
  -h --help Show this screen.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ghdl
3
- Version: 0.4.8
3
+ Version: 0.4.9
4
4
  Summary: Binary Manager for Github Releases
5
5
  Author-email: Imran Khan <imran@khan.ovh>
6
6
  License: GNU AFFERO GENERAL PUBLIC LICENSE
@@ -0,0 +1,14 @@
1
+ ghdl/__init__.py,sha256=XngLcck_FwXKT9uNFPNdCV3YscPufJC4uZ3R5byl3YU,71
2
+ ghdl/config.hy,sha256=Phq5jyoTizCGQMVtVFljx1MByqo9rBLaciZ69PsS-IE,1550
3
+ ghdl/local.hy,sha256=1StKPJ-l3mo6QdtaYfwL9FvZK97MdYIHrRRSF6S06OU,1687
4
+ ghdl/main.hy,sha256=D1dNJPeW-X0WRbh7974Oecxc_LtLH_AJGgBR5kiNuPc,4710
5
+ ghdl/remote.hy,sha256=is-pU8qxVk8rckxRY6Y3YAJCEl49klC2kfV-KoT7ADg,1610
6
+ ghdl/schema.hy,sha256=sXKjpaBVzBAPAx8Ko3RbCJB2GGbE5pilx-E3gVHtFMY,708
7
+ ghdl/utils.hy,sha256=DZpjuemTpuyex-2ShLRyNxMzMKPM0jia9CCnqMdizfA,1604
8
+ ghdl-0.4.9.data/scripts/ghdl,sha256=COv8sAI-zeTEcxkSvob6lAonVJ71vpAWmsnCfsa6HO8,618
9
+ ghdl-0.4.9.data/scripts/ghdl-delete-repo,sha256=b2X42MFFmvvJ6ldLAHyrcCkI5LB40Tuefbc3FMAtu54,92
10
+ ghdl-0.4.9.dist-info/LICENSE,sha256=DZak_2itbUtvHzD3E7GNUYSRK6jdOJ-GqncQ2weavLA,34523
11
+ ghdl-0.4.9.dist-info/METADATA,sha256=ySrH-X8WPqN7gWjjbqAzktbRiejrp9s_-VFKyCM6C04,40236
12
+ ghdl-0.4.9.dist-info/WHEEL,sha256=R06PA3UVYHThwHvxuRWMqaGcr-PuniXahwjmQRFMEkY,91
13
+ ghdl-0.4.9.dist-info/top_level.txt,sha256=SQzk56oLwp9nK3FgsTZRR9-tCPZokrFKwA-1TWOPPwQ,5
14
+ ghdl-0.4.9.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (75.1.0)
2
+ Generator: setuptools (75.5.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -1,14 +0,0 @@
1
- ghdl/__init__.py,sha256=pCoja9vl_gokkKocZ-gcIkDre9lCZZDuKCtWdmuLvFo,71
2
- ghdl/config.hy,sha256=KeBgBXwoSmkQdDUmjSFcvfdxPdjac40HhDu7DvTfMBg,1568
3
- ghdl/local.hy,sha256=1StKPJ-l3mo6QdtaYfwL9FvZK97MdYIHrRRSF6S06OU,1687
4
- ghdl/main.hy,sha256=4zrM3NrfjRL8Xu-xFGtaxsr2_4rIPPqUG0I3d0Y6TT4,4633
5
- ghdl/remote.hy,sha256=HtKipgn984YtMz8NWf8mHN4aLLj5cb8-AwgFL0JAADs,1570
6
- ghdl/schema.hy,sha256=sXKjpaBVzBAPAx8Ko3RbCJB2GGbE5pilx-E3gVHtFMY,708
7
- ghdl/utils.hy,sha256=DZpjuemTpuyex-2ShLRyNxMzMKPM0jia9CCnqMdizfA,1604
8
- ghdl-0.4.8.data/scripts/ghdl,sha256=KET7_ExHWZlIZZFaLSvdcpU1elvBsB0onEoxDIrDOew,613
9
- ghdl-0.4.8.data/scripts/ghdl-delete-repo,sha256=b2X42MFFmvvJ6ldLAHyrcCkI5LB40Tuefbc3FMAtu54,92
10
- ghdl-0.4.8.dist-info/LICENSE,sha256=DZak_2itbUtvHzD3E7GNUYSRK6jdOJ-GqncQ2weavLA,34523
11
- ghdl-0.4.8.dist-info/METADATA,sha256=qcU5NJhItKsp5lwGS400Aw0AiCtkWyP74zTptou7r9w,40236
12
- ghdl-0.4.8.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
13
- ghdl-0.4.8.dist-info/top_level.txt,sha256=SQzk56oLwp9nK3FgsTZRR9-tCPZokrFKwA-1TWOPPwQ,5
14
- ghdl-0.4.8.dist-info/RECORD,,
File without changes