release-cmake.yml 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. name: Release
  2. on:
  3. push:
  4. tags:
  5. - boost-*
  6. jobs:
  7. release-posix-cmake:
  8. runs-on: ubuntu-latest
  9. steps:
  10. - uses: actions/checkout@v4
  11. with:
  12. path: ${{ github.ref_name }}
  13. submodules: true
  14. - name: Cleanup
  15. shell: bash
  16. run: |
  17. find ${{ github.ref_name }} -name ".git" -prune -exec rm -rf {} +
  18. - name: Create archives
  19. run: |
  20. tar -czf ${{ github.ref_name }}-cmake.tar.gz ${{ github.ref_name }}
  21. tar -cJf ${{ github.ref_name }}-cmake.tar.xz ${{ github.ref_name }}
  22. - uses: softprops/action-gh-release@v1
  23. with:
  24. files: |
  25. ${{ github.ref_name }}-cmake.tar.gz
  26. ${{ github.ref_name }}-cmake.tar.xz
  27. release-windows-cmake:
  28. runs-on: windows-latest
  29. needs: release-posix-cmake
  30. steps:
  31. - uses: actions/checkout@v4
  32. with:
  33. path: ${{ github.ref_name }}
  34. submodules: true
  35. - name: Cleanup
  36. shell: bash
  37. run: |
  38. find ${{ github.ref_name }} -name ".git" -prune -exec rm -rf {} +
  39. - name: Create archives
  40. shell: cmd
  41. run: |
  42. 7z a ${{ github.ref_name }}-cmake.zip ${{ github.ref_name }}
  43. 7z a ${{ github.ref_name }}-cmake.7z ${{ github.ref_name }}
  44. - uses: softprops/action-gh-release@v1
  45. with:
  46. files: |
  47. ${{ github.ref_name }}-cmake.zip
  48. ${{ github.ref_name }}-cmake.7z
  49. release-posix-b2-nodocs:
  50. runs-on: ubuntu-latest
  51. needs: release-windows-cmake
  52. steps:
  53. - uses: actions/checkout@v4
  54. with:
  55. path: ${{ github.ref_name }}
  56. submodules: true
  57. - name: Cleanup
  58. shell: bash
  59. run: |
  60. find ${{ github.ref_name }} -name ".git" -prune -exec rm -rf {} +
  61. - name: Move headers
  62. shell: bash
  63. run: |
  64. cd ${{ github.ref_name }}
  65. cp -r libs/*/include/boost libs/numeric/*/include/boost .
  66. rm -rf libs/*/include libs/numeric/*/include
  67. rm -f CMakeLists.txt
  68. - name: Create archives
  69. run: |
  70. tar -czf ${{ github.ref_name }}-b2-nodocs.tar.gz ${{ github.ref_name }}
  71. tar -cJf ${{ github.ref_name }}-b2-nodocs.tar.xz ${{ github.ref_name }}
  72. - uses: softprops/action-gh-release@v1
  73. with:
  74. files: |
  75. ${{ github.ref_name }}-b2-nodocs.tar.gz
  76. ${{ github.ref_name }}-b2-nodocs.tar.xz
  77. release-windows-b2-nodocs:
  78. runs-on: windows-latest
  79. needs: release-posix-b2-nodocs
  80. steps:
  81. - uses: actions/checkout@v4
  82. with:
  83. path: ${{ github.ref_name }}
  84. submodules: true
  85. - name: Cleanup
  86. shell: bash
  87. run: |
  88. find ${{ github.ref_name }} -name ".git" -prune -exec rm -rf {} +
  89. - name: Move headers
  90. shell: bash
  91. run: |
  92. cd ${{ github.ref_name }}
  93. cp -r libs/*/include/boost libs/numeric/*/include/boost .
  94. rm -rf libs/*/include libs/numeric/*/include
  95. rm -f CMakeLists.txt
  96. - name: Create archives
  97. shell: cmd
  98. run: |
  99. 7z a ${{ github.ref_name }}-b2-nodocs.zip ${{ github.ref_name }}
  100. 7z a ${{ github.ref_name }}-b2-nodocs.7z ${{ github.ref_name }}
  101. - uses: softprops/action-gh-release@v1
  102. with:
  103. files: |
  104. ${{ github.ref_name }}-b2-nodocs.zip
  105. ${{ github.ref_name }}-b2-nodocs.7z
粤ICP备19079148号