|
13 | 13 | permissions: {} |
14 | 14 |
|
15 | 15 | jobs: |
16 | | - pre-list-legacy: |
17 | | - strategy: |
18 | | - matrix: |
19 | | - python: |
20 | | - - "3.9" |
21 | | - |
22 | | - runs-on: ubuntu-latest |
23 | | - |
24 | | - steps: |
25 | | - - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 |
26 | | - with: |
27 | | - persist-credentials: false |
28 | | - |
29 | | - - uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0 |
30 | | - with: |
31 | | - # NOTE: matrix.python is intentionally not used here. |
32 | | - python-version: "3.x" |
33 | | - |
34 | | - - name: support deps |
35 | | - run: make dev INSTALL_EXTRA=support |
36 | | - |
37 | | - - name: build pre-list |
38 | | - env: |
39 | | - LISTGEN_PYTHON_VERSION: "${{ matrix.python }}" |
40 | | - run: | |
41 | | - ./env/bin/python ./support/fetch-sphinx.py "${LISTGEN_PYTHON_VERSION}" > pre-list.txt |
42 | | -
|
43 | | - - name: upload pre-list |
44 | | - uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0 |
45 | | - with: |
46 | | - name: pre-list-${{ matrix.python }} |
47 | | - path: pre-list.txt |
48 | | - |
49 | | - expand-list-legacy: |
50 | | - needs: pre-list-legacy |
51 | | - strategy: |
52 | | - matrix: |
53 | | - python: |
54 | | - # - "3.7" # EOL |
55 | | - # - "3.8" # EOL |
56 | | - - "3.9" |
57 | | - |
58 | | - runs-on: ubuntu-latest |
59 | | - |
60 | | - steps: |
61 | | - - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 |
62 | | - with: |
63 | | - persist-credentials: false |
64 | | - |
65 | | - - uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0 |
66 | | - with: |
67 | | - python-version: ${{ matrix.python }} |
68 | | - |
69 | | - - uses: actions/download-artifact@018cc2cf5baa6db3ef3c5f8a56943fffe632ef53 # v6.0.0 |
70 | | - with: |
71 | | - name: pre-list-${{ matrix.python }} |
72 | | - |
73 | | - - name: walk modules |
74 | | - env: |
75 | | - LISTGEN_PYTHON_VERSION: ${{ matrix.python }} |
76 | | - LISTGEN_DRY_RUN: ${{ inputs.dry-run }} |
77 | | - run: | |
78 | | - python ./support/walk-modules.py "${LISTGEN_PYTHON_VERSION}.txt" < pre-list.txt |
79 | | - rm pre-list.txt |
80 | | -
|
81 | | - if [[ -f "./stdlib_list/lists/"${LISTGEN_PYTHON_VERSION}.txt"" ]]; then |
82 | | - sort -u -o ./stdlib_list/lists/"${LISTGEN_PYTHON_VERSION}.txt" \ |
83 | | - ./stdlib_list/lists/"${LISTGEN_PYTHON_VERSION}.txt" \ |
84 | | - "${LISTGEN_PYTHON_VERSION}.txt" |
85 | | - else |
86 | | - sort -u -o ./stdlib_list/lists/"${LISTGEN_PYTHON_VERSION}.txt" \ |
87 | | - "${LISTGEN_PYTHON_VERSION}.txt" |
88 | | - fi |
89 | | -
|
90 | | - rm "${LISTGEN_PYTHON_VERSION}.txt" |
91 | | -
|
92 | | - if [[ "${LISTGEN_DRY_RUN}" == "true" ]]; then |
93 | | - git diff |
94 | | - fi |
95 | | -
|
96 | | - - name: create PR |
97 | | - if: ${{ !inputs.dry-run }} |
98 | | - uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e # v7.0.8 |
99 | | - with: |
100 | | - commit-message: "[BOT] update list for ${{ matrix.python }}" |
101 | | - branch: update-stdlib-list-${{ matrix.python }} |
102 | | - base: main |
103 | | - branch-suffix: timestamp |
104 | | - title: "[BOT] update list for ${{ matrix.python }}" |
105 | | - body: | |
106 | | - This is an automated pull request, updating `${{ matrix.python }}.txt` after a detected change. |
107 | | -
|
108 | | - Please review manually before merging. |
109 | | - assignees: "woodruffw" |
110 | | - reviewers: "woodruffw" |
111 | | - |
112 | 16 | expand-list: |
113 | 17 | strategy: |
114 | 18 | matrix: |
|
0 commit comments