-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* DEV: move iq-tree building into composite action * DEV: correctly specify composite action * DEV: specify shell to use * DEV: merge python setup and libiqtree fetching into composite action * DEV: ensure dependabot updates composite actions
- Loading branch information
Showing
5 changed files
with
96 additions
and
73 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 |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: Fetch or Build IQ-TREE 2 Static Library | ||
description: "Checks if the IQ-TREE 2 static library exists, if not then building it." | ||
inputs: | ||
os: | ||
description: "Runner OS Name." | ||
required: true | ||
outputs: | ||
iqtree2-sha: | ||
description: "SHA for commit of IQ-TREE 2 static library." | ||
value: ${{ steps.iqtree2-sha.outputs.iqtree2-sha }} | ||
runs: | ||
using: "composite" | ||
steps: | ||
- id: iqtree2-sha | ||
name: Get IQ-TREE 2 SHA | ||
shell: bash | ||
run: | | ||
cd iqtree2 | ||
IQ_TREE_2_SHA=$(git rev-parse HEAD) | ||
echo "iqtree2-sha=${IQ_TREE_2_SHA}" >> "$GITHUB_OUTPUT" | ||
- uses: actions/cache@v4 | ||
id: cache | ||
with: | ||
key: libiqtree-${{ inputs.os }}-${{ steps.iqtree2-sha.outputs.iqtree2-sha }} | ||
path: src/piqtree2/_libiqtree/libiqtree2.a | ||
lookup-only: true | ||
|
||
- name: Build IQ-TREE | ||
shell: bash | ||
if: steps.cache.outputs.cache-hit != 'true' | ||
run: | | ||
if [[ "${{ inputs.os }}" == "ubuntu-latest" ]]; then | ||
sudo ./build_tools/before_all_linux.sh | ||
else | ||
./build_tools/before_all_mac.sh | ||
fi |
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 |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: Setup piqtree | ||
description: "Setup Python and Fetch Static Library." | ||
inputs: | ||
python-version: | ||
description: "Python version." | ||
required: true | ||
cache-key: | ||
description: "Key for static library cache." | ||
required: true | ||
runs: | ||
using: "composite" | ||
steps: | ||
- uses: "actions/setup-python@v5" | ||
with: | ||
python-version: ${{ inputs.python-version }} | ||
|
||
- uses: actions/cache/restore@v4 | ||
with: | ||
key: ${{ inputs.cache-key }} | ||
path: src/piqtree2/_libiqtree/libiqtree2.a | ||
fail-on-cache-miss: true |
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
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
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