lumos-identity-cli 0.0.0.dev1__tar.gz
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.
- lumos_identity_cli-0.0.0.dev1/.cursor/Dockerfile +8 -0
- lumos_identity_cli-0.0.0.dev1/.cursor/rules/commit-message.mdc +158 -0
- lumos_identity_cli-0.0.0.dev1/.cursor/rules/docs.mdc +69 -0
- lumos_identity_cli-0.0.0.dev1/.devcontainer/devcontainer.json +31 -0
- lumos_identity_cli-0.0.0.dev1/.github/workflows/build.yml +259 -0
- lumos_identity_cli-0.0.0.dev1/.github/workflows/release.yml +209 -0
- lumos_identity_cli-0.0.0.dev1/.gitignore +16 -0
- lumos_identity_cli-0.0.0.dev1/.pre-commit-config.yaml +35 -0
- lumos_identity_cli-0.0.0.dev1/.releaserc.yaml +45 -0
- lumos_identity_cli-0.0.0.dev1/CHANGELOG.md +40 -0
- lumos_identity_cli-0.0.0.dev1/Makefile +42 -0
- lumos_identity_cli-0.0.0.dev1/PKG-INFO +77 -0
- lumos_identity_cli-0.0.0.dev1/README.md +53 -0
- lumos_identity_cli-0.0.0.dev1/docs/authentication.md +31 -0
- lumos_identity_cli-0.0.0.dev1/docs/contributing.md +270 -0
- lumos_identity_cli-0.0.0.dev1/docs/examples.md +394 -0
- lumos_identity_cli-0.0.0.dev1/docs/index.md +44 -0
- lumos_identity_cli-0.0.0.dev1/docs/installation.md +70 -0
- lumos_identity_cli-0.0.0.dev1/docs/reference.md +360 -0
- lumos_identity_cli-0.0.0.dev1/docs/src/authentication.md +42 -0
- lumos_identity_cli-0.0.0.dev1/docs/src/conf.py +73 -0
- lumos_identity_cli-0.0.0.dev1/docs/src/contributing.md +292 -0
- lumos_identity_cli-0.0.0.dev1/docs/src/examples.md +404 -0
- lumos_identity_cli-0.0.0.dev1/docs/src/index.md +59 -0
- lumos_identity_cli-0.0.0.dev1/docs/src/installation.md +82 -0
- lumos_identity_cli-0.0.0.dev1/docs/src/reference.md +153 -0
- lumos_identity_cli-0.0.0.dev1/pyproject.toml +169 -0
- lumos_identity_cli-0.0.0.dev1/sample-scripts/create_requests.py +30 -0
- lumos_identity_cli-0.0.0.dev1/sample-scripts/customer-secrets.sh +114 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/__init__.py +4 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/__main__.py +9 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/cli.py +96 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/common/__init__.py +1 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/common/client.py +479 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/common/client_helpers.py +40 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/common/helpers.py +90 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/common/keyhelpers.py +41 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/common/logging.py +30 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/common/models.py +236 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/list_collections/__init__.py +1 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/list_collections/cli.py +289 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/request/__init__.py +1 -0
- lumos_identity_cli-0.0.0.dev1/src/lumos/request/cli.py +523 -0
- lumos_identity_cli-0.0.0.dev1/tests/cli_test.py +539 -0
- lumos_identity_cli-0.0.0.dev1/tests/client_helpers_test.py +48 -0
- lumos_identity_cli-0.0.0.dev1/tests/helpers_test.py +115 -0
- lumos_identity_cli-0.0.0.dev1/uv.lock +1343 -0
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Angular-style commit message guidelines. Apply when writing git commit messages.
|
|
3
|
+
globs:
|
|
4
|
+
alwaysApply: false
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Commit Message Format
|
|
8
|
+
|
|
9
|
+
Follow the Angular commit message convention for all commits. This format creates an easier-to-read commit history and enables automated changelog generation.
|
|
10
|
+
|
|
11
|
+
## Structure
|
|
12
|
+
|
|
13
|
+
```
|
|
14
|
+
<type>(<scope>): <short summary>
|
|
15
|
+
|
|
16
|
+
<body>
|
|
17
|
+
|
|
18
|
+
<footer>
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Header Format (Required)
|
|
22
|
+
|
|
23
|
+
```
|
|
24
|
+
<type>(<scope>): <short summary>
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
- **type**: Required. See types below.
|
|
28
|
+
- **scope**: Optional. The area of the codebase affected.
|
|
29
|
+
- **summary**: Required. Present tense, no capitalization, no period at the end.
|
|
30
|
+
|
|
31
|
+
### Commit Types
|
|
32
|
+
|
|
33
|
+
| Type | Description |
|
|
34
|
+
| ------------ | --------------------------------------------------------------------------------------------------- |
|
|
35
|
+
| **feat** | A new feature |
|
|
36
|
+
| **fix** | A bug fix |
|
|
37
|
+
| **docs** | Documentation only changes |
|
|
38
|
+
| **style** | Changes that do not affect the meaning of the code (formatting, whitespace) |
|
|
39
|
+
| **refactor** | A code change that neither fixes a bug nor adds a feature |
|
|
40
|
+
| **perf** | A code change that improves performance |
|
|
41
|
+
| **test** | Adding missing tests or correcting existing tests |
|
|
42
|
+
| **build** | Changes that affect the build system or external dependencies |
|
|
43
|
+
| **ci** | Changes to CI configuration files and scripts |
|
|
44
|
+
| **chore** | Other changes that don't modify src or test files |
|
|
45
|
+
| **revert** | Reverts a previous commit |
|
|
46
|
+
|
|
47
|
+
### Summary Rules
|
|
48
|
+
|
|
49
|
+
- Use imperative, present tense: "change" not "changed" nor "changes"
|
|
50
|
+
- Don't capitalize the first letter
|
|
51
|
+
- No period (.) at the end
|
|
52
|
+
- Keep under 72 characters
|
|
53
|
+
|
|
54
|
+
## Body (Optional but Recommended)
|
|
55
|
+
|
|
56
|
+
- Use imperative, present tense
|
|
57
|
+
- Explain the **motivation** for the change
|
|
58
|
+
- Explain **why** you are making the change, not just what
|
|
59
|
+
- Compare previous behavior with new behavior if helpful
|
|
60
|
+
- Must be at least 20 characters if included
|
|
61
|
+
- Wrap at 72 characters
|
|
62
|
+
|
|
63
|
+
## Footer (Optional)
|
|
64
|
+
|
|
65
|
+
Used for:
|
|
66
|
+
- Breaking changes
|
|
67
|
+
- Deprecations
|
|
68
|
+
- Issue references
|
|
69
|
+
|
|
70
|
+
### Breaking Changes
|
|
71
|
+
|
|
72
|
+
```
|
|
73
|
+
BREAKING CHANGE: <summary>
|
|
74
|
+
|
|
75
|
+
<description + migration instructions>
|
|
76
|
+
|
|
77
|
+
Fixes #<issue number>
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
### Deprecations
|
|
81
|
+
|
|
82
|
+
```
|
|
83
|
+
DEPRECATED: <what is deprecated>
|
|
84
|
+
|
|
85
|
+
<description + recommended update path>
|
|
86
|
+
|
|
87
|
+
Closes #<pr number>
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
### Issue References
|
|
91
|
+
|
|
92
|
+
```
|
|
93
|
+
Fixes #123
|
|
94
|
+
Closes #456
|
|
95
|
+
Refs #789
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
## Examples
|
|
99
|
+
|
|
100
|
+
### Feature with scope
|
|
101
|
+
```
|
|
102
|
+
feat(cli): add verbose logging option
|
|
103
|
+
|
|
104
|
+
Add --verbose flag to enable detailed output during command execution.
|
|
105
|
+
This helps users debug issues with API calls.
|
|
106
|
+
|
|
107
|
+
Closes #42
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
### Bug fix
|
|
111
|
+
```
|
|
112
|
+
fix(auth): handle expired token refresh correctly
|
|
113
|
+
|
|
114
|
+
Previously, expired tokens would cause a crash instead of
|
|
115
|
+
triggering a refresh flow. Now the client properly catches
|
|
116
|
+
the expiration and requests a new token.
|
|
117
|
+
|
|
118
|
+
Fixes #128
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
### Documentation
|
|
122
|
+
```
|
|
123
|
+
docs: update README with installation steps
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
### Breaking change
|
|
127
|
+
```
|
|
128
|
+
feat(api): change response format to JSON
|
|
129
|
+
|
|
130
|
+
BREAKING CHANGE: API responses are now JSON instead of XML.
|
|
131
|
+
|
|
132
|
+
Migrate by updating response parsers to handle JSON format.
|
|
133
|
+
See migration guide in docs/migration-v2.md.
|
|
134
|
+
|
|
135
|
+
Closes #200
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
### Revert
|
|
139
|
+
```
|
|
140
|
+
revert: feat(cli): add verbose logging option
|
|
141
|
+
|
|
142
|
+
This reverts commit abc1234.
|
|
143
|
+
|
|
144
|
+
The verbose mode was causing performance issues in production.
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
## Quick Reference
|
|
148
|
+
|
|
149
|
+
✅ Good:
|
|
150
|
+
- `feat(auth): add OAuth2 support`
|
|
151
|
+
- `fix: resolve memory leak in worker pool`
|
|
152
|
+
- `docs: add API reference for new endpoints`
|
|
153
|
+
|
|
154
|
+
❌ Bad:
|
|
155
|
+
- `Fixed bug` (no type, past tense, vague)
|
|
156
|
+
- `feat: Added new feature.` (past tense, has period)
|
|
157
|
+
- `FEAT: Add Feature` (wrong case)
|
|
158
|
+
- `feat(auth)add oauth` (missing colon after scope)
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Guidelines for editing documentation files. Apply when creating or modifying docs, README, or documentation content.
|
|
3
|
+
globs:
|
|
4
|
+
- README.md
|
|
5
|
+
- docs/**
|
|
6
|
+
alwaysApply: false
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
# Documentation Guidelines
|
|
10
|
+
|
|
11
|
+
## Editable Files
|
|
12
|
+
|
|
13
|
+
Only edit documentation in these locations:
|
|
14
|
+
|
|
15
|
+
| Location | Purpose |
|
|
16
|
+
|----------|---------|
|
|
17
|
+
| `README.md` | Project overview and quickstart |
|
|
18
|
+
| `docs/src/*.md` | Detailed documentation source files |
|
|
19
|
+
|
|
20
|
+
## Never Edit Directly
|
|
21
|
+
|
|
22
|
+
**Never edit `docs/*.md` files directly.** These are auto-generated from Sphinx source files and will be overwritten.
|
|
23
|
+
|
|
24
|
+
## Building Docs
|
|
25
|
+
|
|
26
|
+
After editing any files in `docs/src/`, rebuild the documentation:
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
make -C docs docs
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
This generates:
|
|
33
|
+
- `docs/*.md` - Markdown output for GitHub viewing
|
|
34
|
+
- `docs/src/_build/html/` - HTML documentation
|
|
35
|
+
|
|
36
|
+
## README Guidelines
|
|
37
|
+
|
|
38
|
+
The README should be:
|
|
39
|
+
|
|
40
|
+
- **Concise**: Brief project overview, not exhaustive documentation
|
|
41
|
+
- **Quickstart focused**: Get users running in minutes
|
|
42
|
+
- **A gateway**: Link to detailed docs in `docs/` for deeper topics
|
|
43
|
+
|
|
44
|
+
### README Structure
|
|
45
|
+
|
|
46
|
+
1. Project title and badges
|
|
47
|
+
2. One-paragraph description
|
|
48
|
+
3. Quick installation
|
|
49
|
+
4. Basic usage example
|
|
50
|
+
5. Links to detailed documentation in `docs/`
|
|
51
|
+
|
|
52
|
+
### Linking to Detailed Docs
|
|
53
|
+
|
|
54
|
+
For topics that need more detail, link to the full docs:
|
|
55
|
+
|
|
56
|
+
```markdown
|
|
57
|
+
For more details, see the [Installation Guide](docs/installation.md).
|
|
58
|
+
|
|
59
|
+
See the [CLI Reference](docs/cli-reference.md) for all available commands.
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
## Sphinx Source Files
|
|
63
|
+
|
|
64
|
+
When editing `docs/src/*.md`:
|
|
65
|
+
|
|
66
|
+
- Follow existing formatting conventions
|
|
67
|
+
- Use proper Sphinx/MyST markdown syntax
|
|
68
|
+
- Include cross-references where appropriate
|
|
69
|
+
- Always rebuild with `make -C docs docs` after changes
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"image": "public.ecr.aws/lumos/devcontainer/base:latest",
|
|
3
|
+
"mounts": [
|
|
4
|
+
"source=${localEnv:HOME}/.cursor/,target=/home/vscode/.cursor/,type=bind",
|
|
5
|
+
"source=lumos-cli-devcontainer-venv,target=${containerWorkspaceFolder}/.venv,type=volume",
|
|
6
|
+
"source=lumos-cli-devcontainer-data,target=/home/vscode/devcontainer-data,type=volume"
|
|
7
|
+
],
|
|
8
|
+
"initializeCommand": {
|
|
9
|
+
"cursor": "mkdir -p ${HOME}/.cursor/"
|
|
10
|
+
},
|
|
11
|
+
"onCreateCommand": {
|
|
12
|
+
"git_safe": "git config --global --add safe.directory ${containerWorkspaceFolder}",
|
|
13
|
+
"venv": "sudo chown -R vscode:vscode ${containerWorkspaceFolder}/.venv"
|
|
14
|
+
},
|
|
15
|
+
"customizations": {
|
|
16
|
+
"vscode": {
|
|
17
|
+
"extensions": [
|
|
18
|
+
"ms-python.python",
|
|
19
|
+
"anysphere.cursorpyright",
|
|
20
|
+
"GitHub.vscode-pull-request-github",
|
|
21
|
+
"charliermarsh.ruff",
|
|
22
|
+
"eamodio.gitlens",
|
|
23
|
+
"tamasfe.even-better-toml"
|
|
24
|
+
],
|
|
25
|
+
"settings": {
|
|
26
|
+
// Devcontainer specific settings
|
|
27
|
+
"terminal.integrated.defaultProfile.linux": "zsh"
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -0,0 +1,259 @@
|
|
|
1
|
+
name: Build
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_call:
|
|
5
|
+
inputs:
|
|
6
|
+
version:
|
|
7
|
+
description: "Version to build (x.x.x)"
|
|
8
|
+
type: string
|
|
9
|
+
required: false
|
|
10
|
+
default: ''
|
|
11
|
+
push:
|
|
12
|
+
branches:
|
|
13
|
+
- main
|
|
14
|
+
pull_request:
|
|
15
|
+
branches:
|
|
16
|
+
- main
|
|
17
|
+
|
|
18
|
+
jobs:
|
|
19
|
+
|
|
20
|
+
validate-docs:
|
|
21
|
+
name: Validate Documentation
|
|
22
|
+
runs-on: ubuntu-latest
|
|
23
|
+
steps:
|
|
24
|
+
- name: Checkout code
|
|
25
|
+
uses: actions/checkout@v4
|
|
26
|
+
|
|
27
|
+
- name: Setup Python
|
|
28
|
+
uses: actions/setup-python@v5
|
|
29
|
+
with:
|
|
30
|
+
python-version: '3.10.6'
|
|
31
|
+
|
|
32
|
+
- name: Setup UV
|
|
33
|
+
uses: astral-sh/setup-uv@v4
|
|
34
|
+
with:
|
|
35
|
+
version: latest
|
|
36
|
+
enable-cache: true
|
|
37
|
+
|
|
38
|
+
- name: Install dependencies
|
|
39
|
+
run: uv sync --group docs
|
|
40
|
+
|
|
41
|
+
- name: Build documentation
|
|
42
|
+
run: make docs
|
|
43
|
+
|
|
44
|
+
- name: Check for uncommitted documentation changes
|
|
45
|
+
run: |
|
|
46
|
+
if [ -n "$(git status --porcelain docs/)" ]; then
|
|
47
|
+
echo "::error::Generated documentation is out of date. Please run 'make -C docs docs' and commit the changes."
|
|
48
|
+
echo ""
|
|
49
|
+
echo "The following files have uncommitted changes:"
|
|
50
|
+
git status --porcelain docs/
|
|
51
|
+
echo ""
|
|
52
|
+
echo "Diff:"
|
|
53
|
+
git diff docs/
|
|
54
|
+
exit 1
|
|
55
|
+
fi
|
|
56
|
+
echo "✅ Documentation is up to"
|
|
57
|
+
|
|
58
|
+
- name: Rdme Dry Run
|
|
59
|
+
env:
|
|
60
|
+
RDME_API_KEY: ${{ secrets.RDME_API_KEY }}
|
|
61
|
+
run: |
|
|
62
|
+
npm install -g rdme
|
|
63
|
+
rdme docs upload docs/src/_build/rdme/ --dry-run
|
|
64
|
+
|
|
65
|
+
lint:
|
|
66
|
+
name: Lint and Type Check
|
|
67
|
+
runs-on: ubuntu-latest
|
|
68
|
+
steps:
|
|
69
|
+
- name: Checkout code
|
|
70
|
+
uses: actions/checkout@v4
|
|
71
|
+
|
|
72
|
+
- name: Set up Python
|
|
73
|
+
uses: actions/setup-python@v5
|
|
74
|
+
with:
|
|
75
|
+
python-version: '3.10.6'
|
|
76
|
+
|
|
77
|
+
- name: Install uv
|
|
78
|
+
uses: astral-sh/setup-uv@v4
|
|
79
|
+
with:
|
|
80
|
+
version: latest
|
|
81
|
+
enable-cache: true
|
|
82
|
+
|
|
83
|
+
- name: Install dependencies
|
|
84
|
+
shell: bash
|
|
85
|
+
run: uv sync --group dev
|
|
86
|
+
|
|
87
|
+
- name: Run ruff linter
|
|
88
|
+
shell: bash
|
|
89
|
+
run: uv run ruff check .
|
|
90
|
+
|
|
91
|
+
- name: Run ruff formatter check
|
|
92
|
+
shell: bash
|
|
93
|
+
run: uv run ruff format --check .
|
|
94
|
+
|
|
95
|
+
- name: Run basedpyright type checker
|
|
96
|
+
shell: bash
|
|
97
|
+
run: uv run basedpyright
|
|
98
|
+
|
|
99
|
+
test:
|
|
100
|
+
name: Unit Tests
|
|
101
|
+
runs-on: ubuntu-latest
|
|
102
|
+
steps:
|
|
103
|
+
- name: Checkout code
|
|
104
|
+
uses: actions/checkout@v4
|
|
105
|
+
|
|
106
|
+
- name: Set up Python
|
|
107
|
+
uses: actions/setup-python@v5
|
|
108
|
+
with:
|
|
109
|
+
python-version: '3.10.6'
|
|
110
|
+
|
|
111
|
+
- name: Install uv
|
|
112
|
+
uses: astral-sh/setup-uv@v4
|
|
113
|
+
with:
|
|
114
|
+
version: latest
|
|
115
|
+
enable-cache: true
|
|
116
|
+
|
|
117
|
+
- name: Install dependencies
|
|
118
|
+
shell: bash
|
|
119
|
+
run: uv sync --group dev
|
|
120
|
+
|
|
121
|
+
- name: Run tests
|
|
122
|
+
run: uv run pytest tests/ -v
|
|
123
|
+
|
|
124
|
+
python-package:
|
|
125
|
+
name: Python Package
|
|
126
|
+
needs:
|
|
127
|
+
- lint
|
|
128
|
+
- test
|
|
129
|
+
runs-on: ubuntu-latest
|
|
130
|
+
permissions:
|
|
131
|
+
contents: read
|
|
132
|
+
packages: write
|
|
133
|
+
steps:
|
|
134
|
+
- name: Checkout code
|
|
135
|
+
uses: actions/checkout@v4
|
|
136
|
+
|
|
137
|
+
- name: Set up Python
|
|
138
|
+
uses: actions/setup-python@v5
|
|
139
|
+
with:
|
|
140
|
+
python-version: '3.10.6'
|
|
141
|
+
|
|
142
|
+
- name: Install uv
|
|
143
|
+
uses: astral-sh/setup-uv@v4
|
|
144
|
+
with:
|
|
145
|
+
version: latest
|
|
146
|
+
enable-cache: true
|
|
147
|
+
|
|
148
|
+
- name: Update version
|
|
149
|
+
shell: bash
|
|
150
|
+
if: inputs.version != ''
|
|
151
|
+
run: uv version ${{ inputs.version }}
|
|
152
|
+
|
|
153
|
+
- name: Build
|
|
154
|
+
shell: bash
|
|
155
|
+
run: |
|
|
156
|
+
uv build
|
|
157
|
+
|
|
158
|
+
- name: Upload build artifacts
|
|
159
|
+
uses: actions/upload-artifact@v4
|
|
160
|
+
with:
|
|
161
|
+
name: python-dist-v${{ inputs.version || 'dev' }}
|
|
162
|
+
path: dist/
|
|
163
|
+
retention-days: 90
|
|
164
|
+
|
|
165
|
+
|
|
166
|
+
build-binaries:
|
|
167
|
+
name: ${{ matrix.platform }} Binary
|
|
168
|
+
needs:
|
|
169
|
+
- lint
|
|
170
|
+
- test
|
|
171
|
+
runs-on: ${{ matrix.runner }}
|
|
172
|
+
strategy:
|
|
173
|
+
fail-fast: false
|
|
174
|
+
matrix:
|
|
175
|
+
include:
|
|
176
|
+
- runner: ubuntu22-2cpu-amd64
|
|
177
|
+
platform: linux-amd64
|
|
178
|
+
- runner: ubuntu22-2cpu-arm64
|
|
179
|
+
platform: linux-arm64
|
|
180
|
+
- runner: macos-latest
|
|
181
|
+
platform: macos-arm64
|
|
182
|
+
- runner: windows-latest
|
|
183
|
+
platform: windows
|
|
184
|
+
|
|
185
|
+
steps:
|
|
186
|
+
- name: Checkout code
|
|
187
|
+
uses: actions/checkout@v4
|
|
188
|
+
|
|
189
|
+
- name: Set up Python
|
|
190
|
+
uses: actions/setup-python@v5
|
|
191
|
+
with:
|
|
192
|
+
python-version: '3.10.6'
|
|
193
|
+
|
|
194
|
+
- name: Install uv
|
|
195
|
+
uses: astral-sh/setup-uv@v4
|
|
196
|
+
with:
|
|
197
|
+
version: latest
|
|
198
|
+
enable-cache: true
|
|
199
|
+
|
|
200
|
+
- name: Update version
|
|
201
|
+
shell: bash
|
|
202
|
+
if: inputs.version != ''
|
|
203
|
+
run: uv version ${{ inputs.version }}
|
|
204
|
+
|
|
205
|
+
- name: Install dependencies
|
|
206
|
+
shell: bash
|
|
207
|
+
run: uv sync --group build
|
|
208
|
+
|
|
209
|
+
- name: Build binary
|
|
210
|
+
shell: bash
|
|
211
|
+
run: |
|
|
212
|
+
uv run pyinstaller src/lumos/__main__.py --name lumos
|
|
213
|
+
VERSION="${{ inputs.version || 'dev' }}"
|
|
214
|
+
tar -czf lumos-${{ matrix.platform }}-v${VERSION}.tar.gz -C ./dist/lumos .
|
|
215
|
+
|
|
216
|
+
- name: Upload artifacts to workflow
|
|
217
|
+
uses: actions/upload-artifact@v4
|
|
218
|
+
with:
|
|
219
|
+
name: lumos-${{ matrix.platform }}-v${{ inputs.version || 'dev' }}
|
|
220
|
+
path: lumos-${{ matrix.platform }}-v${{ inputs.version || 'dev' }}.tar.gz
|
|
221
|
+
retention-days: 90
|
|
222
|
+
|
|
223
|
+
test-binaries:
|
|
224
|
+
name: Test ${{ matrix.platform }} Binary
|
|
225
|
+
needs: build-binaries
|
|
226
|
+
runs-on: ${{ matrix.runner }}
|
|
227
|
+
strategy:
|
|
228
|
+
fail-fast: false
|
|
229
|
+
matrix:
|
|
230
|
+
include:
|
|
231
|
+
- runner: ubuntu22-2cpu-amd64
|
|
232
|
+
platform: linux-amd64
|
|
233
|
+
- runner: ubuntu22-2cpu-arm64
|
|
234
|
+
platform: linux-arm64
|
|
235
|
+
- runner: macos-latest
|
|
236
|
+
platform: macos-arm64
|
|
237
|
+
- runner: windows-latest
|
|
238
|
+
platform: windows
|
|
239
|
+
|
|
240
|
+
steps:
|
|
241
|
+
- name: Download binary artifact
|
|
242
|
+
uses: actions/download-artifact@v4
|
|
243
|
+
with:
|
|
244
|
+
name: lumos-${{ matrix.platform }}-v${{ inputs.version || 'dev' }}
|
|
245
|
+
|
|
246
|
+
- name: Extract and test binary (Unix)
|
|
247
|
+
if: matrix.platform != 'windows'
|
|
248
|
+
shell: bash
|
|
249
|
+
run: |
|
|
250
|
+
tar -xzf lumos-${{ matrix.platform }}-v${{ inputs.version || 'dev' }}.tar.gz
|
|
251
|
+
chmod +x lumos
|
|
252
|
+
./lumos --version
|
|
253
|
+
|
|
254
|
+
- name: Extract and test binary (Windows)
|
|
255
|
+
if: matrix.platform == 'windows'
|
|
256
|
+
shell: pwsh
|
|
257
|
+
run: |
|
|
258
|
+
tar -xzf lumos-${{ matrix.platform }}-v${{ inputs.version || 'dev' }}.tar.gz
|
|
259
|
+
.\lumos.exe --version
|