Skip to content

feat: templates now generates artifacts based on component name (#44) #44

feat: templates now generates artifacts based on component name (#44)

feat: templates now generates artifacts based on component name (#44) #44

# This workflow archives the templates from the git hub repository
name: Archive
on:
# Triggers the workflow on push events but only for the main branch
push:
branches: [ main ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
archive:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Archive the templates
run: |
mkdir ~/archived-templates
# Archive Java templates
cd templates/java
zip -r ~/archived-templates/HelloWorld-java.zip HelloWorld
zip -r ~/archived-templates/LocalPubSub-java.zip LocalPubSub
zip -r ~/archived-templates/TestingFramework-java.zip TestingFramework
zip -r ~/archived-templates/TestTemplateForCLI.zip TestTemplateForCLI
# Archive Python templates
cd ../python
zip -r ~/archived-templates/HelloWorld-python.zip HelloWorld
zip -r ~/archived-templates/LocalPubSub-python.zip LocalPubSub
- name: Upload zipped artifacts
uses: actions/[email protected]
with:
name: archived-templates
path: ~/archived-templates/*.zip
- name: Download uploaded artifacts
id: download
uses: actions/[email protected]
with:
path: ~/download/
- name: Release
id: upload-release-asset
uses: softprops/action-gh-release@v1
with:
files: ${{steps.download.outputs.download-path}}/archived-templates/*.zip
tag_name: v1.0