Skip to content

Commit 20a79d1

Browse files
chore(libclimate): add installable SIS Python packaging skeleton (#1)
* chore(libclimate): add installable SIS Python packaging skeleton Land SIS Python boilerplate so the empty **libclimate** package installs and tests without a **Climate** API: - **pyproject.toml** / **setup.py** with runtime deps **diagnosticism**, **pyclasp**, and **woad**; - **python-package.yml** matrix 3.8–3.14 plus a **build-py27** job; - README, CHANGES, NEWS, AUTHORS, TODO, LICENSE, and dist/test helpers; * chore(python): establish canonical .sis/ project identity files Add .sis/project_name.txt and .sis/script_info_lines.txt across all 10 Python repositories to define canonical short project names and script information headers: - asynkio; - CLASP.Python; - Diagnosticism.Python; - libCLImate.Python; - libpath.Python; - p99.Python; - py2be; - Quench.Python; - recls.Python; - woad.Python; * docs: complete AUTHORS.md and NEWS.md for all Python projects * chore(python): standardise editor and VCS boilerplate across projects Align .gitattributes, .gitignore, .editorconfig, .vimrc, and .vscode/settings.json across all 10 Python projects: - Linguist attributes for Python / shell / vimrc; - Synesis Python ignore set including .venv and tool caches; - EditorConfig matching .vscode indent/EOL/newline rules (no trailing-blank-line policy); - Vim and VS Code python rulers unified at [ 50, 60, 76, 120 ]. * chore(python): adopt PEP 621 hybrid packaging for Dual-tier libraries Add pyproject.toml alongside setup.py/setup.cfg so Dual-tier Python libraries keep Python 2.7 installability while modern tooling uses PEP 621: - migrate CLASP.Python, Diagnosticism.Python, and py2be to hybrid form; - add universal wheel setup.cfg; sync classifiers through 3.14; - fix CLASP.Python project URL casing; verify libCLImate and woad hybrids. * chore(python): complete MANIFEST.in for active library sdists Ensure active Python libraries package AUTHORS, NEWS, and other standard docs in sdists: - refresh MANIFEST.in for asynkio, CLASP.Python, Diagnosticism.Python, py2be; - add MANIFEST.in for libCLImate.Python and woad.Python; - fix missing final newline on CLASP.Python MANIFEST.in. * version * ci(python): standardise python-package.yml push and PR triggers Align active Python libraries to the Synesis canonical CI branch set: - on.push.branches: master, dev, boilerplate, idiomatic, rc1, rc2, rc3; - unfiltered pull_request:; - drop ad-hoc branches and path globs from asynkio and Dual workflows. * test(python): standardise run_all_unit_tests.sh with .sis identity Align active Python libraries on the misc-dev-scripts unit-test helper: - refresh or add run_all_unit_tests.sh in all six active projects; - load .sis/project_name.txt and show script_info_lines.txt on --help; - use unittest discover -s tests (pytest preference for asynkio); - update the misc-dev-scripts Python template to match. * chore(python): prefer project .venv in run_all_unit_tests.sh discovery Discover `$Dir/.venv/bin/python` before PATH so bare helper runs avoid Apple/Xcode python3 (too old for asynkio; unsuitable for local install/test). * ci(libclimate): add failing ruff lint job for Dual-tier CI Introduce ruff as the Dual lint gate for libCLImate.Python: - add [tool.ruff] (py38, E/F; E501 ignored pending wrap pass) and a dev optional extra; - add a Lint (ruff) job on python-package.yml before the build matrix; - re-export runtime deps via explicit aliases and `__all__` for F401. * chore(python): bump active library versions past last published tags Raise asynkio, CLASP.Python, Diagnosticism.Python, libCLImate.Python, py2be, and woad.Python one patch above the latest published tag (or prior local floor) so packaging/CI modernisation is releasable; sync package metadata, smoke asserts, CHANGES.md, and NEWS.md. * chore(python): bootstrap Tier 2 Dual skeletons at 0.0.0 with CI Add packaging, version-only packages, Dual helpers, ruff lint, and python-package.yml to libpath.Python, p99.Python, Quench.Python, and recls.Python at 0.0.0 (never tagged); align libCLImate.Python to 0.0.0 under the same rule.
1 parent bfe43ca commit 20a79d1

24 files changed

Lines changed: 948 additions & 1 deletion

‎.editorconfig‎

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
root = true
2+
3+
# Language indent/EOL/charset overlap with .vscode/settings.json.
4+
# Rulers, renderWhitespace, detectIndentation, mergeEditor, and
5+
# language-server settings cannot be expressed here — they stay in
6+
# settings.json.
7+
8+
[*]
9+
charset = utf-8
10+
end_of_line = lf
11+
indent_size = 2
12+
indent_style = tab
13+
insert_final_newline = true
14+
trim_trailing_whitespace = true
15+
16+
# [json]
17+
[*.json]
18+
indent_size = 2
19+
indent_style = space
20+
21+
# [markdown]
22+
[*.md]
23+
indent_size = 2
24+
indent_style = space
25+
26+
# [python]
27+
[*.py]
28+
indent_size = 4
29+
indent_style = space
30+
31+
# [shellscript]
32+
[*.{bash,sh,zsh}]
33+
indent_size = 2
34+
indent_style = space
35+
36+
# [toml]
37+
[*.toml]
38+
indent_size = 2
39+
indent_style = tab
40+
41+
# [yaml]
42+
[*.{yaml,yml}]
43+
indent_size = 2
44+
indent_style = space

‎.gitattributes‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
*.c linguist-language=C
2+
*.cpp linguist-language=C++
3+
*.h linguist-language=C
4+
*.hpp linguist-language=C++
5+
*.html linguist-detectable=false
6+
*.py linguist-language=Python
7+
*.sh linguist-detectable=false
8+
*.vimrc linguist-detectable=false
9+
makefile linguist-detectable=false
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
# This workflow will install Python dependencies, run tests, and smoke
2+
# the sdist/wheel on a range of Python versions.
3+
#
4+
# Created: 21st August 2026
5+
# Updated: 14th September 2026
6+
#
7+
8+
name: Python package
9+
10+
on:
11+
push:
12+
branches:
13+
- master
14+
- dev
15+
- boilerplate
16+
- idiomatic
17+
- rc1
18+
- rc2
19+
- rc3
20+
pull_request:
21+
22+
permissions:
23+
contents: read
24+
25+
defaults:
26+
run:
27+
shell: bash
28+
29+
jobs:
30+
lint:
31+
name: Lint (ruff)
32+
runs-on: ubuntu-latest
33+
34+
steps:
35+
- name: Checking out code
36+
uses: actions/checkout@v4
37+
38+
- name: Set up Python
39+
uses: actions/setup-python@v5
40+
with:
41+
python-version: "3.14"
42+
43+
- name: Install dependencies
44+
run: |
45+
python -m pip install --upgrade pip
46+
python -m pip install ruff
47+
48+
- name: Lint with ruff
49+
run: |
50+
ruff check .
51+
52+
build:
53+
54+
runs-on: ubuntu-latest
55+
strategy:
56+
fail-fast: false
57+
matrix:
58+
python-version:
59+
- "3.8"
60+
- "3.9"
61+
- "3.10"
62+
- "3.11"
63+
- "3.12"
64+
- "3.13"
65+
- "3.14"
66+
67+
steps:
68+
- name: Checking out code
69+
uses: actions/checkout@v4
70+
71+
- name: Set up Python ${{ matrix.python-version }}
72+
uses: actions/setup-python@v5
73+
with:
74+
python-version: ${{ matrix.python-version }}
75+
76+
- name: Install dependencies
77+
run: |
78+
python -m pip install --upgrade pip
79+
python -m pip install pytest
80+
python -m pip install -e .
81+
82+
- name: Test with pytest
83+
run: |
84+
pytest
85+
86+
- name: Build and install smoke
87+
run: |
88+
python -m pip install build
89+
python -m build
90+
python -m pip install dist/libclimate-*.whl
91+
python -c "import libclimate; assert libclimate.__version__ == '0.0.0'; print(libclimate.__version__)"
92+
93+
build-py27:
94+
95+
runs-on: ubuntu-latest
96+
container:
97+
image: python:2.7-slim
98+
steps:
99+
- uses: actions/checkout@v4
100+
- name: Install dependencies
101+
run: |
102+
python -m pip install --upgrade "pip<21" setuptools
103+
python -m pip install diagnosticism pyclasp woad
104+
- name: Compile library modules
105+
run: |
106+
python -m compileall libclimate
107+
- name: Test with unittest
108+
run: |
109+
python -m unittest discover -s tests
110+
env:
111+
PYTHONPATH: ${{ github.workspace }}

‎.gitignore‎

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
2+
# directories (by name)
3+
4+
/.bin/
5+
/.pytest_cache/
6+
/.ruff_cache/
7+
/.venv/
8+
9+
build/
10+
dist/
11+
dist-old/
12+
scratch/
13+
14+
*.egg-info/
15+
16+
17+
# directories (by pattern)
18+
19+
**/__pycache__/
20+
21+
22+
# files (by name)
23+
24+
.DS_Store
25+
26+
notes.txt
27+
28+
29+
# files (by pattern)
30+
31+
*~
32+
*.pyc
33+
*.pyo
34+
*.swo
35+
*.swp
36+
*.tmp
37+
*.zip

‎.sis/project_name.txt‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
libCLImate.Python

‎.sis/script_info_lines.txt‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
libCLImate.Python is a Command-Line Interface boilerplate mini-framework for Python
2+
Copyright (c) 2019-2026, Matthew Wilson and Synesis Information Systems

‎.vimrc‎

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
" Synesis Python project .vimrc — aligned with .vscode/settings.json (Python)
2+
3+
set nocompatible
4+
filetype indent plugin on
5+
syntax enable
6+
set autoindent
7+
set backspace=indent,eol,start
8+
set hlsearch
9+
set incsearch
10+
set number
11+
12+
" files.insertFinalNewline
13+
set eol
14+
set fixeol
15+
16+
" editor.renderWhitespace: all
17+
set list
18+
set listchars=tab:->,trail:-,extends:>,precedes:<,nbsp:+
19+
20+
" editor.detectIndentation: false — global defaults match [python] (editor.tabSize: 4, insertSpaces: true)
21+
set colorcolumn=76
22+
set expandtab
23+
set shiftwidth=4
24+
set softtabstop=4
25+
set tabstop=4
26+
27+
" colorcolumn draws a full-column tint in Vim (not a VS Code-style 1px line).
28+
" Keep it subtle via the ColorColumn highlight group; reapply after colorscheme changes.
29+
if has('termguicolors')
30+
" set termguicolors
31+
endif
32+
33+
function! s:ConfigureColorColumn() abort
34+
highlight ColorColumn ctermbg=236 guibg=#2a2a2a cterm=NONE gui=NONE
35+
endfunction
36+
37+
call s:ConfigureColorColumn()
38+
autocmd ColorScheme * call s:ConfigureColorColumn()
39+
40+
" files.trimTrailingWhitespace
41+
autocmd BufWritePre * %s/\s\+$//e
42+
43+
augroup sis_python
44+
autocmd!
45+
46+
" [json] / [markdown] / [yaml]
47+
autocmd FileType json,markdown,yaml setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2
48+
49+
" [python] — match .vscode [python] tabSize 4 / insertSpaces true / rulers 50,60,76,120
50+
autocmd FileType python setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4 colorcolumn=50,60,76,120
51+
52+
" [shellscript]
53+
autocmd FileType sh,bash,zsh setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 colorcolumn=60,76
54+
55+
" [toml]
56+
autocmd FileType toml setlocal noexpandtab tabstop=2 shiftwidth=2 softtabstop=2
57+
augroup END

‎.vscode/settings.json‎

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
{
2+
"[json]": {
3+
"editor.tabSize": 2,
4+
},
5+
"[markdown]": {
6+
"editor.insertSpaces": true,
7+
"editor.tabSize": 2,
8+
},
9+
"[python]": {
10+
"diffEditor.ignoreTrimWhitespace": false,
11+
"editor.insertSpaces": true,
12+
"editor.rulers": [ 50, 60, 76, 120 ],
13+
"editor.tabSize": 4,
14+
},
15+
"[shellscript]": {
16+
"editor.insertSpaces": true,
17+
"editor.rulers": [ 60, 76 ],
18+
"editor.tabSize": 2,
19+
},
20+
"[toml]": {
21+
"editor.insertSpaces": false,
22+
"editor.tabSize": 2,
23+
},
24+
"[yaml]": {
25+
"editor.insertSpaces": true,
26+
"editor.tabSize": 2,
27+
},
28+
"editor.detectIndentation": false,
29+
"editor.insertSpaces": false,
30+
"editor.renderWhitespace": "all",
31+
"editor.rulers": [ 76 ],
32+
"editor.tabSize": 2,
33+
"files.exclude": {
34+
"**/*.egg-info": true,
35+
"**/*.swp": true,
36+
"**/__pycache__": true,
37+
},
38+
"files.insertFinalNewline": true,
39+
"files.trimTrailingWhitespace": true,
40+
"git.mergeEditor": false,
41+
"python.analysis.typeCheckingMode": "standard",
42+
"python.languageServer": "Pylance",
43+
}

‎AUTHORS.md‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# libCLImate.Python - Authors <!-- omit in toc -->
2+
3+
4+
## Major Contributors
5+
6+
| Name | GitHub |
7+
| ----------- | --------------------------------- |
8+
| Matt Wilson | [mwsis](https://github.com/mwsis) |
9+
10+
11+
## Defect reports, fixes and suggestions (for which we are very grateful)
12+
13+
| Name | GitHub |
14+
| ------- | ------ |
15+
| \<none> | |
16+
17+
18+
Contributions are welcomed.
19+
20+
21+
<!-- ########################### end of file ########################### -->

‎CHANGES.md‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# libCLImate.Python - Changes <!-- omit in toc -->
2+
3+
4+
## 0.0.0 - 14th September 2026
5+
6+
* initial project scaffolding;
7+
* declared runtime dependencies **diagnosticism**, **pyclasp**, and **woad**;
8+
* packaging, documentation, and CI modernisation (canonical CI, **ruff**, helper scripts, **MANIFEST.in**);
9+
* **Python** **2.7** and **3.8+** compatibility;
10+
11+
12+
<!-- ########################### end of file ########################### -->

0 commit comments

Comments
 (0)