fix copying non-head pantry

This commit is contained in:
Jacob Heider 2022-10-26 01:23:29 -04:00 committed by Max Howell
parent e828abd212
commit e0cfd65fe2

View file

@ -67,9 +67,12 @@ jobs:
- name: prepare pantries
run: |
tea --sync
cp -Rv $GITHUB_WORKSPACE/pantry/ /opt/tea.xyz/var/pantry || true
# ^^ || true because I cant figure out how to stop `cp` erroring
# because it doesnt want to copy symlinks that already exist, eg. `src`
find $GITHUB_WORKSPACE/pantry \
-not -type l \
-mindepth 1 \
-maxdepth 1 \
-print0 | \
xargs -0 -I{} cp -Rv {} /opt/tea.xyz/var/pantry
- run: pantry/scripts/sort.ts ${{ inputs.projects }}
id: sorted
@ -139,9 +142,14 @@ jobs:
prefix: ${{ github.workspace }}
- name: overlay this pantry
run: cp -Rv $GITHUB_WORKSPACE/pantry/ /opt/tea.xyz/var/pantry || true
# ^^ || true because I cant figure out how to stop `cp` erroring
# because it doesnt want to copy symlinks that already exist, eg. `src`
run: |
tea --sync
find $GITHUB_WORKSPACE/pantry \
-not -type l \
-mindepth 1 \
-maxdepth 1 \
-print0 | \
xargs -0 -I{} cp -Rv {} $GITHUB_WORKSPACE/tea.xyz/var/pantry
- uses: actions/download-artifact@v3
with: