diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 710504a0..b2e78c93 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -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 diff --git a/.github/workflows/upload.yaml b/.github/workflows/upload.yaml new file mode 100644 index 00000000..ee138c73 --- /dev/null +++ b/.github/workflows/upload.yaml @@ -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 \ No newline at end of file diff --git a/.template/app/README.md.tpl b/.template/app/README.md.tpl index 35ceb027..d3939ecc 100644 --- a/.template/app/README.md.tpl +++ b/.template/app/README.md.tpl @@ -1,6 +1,4 @@ -# {{ .APP }} - -build by jzero framework +# {{ .APP }}g ## Install Jzero Framework