jack1 codebase
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

50 lines
1.4KB

  1. name: Release tarball archive
  2. on:
  3. push:
  4. jobs:
  5. archive_source_code:
  6. name: Source Code Tarball
  7. runs-on: ubuntu-18.04
  8. env:
  9. ARCHIVE_BASENAME: jack1-${{ github.ref_name }}
  10. steps:
  11. - name: Checkout
  12. uses: actions/checkout@v2
  13. with:
  14. submodules: recursive
  15. - name: Dependencies setup
  16. run: |
  17. sudo apt-get update -qq
  18. sudo apt-get install -yqq python-pip
  19. sudo pip install git-archive-all
  20. - name: Archive source code
  21. shell: bash
  22. run: |
  23. cd "${GITHUB_WORKSPACE}"
  24. ./autogen.sh
  25. rm -rf autom4te.cache
  26. git-archive-all --prefix="${ARCHIVE_BASENAME}/" -9 "${{runner.workspace}}/${ARCHIVE_BASENAME}.tar.gz"
  27. - uses: actions/upload-artifact@v2
  28. with:
  29. name: Source code tarball
  30. path: ${{runner.workspace}}/${{env.ARCHIVE_BASENAME}}.tar.gz
  31. deploy:
  32. if: startsWith(github.ref, 'refs/tags/')
  33. runs-on: ubuntu-18.04
  34. needs:
  35. - archive_source_code
  36. steps:
  37. - uses: actions/download-artifact@v2
  38. with:
  39. name: Source code tarball
  40. - uses: softprops/action-gh-release@v1
  41. env:
  42. GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
  43. with:
  44. tag_name: ${{ github.ref_name }}
  45. name: Release ${{ github.ref_name }}
  46. draft: false
  47. prerelease: false
  48. files: |
  49. jack1-${{ github.ref_name }}.*