From 1508e4e1976e6ebc1ad99371bf049616dd4c16b8 Mon Sep 17 00:00:00 2001 From: Spoffy Date: Mon, 8 Jul 2024 14:24:56 +0100 Subject: [PATCH] Fixes OSS including EE by providing empty ext dir --- .github/workflows/docker_latest.yml | 4 ++-- buildtools/checkout-ext-directory.sh | 1 + ext/.gitignore | 4 ++++ ext/README.md | 5 +++++ 4 files changed, 12 insertions(+), 2 deletions(-) create mode 100644 ext/.gitignore create mode 100644 ext/README.md diff --git a/.github/workflows/docker_latest.yml b/.github/workflows/docker_latest.yml index b3adb7ef98e..d72682cf8fc 100644 --- a/.github/workflows/docker_latest.yml +++ b/.github/workflows/docker_latest.yml @@ -87,7 +87,7 @@ jobs: load: true tags: ${{ env.DOCKER_HUB_OWNER }}/${{ matrix.image.name }}:${{ env.TAG }} cache-from: type=gha - build-contexts: ${{ matrix.image.name != 'grist-oss' && 'ext=ext' || '' }} + build-contexts: ext=ext - name: Use Node.js ${{ matrix.node-version }} for testing if: ${{ !inputs.disable_tests }} @@ -140,7 +140,7 @@ jobs: tags: ${{ env.DOCKER_HUB_OWNER }}/${{ matrix.image.name }}:${{ env.TAG }} cache-from: type=gha cache-to: type=gha,mode=max - build-contexts: ${{ matrix.image.name != 'grist-oss' && 'ext=ext' || '' }} + build-contexts: ext=ext - name: Push Enterprise to Docker Hub if: ${{ matrix.image.name == 'grist' }} diff --git a/buildtools/checkout-ext-directory.sh b/buildtools/checkout-ext-directory.sh index 6861b9e2b30..81753e31405 100755 --- a/buildtools/checkout-ext-directory.sh +++ b/buildtools/checkout-ext-directory.sh @@ -14,5 +14,6 @@ pushd $repo git sparse-checkout set ext git checkout popd +rm -rf ./ext mv $repo/ext . rm -rf $repo diff --git a/ext/.gitignore b/ext/.gitignore new file mode 100644 index 00000000000..cfe35849b8c --- /dev/null +++ b/ext/.gitignore @@ -0,0 +1,4 @@ +**/* + +!.gitignore +!README.md \ No newline at end of file diff --git a/ext/README.md b/ext/README.md new file mode 100644 index 00000000000..60101bedead --- /dev/null +++ b/ext/README.md @@ -0,0 +1,5 @@ +`ext` is a directory that allows derivatives of Grist core to be created, without modifying any of the base files. + +Files placed in here should be new files, or replacing files in the `stubs` directory. + +When compiling, Typescript resolves files in `ext` before files in `stubs`, using the `ext` file instead (if it exists). \ No newline at end of file