|
1 | 1 | name: "Copilot Setup Steps" |
2 | 2 |
|
3 | | -# Automatically run the setup steps when they are changed to allow for easy validation, |
4 | | -# and allow manual testing through the repository's "Actions" tab |
| 3 | +# Workflow for GitHub Copilot Workspace to prepare TNFR development environment |
5 | 4 | on: |
6 | 5 | workflow_dispatch: |
7 | 6 | push: |
|
12 | 11 | - .github/workflows/copilot-setup-steps.yml |
13 | 12 |
|
14 | 13 | jobs: |
15 | | - # The job MUST be called `copilot-setup-steps` or it will not be picked up by Copilot. |
| 14 | + # The job MUST be called `copilot-setup-steps` for GitHub Copilot Workspace |
16 | 15 | copilot-setup-steps: |
17 | 16 | runs-on: ubuntu-latest |
18 | | - |
19 | | - # Set the permissions needed for Copilot operations |
20 | | - # Copilot will be given its own token for its operations. |
| 17 | + |
21 | 18 | permissions: |
22 | | - # Required for actions/checkout - Copilot needs to access the repository |
23 | 19 | contents: read |
24 | | - # Required for Copilot to interact with Actions |
25 | | - actions: read |
26 | | - # Required for Copilot to read metadata |
27 | | - metadata: read |
28 | 20 |
|
29 | | - # Configure the environment for TNFR development |
30 | | - # Purpose: Enable exploration, study, investigation, and development of TNFR |
31 | | - # (Resonant Fractal Nature Theory - modeling coherent patterns through resonance) |
32 | 21 | steps: |
33 | | - - name: Checkout TNFR repository |
34 | | - uses: actions/checkout@v5 |
35 | | - |
36 | | - - name: Clean Python bytecode cache |
37 | | - run: | |
38 | | - find . -type d -name __pycache__ -exec rm -rf {} + 2>/dev/null || true |
39 | | - find . -type f -name "*.pyc" -delete 2>/dev/null || true |
| 22 | + - name: Checkout repository |
| 23 | + uses: actions/checkout@v4 |
40 | 24 |
|
41 | 25 | - name: Set up Python |
42 | | - uses: actions/setup-python@v6 |
| 26 | + uses: actions/setup-python@v5 |
43 | 27 | with: |
44 | | - # Using Python 3.11 - the primary version for TNFR development and CI |
45 | 28 | python-version: "3.11" |
46 | 29 | cache: "pip" |
47 | 30 |
|
48 | | - - name: Install TNFR dependencies |
| 31 | + - name: Install dependencies |
49 | 32 | run: | |
50 | 33 | python -m pip install --upgrade pip |
51 | | - # Install TNFR directly from repository source code (NOT from PyPI) |
52 | | - # Using editable mode (-e) to work with the latest development version |
53 | | - python -m pip install -e .[test,numpy,yaml,orjson] |
| 34 | + pip install -e .[test,numpy,yaml,orjson] |
54 | 35 |
|
55 | | - - name: Verify TNFR installation |
| 36 | + - name: Verify installation |
56 | 37 | run: | |
57 | | - # Verify the TNFR package is properly installed from repo (not PyPI) |
58 | | - python -c "import tnfr; print(f'✓ TNFR version: {tnfr.__version__}')" |
59 | | - # Verify core modules are accessible |
60 | | - python -c "from tnfr.operators import Emission, Coherence, Resonance; print('✓ Core operators')" |
61 | | - python -c "from tnfr.metrics.coherence import compute_global_coherence; print('✓ Metrics')" |
62 | | - echo "✓ TNFR environment ready for Copilot" |
| 38 | + python -c "import tnfr; print(f'TNFR v{tnfr.__version__} ready')" |
0 commit comments