Skip to content

Commit b751185

Browse files
authored
Merge pull request #74 from glyph/restructure-requirements
re-structure requirements gathering
2 parents 3625f0b + 147d95a commit b751185

10 files changed

+77
-135
lines changed

.github/workflows/test-ui.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
mypy src
3333
- name: Run Mac GUI tests
3434
run: |
35-
CI_MODE=YES python setup.py py2app --alias | cat
35+
CI_MODE=YES python py2app_setup.py py2app --alias | cat
3636
./dist/CiPomodouroboros.app/Contents/MacOS/CiPomodouroboros
3737
3838
model-tests:

pindeps

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
3+
pip-compile --strip-extras --quiet --upgrade --allow-unsafe --no-emit-index-url

setup.py py2app_setup.py

+5-3
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,10 @@
22
This is a setup.py script generated by py2applet
33
44
Usage:
5-
python setup.py py2app
5+
python py2app_setup.py py2app
66
"""
7+
8+
import py2app
79
import os
810

911
from setuptools import setup
@@ -33,13 +35,13 @@ def check_mode() -> str:
3335
"LSUIElement": True,
3436
"NSRequiresAquaSystemAppearance": False,
3537
"CFBundleIdentifier": f"im.glyph.and.this.is.{MODE}pomodouroboros",
38+
"CFBundleName": f"{MODE}Pomodouroboros",
3639
},
3740
"iconfile": f"{MODE}icon.icns",
41+
"app": APP,
3842
}
3943

4044
setup(
41-
name=f"{MODE}Pomodouroboros",
42-
app=APP,
4345
data_files=DATA_FILES,
4446
options={"py2app": OPTIONS},
4547
)

pyproject.toml

+44-1
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,52 @@
11
[build-system]
22
requires = [
3-
"setuptools>=42",
3+
"setuptools>=42,<71.0.0",
44
"wheel",
55
]
66
build-backend = "setuptools.build_meta"
77

8+
[project]
9+
name = "Pomodouroboros"
10+
authors=[
11+
{ name = "Glyph", email = "[email protected]" },
12+
]
13+
description = "An extremely opinionated pomodoro system."
14+
readme = "README.md"
15+
dependencies = [
16+
# core dependencies
17+
"twisted[tls,http2]",
18+
"python-dateutil",
19+
"ulid-py",
20+
"datetype",
21+
"fritter",
22+
"setuptools<71.0.0",
23+
24+
"pip-tools",
25+
"mypy",
26+
"mypy-zope",
27+
"types-python-dateutil",
28+
29+
"py2app ; sys_platform == 'darwin'",
30+
"pyobjc-core ; sys_platform == 'darwin'",
31+
"pyobjc-framework-Cocoa ; sys_platform == 'darwin'",
32+
"pyobjc-framework-ExceptionHandling ; sys_platform == 'darwin'",
33+
"pyobjc-framework-UserNotifications ; sys_platform == 'darwin'",
34+
"pyobjc-framework-CFNetwork ; sys_platform == 'darwin'",
35+
"quickmacapp ; sys_platform == 'darwin'",
36+
"quickmachotkey ; sys_platform == 'darwin'",
37+
"encrust ; sys_platform == 'darwin'",
38+
]
39+
classifiers = [
40+
"Programming Language :: Python :: 3",
41+
]
42+
version = "0.4.8"
43+
44+
[project.urls]
45+
Source = "https://github.com/glyph/Pomodouroboros"
46+
Bug-Tracker = "https://github.com/glyph/Pomodouroboros/issues"
47+
[project.scripts]
48+
pom = "pomodouroboros.cli:main"
49+
850
[tool.black]
951
line-length = 79
1052

@@ -17,3 +59,4 @@ line_length = 79
1759
ignore = [
1860
"E731",
1961
]
62+

requirements.in

-22
This file was deleted.

requirements.txt

+22-22
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# This file is autogenerated by pip-compile with Python 3.12
33
# by the following command:
44
#
5-
# pip-compile --allow-unsafe --no-emit-index-url
5+
# pip-compile --allow-unsafe --no-emit-index-url --strip-extras
66
#
77
altgraph==0.17.4
88
# via
@@ -45,14 +45,14 @@ cython-test-exception-raiser==1.0.2
4545
# via twisted
4646
datetype==2024.2.28
4747
# via
48-
# -r requirements.in
48+
# Pomodouroboros (pyproject.toml)
4949
# fritter
5050
delocate==0.12.0
5151
# via encrust
5252
encrust==2024.9.3 ; sys_platform == "darwin"
53-
# via -r requirements.in
53+
# via Pomodouroboros (pyproject.toml)
5454
fritter==0.0.9
55-
# via -r requirements.in
55+
# via Pomodouroboros (pyproject.toml)
5656
h11==0.14.0
5757
# via httpcore
5858
h2==4.1.0
@@ -63,7 +63,7 @@ hpack==4.0.0
6363
# via h2
6464
httpcore==1.0.7
6565
# via httpx
66-
httpx[http2]==0.28.0
66+
httpx==0.28.0
6767
# via twisted
6868
hyperframe==6.0.1
6969
# via h2
@@ -87,24 +87,24 @@ modulegraph==0.19.6
8787
# via py2app
8888
mypy==1.13.0
8989
# via
90-
# -r requirements.in
90+
# Pomodouroboros (pyproject.toml)
9191
# mypy-zope
9292
mypy-extensions==1.0.0
9393
# via mypy
9494
mypy-zope==1.0.9
95-
# via -r requirements.in
95+
# via Pomodouroboros (pyproject.toml)
9696
packaging==24.2
9797
# via
9898
# build
9999
# delocate
100100
# py2app
101101
pip-tools==7.4.1
102-
# via -r requirements.in
102+
# via Pomodouroboros (pyproject.toml)
103103
priority==1.3.0
104104
# via twisted
105105
py2app==0.28.8 ; sys_platform == "darwin"
106106
# via
107-
# -r requirements.in
107+
# Pomodouroboros (pyproject.toml)
108108
# encrust
109109
pyasn1==0.6.1
110110
# via
@@ -118,7 +118,7 @@ pyhamcrest==2.1.0
118118
# via twisted
119119
pyobjc-core==10.3.2 ; sys_platform == "darwin"
120120
# via
121-
# -r requirements.in
121+
# Pomodouroboros (pyproject.toml)
122122
# pyobjc-framework-cfnetwork
123123
# pyobjc-framework-cocoa
124124
# pyobjc-framework-exceptionhandling
@@ -127,23 +127,23 @@ pyobjc-core==10.3.2 ; sys_platform == "darwin"
127127
# twisted
128128
pyobjc-framework-cfnetwork==10.3.2 ; sys_platform == "darwin"
129129
# via
130-
# -r requirements.in
130+
# Pomodouroboros (pyproject.toml)
131131
# twisted
132132
pyobjc-framework-cocoa==10.3.2 ; sys_platform == "darwin"
133133
# via
134-
# -r requirements.in
134+
# Pomodouroboros (pyproject.toml)
135135
# pyobjc-framework-cfnetwork
136136
# pyobjc-framework-exceptionhandling
137137
# pyobjc-framework-usernotifications
138138
# quickmacapp
139139
# twisted
140140
pyobjc-framework-exceptionhandling==10.3.2 ; sys_platform == "darwin"
141141
# via
142-
# -r requirements.in
142+
# Pomodouroboros (pyproject.toml)
143143
# quickmacapp
144144
pyobjc-framework-usernotifications==10.3.2 ; sys_platform == "darwin"
145145
# via
146-
# -r requirements.in
146+
# Pomodouroboros (pyproject.toml)
147147
# quickmacapp
148148
pyopenssl==24.3.0
149149
# via twisted
@@ -154,11 +154,11 @@ pyproject-hooks==1.2.0
154154
pyserial==3.5
155155
# via twisted
156156
python-dateutil==2.9.0.post0
157-
# via -r requirements.in
157+
# via Pomodouroboros (pyproject.toml)
158158
quickmacapp==2023.4.24 ; sys_platform == "darwin"
159-
# via -r requirements.in
159+
# via Pomodouroboros (pyproject.toml)
160160
quickmachotkey==2023.11.17 ; sys_platform == "darwin"
161-
# via -r requirements.in
161+
# via Pomodouroboros (pyproject.toml)
162162
service-identity==24.2.0
163163
# via twisted
164164
six==1.16.0
@@ -167,13 +167,13 @@ sniffio==1.3.1
167167
# via anyio
168168
sortedcontainers==2.4.0
169169
# via hypothesis
170-
twisted[http2,tls]==24.10.0
170+
twisted==24.10.0
171171
# via
172-
# -r requirements.in
172+
# Pomodouroboros (pyproject.toml)
173173
# encrust
174174
# quickmacapp
175175
types-python-dateutil==2.9.0.20241003
176-
# via -r requirements.in
176+
# via Pomodouroboros (pyproject.toml)
177177
typing-extensions==4.12.2
178178
# via
179179
# delocate
@@ -182,7 +182,7 @@ typing-extensions==4.12.2
182182
tzdata==2024.2
183183
# via fritter
184184
ulid-py==1.1.0
185-
# via -r requirements.in
185+
# via Pomodouroboros (pyproject.toml)
186186
wheel==0.45.1
187187
# via pip-tools
188188
wheel-filename==1.4.1
@@ -202,7 +202,7 @@ pip==24.3.1
202202
# via pip-tools
203203
setuptools==70.3.0
204204
# via
205-
# -r requirements.in
205+
# Pomodouroboros (pyproject.toml)
206206
# incremental
207207
# modulegraph
208208
# pip-tools

runme

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
mypy ./src;
44
rm -fr ./build ./dist;
55
# https://github.com/ronaldoussoren/py2app/issues/444
6-
python setup.py py2app --alias | cat;
6+
python py2app_setup.py py2app --alias | cat;
77
rm -fr ./build;
88
exec ./dist/Pomodouroboros.app/Contents/MacOS/Pomodouroboros;

setup.cfg

-27
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,3 @@
1-
[metadata]
2-
name = Pomodouroboros
3-
version = 0.4.7
4-
author = Glyph
5-
author_email = [email protected]
6-
description = An extremely opinionated pomodoro system.
7-
long_description = file: README.md
8-
long_description_content_type = text/markdown
9-
url = https://github.com/glyph/Pomodouroboros
10-
project_urls =
11-
Bug Tracker = https://github.com/glyph/Pomodouroboros/issues
12-
classifiers =
13-
Programming Language :: Python :: 3
14-
15-
[options]
16-
package_dir =
17-
= src
18-
packages = find:
19-
python_requires = >=3.6
20-
21-
[options.packages.find]
22-
where = src
23-
24-
[options.entry_points]
25-
console_scripts =
26-
pom = pomodouroboros.cli:main
27-
281
[flake8]
292
# ObjC method names create too many impossible-to-shorten lines
303
# W503 seems at odds with black?

src/scratch.py

-57
This file was deleted.

testme

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@ mypy ./src;
44
rm -fr ./dist/TestPomodouroboros.app;
55
export TEST_MODE=YES;
66
# https://github.com/ronaldoussoren/py2app/issues/444
7-
python setup.py py2app --alias | cat;
7+
python py2app_setup.py py2app --alias | cat;
88
./dist/TestPomodouroboros.app/Contents/MacOS/TestPomodouroboros;

0 commit comments

Comments
 (0)