-
Notifications
You must be signed in to change notification settings - Fork 0
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
1 parent
d2345c3
commit c4b0f0e
Showing
1 changed file
with
29 additions
and
27 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 |
---|---|---|
|
@@ -18,44 +18,46 @@ jobs: | |
- "SHA256:QZzH4mh9xO+ArIdKO+hiIYq54i5itfQN2PdZlvV+yok" | ||
- "SHA256:YqMJCA/aAJSLDZXC4ZJ0bhSIQfHo1dNtSYOj/pXBdrI" | ||
|
||
- jq/install | ||
- when: | ||
condition: << pipeline.trigger_parameters >> | ||
steps: | ||
- jq/install | ||
|
||
- run: | ||
name: Install Liquid | ||
command: sudo npm install liquidjs -g | ||
- run: | ||
name: Install Liquid | ||
command: sudo npm install liquidjs -g | ||
|
||
- run: | ||
name: Transform Formula Template | ||
command: | | ||
export REQUEST_BODY="<< pipeline.trigger_parameters.webhook.body >>" | ||
export WEBHOOK_VERSION=$($REQUEST_BODY | jq .version) | ||
- run: | ||
name: Transform Formula Template | ||
command: | | ||
export REQUEST_BODY="<< pipeline.trigger_parameters.webhook.body >>" | ||
export WEBHOOK_VERSION=$($REQUEST_BODY | jq .version) | ||
echo "Apply requested context to template:" | ||
echo $REQUEST_BODY | ||
echo "Apply requested context to template:" | ||
echo $REQUEST_BODY | ||
liquidjs --template @./Templates/parra-cli.rb.liquid --context $REQUEST_BODY --output ./Formula/parra-cli.rb | ||
liquidjs --template @./Templates/parra-cli.rb.liquid --context $REQUEST_BODY --output ./Formula/parra-cli.rb | ||
cat ./Formula/parra-cli.rb | ||
git config credential.helper 'cache --timeout=120' | ||
git config --global user.name "$GH_USER" | ||
git config --global user.email "$GH_EMAIL" | ||
cat ./Formula/parra-cli.rb | ||
git config credential.helper 'cache --timeout=120' | ||
git config --global user.name "$GH_USER" | ||
git config --global user.email "$GH_EMAIL" | ||
git add --all | ||
git commit --allow-empty -m "Parra CLI version $WEBHOOK_VERSION" | ||
git add --all | ||
git commit --allow-empty -m "Parra CLI version $WEBHOOK_VERSION" | ||
# Quiet push so key isn't shown in logs | ||
# git push -q [email protected]:Parra-Inc/tap.git main | ||
git push -q https://${TAPS_REPO_ACCESS_TOKEN}@github.com/Parra-Inc/tap.git main | ||
# Quiet push so key isn't shown in logs | ||
# git push -q [email protected]:Parra-Inc/tap.git main | ||
git push -q https://${TAPS_REPO_ACCESS_TOKEN}@github.com/Parra-Inc/tap.git main | ||
- slack/notify: | ||
channel: C06NY501UAX | ||
event: fail | ||
template: basic_fail_1 | ||
- slack/notify: | ||
channel: C06NY501UAX | ||
event: fail | ||
template: basic_fail_1 | ||
|
||
workflows: | ||
update-cli-formula-workflow: | ||
when: << pipeline.trigger_parameters >> | ||
jobs: | ||
- update-cli-formula: | ||
filters: | ||
|