-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
14 additions
and
5,398 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -42,42 +42,34 @@ jobs: | |
- name: Install Python dependencies | ||
shell: bash -l {0} | ||
run: | | ||
python${{ matrix.python-version }} -m pip install --upgrade pip pip-tools pre-commit black | ||
python${{ matrix.python-version }} -m pip install --upgrade pip pip-tools black | ||
python${{ matrix.python-version }} -m pip install --user `grep numpy ${{ matrix.package }}/requirements/${{ matrix.os }}_py${{ matrix.python-version }}_extras.txt` | ||
python${{ matrix.python-version }} -m pip install --user -r ${{ matrix.package }}/requirements/${{ matrix.os }}_py${{ matrix.python-version }}_extras.txt | ||
env: | ||
CC: gcc-10 | ||
CXX: g++-10 | ||
|
||
- name: generate Enums | ||
id: enums | ||
shell: bash -l {0} | ||
if: matrix.package == 'emmet-core' | ||
continue-on-error: true | ||
run: | | ||
python${{ matrix.python-version }} emmet-core/emmet/core/qchem/calc_types/generate.py | ||
python${{ matrix.python-version }} emmet-core/emmet/core/vasp/calc_types/generate.py | ||
black emmet-core/emmet/core/*/calc_types/enums.py | ||
pre-commit run --all-files | ||
echo "count=$(git diff-index HEAD emmet-core/emmet/core/*/calc_types/enums.py | wc -l | xargs)" >> $GITHUB_OUTPUT | ||
echo "files=$(git ls-files --exclude-standard --others emmet-core/emmet/core/*/calc_types/enums.py | wc -l | xargs)" >> $GITHUB_OUTPUT | ||
- name: commit & push enums changes | ||
if: matrix.package == 'emmet-core' && (steps.enums.outputs.count > 0 || steps.enums.outputs.files > 0) | ||
shell: bash -l {0} | ||
run: | | ||
git config user.name github-actions | ||
git config user.email [email protected] | ||
git add emmet-core/emmet/core/*/calc_types/enums.py | ||
git commit --allow-empty -m "[automated commit] update calc type enums" | ||
git push | ||
# - name: Check Enum outputs | ||
# id: enums | ||
# shell: bash -l {0} | ||
# if: matrix.package == 'emmet-core' | ||
# run: | | ||
# echo "count=$(git diff-index HEAD emmet-core/emmet/core/*/calc_types/enums.py | wc -l | xargs)" >> $GITHUB_OUTPUT | ||
# echo "files=$(git ls-files --exclude-standard --others emmet-core/emmet/core/*/calc_types/enums.py | wc -l | xargs)" >> $GITHUB_OUTPUT | ||
# | ||
# - name: commit & push enums changes | ||
# if: matrix.package == 'emmet-core' | ||
# shell: bash -l {0} | ||
# run: | | ||
# git config user.name github-actions | ||
# git config user.email [email protected] | ||
# git add emmet-core/emmet/core/*/calc_types/enums.py | ||
# git commit --allow-empty -m "[automated commit] update calc type enums" | ||
# git push | ||
# | ||
# - name: Install editable emmet-core if needed | ||
# shell: bash -l {0} | ||
# if: matrix.package != 'emmet-core' | ||
|
Oops, something went wrong.