diff --git a/.ci/package-mac.sh b/.ci/package-mac.sh index 59ade2e..0c2dcde 100644 --- a/.ci/package-mac.sh +++ b/.ci/package-mac.sh @@ -16,15 +16,16 @@ set -e # Modify the package with the solution from https://stackoverflow.com/a/11299907 # First, download the package and extract it wget https://github.com/rime/squirrel/releases/download/${SQUIRREL_VERSION}/Squirrel-${SQUIRREL_VERSION}.pkg -pushd package -xar -xf ../Squirrel-${SQUIRREL_VERSION}.pkg # Extract the application +mkdir package +pushd package +xar -xf ../Squirrel-${SQUIRREL_VERSION}.pkg cat Payload | gunzip -dc | cpio -i -pushd Squirrel.app/Contents # Remove all default rime schemas but keep opencc data and app config # Then, download the latest schemas we need and amend the `default.yaml` +pushd Squirrel.app/Contents GLOBIGNORE=SharedSupport/squirrel.yaml rm SharedSupport/*.* cp -rf "$SCHEMA_DIR/"* SharedSupport