action.yml 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. name: set variables
  2. description: set environment variables
  3. inputs:
  4. susfs:
  5. description: 'susfs'
  6. required: true
  7. branch:
  8. description: 'device kernel'
  9. required: true
  10. zeromount:
  11. description: 'zeromount'
  12. required: true
  13. nomount:
  14. description: 'nomount'
  15. required: true
  16. runs:
  17. using: composite
  18. steps:
  19. - name: set dependency directory variables
  20. shell: bash
  21. run: |
  22. ROOT="$GITHUB_WORKSPACE"
  23. if [[ ${{ inputs.susfs }} == 'true' ]]; then
  24. SUSFS4KSU="$ROOT/susfs4ksu"
  25. echo "SUSFS4KSU=$SUSFS4KSU" >> $GITHUB_ENV
  26. fi
  27. ANYKERNEL3="$ROOT/AnyKernel3"
  28. if [[ ${{ inputs.zeromount }} == 'true' ]]; then
  29. ZEROMOUNT="$ROOT/Super-Builders"
  30. echo "ZEROMOUNT=$ZEROMOUNT" >> $GITHUB_ENV
  31. fi
  32. if [[ ${{ inputs.nomount }} == 'true' ]]; then
  33. NOMOUNT="$ROOT/nomount"
  34. echo "NOMOUNT=$NOMOUNT" >> $GITHUB_ENV
  35. fi
  36. KERNEL_PATCHES="$ROOT/kernel_patches"
  37. echo "ROOT=$ROOT" >> $GITHUB_ENV
  38. echo "ANYKERNEL3=$ANYKERNEL3" >> $GITHUB_ENV
  39. echo "KERNEL_PATCHES=$KERNEL_PATCHES" >> $GITHUB_ENV
  40. - name: set common variable
  41. shell: bash
  42. run: |
  43. if [[ ${{ inputs.branch }} == SM-A546* || "${{ inputs.branch }}" == "SM-M146B-Oneui7-ADYJ2" || "${{ inputs.branch }}" == "SM-S908B-Oneui8-bitK" || "${{ inputs.branch }}" == "SM-X610-Oneui6.1.1-bit7" || "${{ inputs.branch }}" == "SM-A166B-Oneui7" ]]; then
  44. COMMON="$CONFIG"
  45. elif [[ "${{ inputs.branch }}" == "SM-A566B" || ${{ inputs.branch }} == SM-A055* ]]; then
  46. COMMON="$CONFIG/kernel-6.6"
  47. elif [[ ${{ inputs.branch }} == SM-S926B* || ${{ inputs.branch }} == SM-A556* ]]; then
  48. COMMON="$CONFIG/kernel"
  49. elif [[ "${{ inputs.branch }}" == "SM-A075M-Oneui7" ]]; then
  50. COMMON="$CONFIG/kernel-5.10"
  51. elif [[ "${{ inputs.branch }}" == "SM-X926B-Oneui6.1" ]]; then
  52. COMMON="$CONFIG/kernel-6.1"
  53. else
  54. COMMON="$CONFIG/kernel_platform/common"
  55. fi
  56. echo "COMMON=$COMMON" >> $GITHUB_ENV
  57. - name: set defconfig variable
  58. shell: bash
  59. run: |
  60. if [[ ${{ inputs.branch }} == SM-A546B* ]]; then
  61. GKI_DEFCONFIG="$COMMON/arch/arm64/configs/s5e8835-a54xnaxx_defconfig"
  62. elif [[ ${{ inputs.branch }} == SM-A546E* ]]; then
  63. GKI_DEFCONFIG="$COMMON/arch/arm64/configs/s5e8835-a54xnsxx_defconfig"
  64. elif [[ "${{ inputs.branch }}" == "SM-M146B-Oneui7-ADYJ2" ]]; then
  65. GKI_DEFCONFIG="$COMMON/arch/arm64/configs/s5e8535-m14xnsxx_defconfig"
  66. elif [[ "${{ inputs.branch }}" == "SM-S908B-Oneui8-bitK" ]]; then
  67. GKI_DEFCONFIG="$COMMON/arch/arm64/configs/s5e9925-b0sxxx_defconfig"
  68. elif [[ "${{ inputs.branch }}" == "SM-X610-Oneui6.1.1-bit7" ]]; then
  69. GKI_DEFCONFIG="$COMMON/arch/arm64/configs/s5e8835-gts9fepwifixx_defconfig"
  70. elif [[ "${{ inputs.branch }}" == "SM-A166B-Oneui7" ]]; then
  71. GKI_DEFCONFIG="$COMMON/arch/arm64/configs/s5e8535-a16xxx_defconfig"
  72. else
  73. GKI_DEFCONFIG="$COMMON/arch/arm64/configs/gki_defconfig"
  74. fi
  75. echo "GKI_DEFCONFIG=$GKI_DEFCONFIG" >> $GITHUB_ENV