push git attributes first so the ci doesnt break
This commit is contained in:
@@ -139,17 +139,18 @@ jobs:
|
|||||||
owner="${repo_full%%/*}"
|
owner="${repo_full%%/*}"
|
||||||
repo="${repo_full##*/}"
|
repo="${repo_full##*/}"
|
||||||
api="$GITEA_API/repos/$owner/$repo"
|
api="$GITEA_API/repos/$owner/$repo"
|
||||||
echo "🔧 Syncing CI and .gitattributes to: $owner/$repo"
|
echo "🔧 Syncing .gitattributes and CI to: $owner/$repo"
|
||||||
|
|
||||||
default_branch=$(curl -sSL -H "Authorization: token ${{ secrets.TOKEN }}" "$api" | jq -r '.default_branch')
|
default_branch=$(curl -sSL -H "Authorization: token ${{ secrets.TOKEN }}" "$api" | jq -r '.default_branch')
|
||||||
|
|
||||||
for file in "$TEMPLATE_PATH" ".gitattributes"; do
|
# process .gitattributes first, then CI template
|
||||||
if [[ "$file" == "$TEMPLATE_PATH" ]]; then
|
for file in ".gitattributes" "$TEMPLATE_PATH"; do
|
||||||
content="${{ needs.fetch-template.outputs.template_b64 }}"
|
if [[ "$file" == ".gitattributes" ]]; then
|
||||||
msg="Update CI from skins-template"
|
|
||||||
else
|
|
||||||
content="${{ needs.fetch-template.outputs.gitattributes_b64 }}"
|
content="${{ needs.fetch-template.outputs.gitattributes_b64 }}"
|
||||||
msg="Update .gitattributes from skins-template"
|
msg="Update .gitattributes from skins-template"
|
||||||
|
else
|
||||||
|
content="${{ needs.fetch-template.outputs.template_b64 }}"
|
||||||
|
msg="Update CI from skins-template"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
url="$api/contents/$file"
|
url="$api/contents/$file"
|
||||||
|
|||||||
Reference in New Issue
Block a user