diff --git a/.changeset/brave-chairs-give.md b/.changeset/brave-chairs-give.md new file mode 100644 index 0000000000..a7845db712 --- /dev/null +++ b/.changeset/brave-chairs-give.md @@ -0,0 +1,5 @@ +--- +'@graphql-hive/cli': patch +--- + +Fix [: /bin: unexpected operator on POSIX diff --git a/patches/oclif@3.17.1.patch b/patches/oclif@3.17.1.patch index b7d4ee87d9..adc6e5dfb5 100644 --- a/patches/oclif@3.17.1.patch +++ b/patches/oclif@3.17.1.patch @@ -1,5 +1,5 @@ diff --git a/lib/tarballs/bin.js b/lib/tarballs/bin.js -index 8301c7be4c3101de9caf1c1b127cf1f940a1706c..402c146592628c6181576d01988e2f4e3bb654db 100644 +index 8301c7be4c3101de9caf1c1b127cf1f940a1706c..e7d955d29ce3d002a260ef7f4a1355fcdc95e018 100644 --- a/lib/tarballs/bin.js +++ b/lib/tarballs/bin.js @@ -7,85 +7,65 @@ const node_child_process_1 = require("node:child_process"); @@ -59,8 +59,8 @@ index 8301c7be4c3101de9caf1c1b127cf1f940a1706c..402c146592628c6181576d01988e2f4e SOURCE="\$( readlink "\$SOURCE" )" # If \$SOURCE was a relative symlink (so no "/" as prefix, need to resolve it relative to the symlink base directory - [[ \$SOURCE != /* ]] && SOURCE="\$DIR/\$SOURCE" -+ if [ "\$SOURCE" != /* ]; then -+ SOURCE="\$DIR/\$SOURCE" ++ if echo "\$SOURCE" | grep -q '^/*\$'; then ++ SOURCE="\$DIR/\$SOURCE" + fi done DIR="\$( cd -P "\$( dirname "\$SOURCE" )" && pwd )" diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 3cef040337..d2f5572492 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -51,7 +51,7 @@ patchedDependencies: hash: hxh4emx3aynf2jzsz5rahc4b4y path: patches/nextra@2.12.3.patch oclif@3.17.1: - hash: kht3qv63ahm725k3oatnyst5dm + hash: r7hloedkrpcouyrb6pxfskdz4e path: patches/oclif@3.17.1.patch importers: @@ -398,7 +398,7 @@ importers: version: 1.0.2 oclif: specifier: 3.17.1 - version: 3.17.1(patch_hash=kht3qv63ahm725k3oatnyst5dm)(@swc/core@1.3.85)(@types/node@18.17.17)(typescript@5.2.2) + version: 3.17.1(patch_hash=r7hloedkrpcouyrb6pxfskdz4e)(@swc/core@1.3.85)(@types/node@18.17.17)(typescript@5.2.2) rimraf: specifier: 4.4.1 version: 4.4.1 @@ -25527,7 +25527,7 @@ packages: resolution: {integrity: sha512-PX1wu0AmAdPqOL1mWhqmlOd8kOIZQwGZw6rh7uby9fTc5lhaOWFLX3I6R1hrF9k3zUY40e6igsLGkDXK92LJNg==} dev: true - /oclif@3.17.1(patch_hash=kht3qv63ahm725k3oatnyst5dm)(@swc/core@1.3.85)(@types/node@18.17.17)(typescript@5.2.2): + /oclif@3.17.1(patch_hash=r7hloedkrpcouyrb6pxfskdz4e)(@swc/core@1.3.85)(@types/node@18.17.17)(typescript@5.2.2): resolution: {integrity: sha512-qwop0W9s5nJJ9tTdLsYXxxvGSNc9xKjXccEAGCXM+x8NmGtZ4P89FwqDY4PIG7IeV9VNpYhZKQArpZNwPGn0CQ==} engines: {node: '>=12.0.0'} hasBin: true