Skip to content

Commit

Permalink
fix(gitlab-ci,github-actions/release): Fix Git submodules not include…
Browse files Browse the repository at this point in the history
…d in the release archive

Signed-off-by: 林博仁(Buo-ren Lin) <[email protected]>
  • Loading branch information
brlin-tw committed Oct 27, 2024
1 parent 9159f5e commit cc06f9d
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ jobs:
# WORKAROUND: Adding this option triggers actions/checkout#1467
#fetch-tags: true

# Also recursively fetch submodules
# WORKAROUND: Adding this option triggers actions/checkout#1959
#submodules: true

- name: >-
WORKAROUND: Fetch tags that points to the revisions
checked-out(actions/checkout#1467)
Expand All @@ -40,6 +44,13 @@ jobs:
--depth=100 \
--no-recurse-submodules
- name: >-
WORKAROUND: Checkout submodules recursively(actions/checkout#1959)
run: |-
git submodule update \
--init \
--recursive
- name: Determine the project identifier
run: printf "project_id=${GITHUB_REPOSITORY##*/}\\n" >> $GITHUB_ENV

Expand Down
3 changes: 3 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
#
# Copyright 2024 林博仁(Buo-ren Lin) <[email protected]>
# SPDX-License-Identifier: CC-BY-SA-4.0 OR LicenseRef-Apache-2.0-If-Not-Used-In-Template-Projects
variables:
GIT_SUBMODULE_STRATEGY: recursive

do-static-analysis:
stage: test
rules:
Expand Down

0 comments on commit cc06f9d

Please sign in to comment.