Skip to content

Commit

Permalink
Merge pull request #37 from jzero-io/feat/templates-update
Browse files Browse the repository at this point in the history
feat(jzero): update template
  • Loading branch information
jaronnie authored Jul 29, 2024
2 parents 1d8281d + 3ad5d31 commit 16322bf
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 22 deletions.
24 changes: 5 additions & 19 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,25 +37,11 @@ jobs:
go run main.go version
cd ../..
- name: Check for changes in the .template directory
id: changes
run: |
git fetch origin main
CHANGED_FILES=$(git diff --name-only origin/main HEAD)
echo "Changed files: $CHANGED_FILES"
if echo "$CHANGED_FILES" | grep -q '^.template'; then
echo ".template directory has changes."
echo "::set-output name=template_changed::true"
else
echo ".template directory has no changes."
echo "::set-output name=template_changed::false"
fi
- name: Upload project to examples repo
if: steps.changes.outputs.template_changed == 'true'
run: |
cd examples
git push
- name: Upload artifact
uses: actions/upload-artifact@v2
with:
name: examples-artifact
path: examples

- uses: actions/checkout@v2
- name: golangci-lint
Expand Down
24 changes: 24 additions & 0 deletions .github/workflows/upload.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: jzero-ci

on:
push:
branches:
- main
paths:
- '.template/**'

jobs:
golangci:
name: ci
runs-on: ubuntu-latest
steps:
- name: Download artifact
uses: actions/download-artifact@v2
with:
name: examples-artifact
path: examples

- name: Upload project to examples repo
run: |
cd examples
git push -f
4 changes: 1 addition & 3 deletions .template/app/README.md.tpl
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
# {{ .APP }}

build by jzero framework
# {{ .APP }}g

## Install Jzero Framework

Expand Down

0 comments on commit 16322bf

Please sign in to comment.