Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
mickmaccallum committed Jul 30, 2024
1 parent d2345c3 commit c4b0f0e
Showing 1 changed file with 29 additions and 27 deletions.
56 changes: 29 additions & 27 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down

0 comments on commit c4b0f0e

Please sign in to comment.