supabase 1.17.7 → 1.18.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "supabase",
3
- "version": "1.17.7",
3
+ "version": "1.18.1",
4
4
  "description": "Supabase CLI",
5
5
  "repository": "supabase/cli",
6
6
  "homepage": "https://supabase.com/docs/reference/cli",
@@ -59,10 +59,11 @@ async function parsePackageJson() {
59
59
  }
60
60
 
61
61
  // We have validated the config. It exists in all its glory
62
- let binName = path.basename(packageJson.bin);
63
- const binPath = path.dirname(packageJson.bin);
64
- let url = packageJson.url;
65
- let version = packageJson.version;
62
+ const bin = packageJson.bin.toString();
63
+ const binName = path.basename(bin);
64
+ const binPath = path.dirname(bin);
65
+ let url = packageJson.url.toString();
66
+ let version = packageJson.version.toString();
66
67
 
67
68
  // strip the 'v' if necessary v0.0.1 => 0.0.1
68
69
  if (version[0] === "v") version = version.substr(1);
@@ -115,6 +116,13 @@ async function main() {
115
116
  await fs.promises.link(bin + ext, bin);
116
117
  }
117
118
 
119
+ // Copy binary because yarn runs as postinstall
120
+ if (process.env.npm_config_user_agent.startsWith("yarn/")) {
121
+ const bin = path.join(opts.binPath, opts.binName);
122
+ const link = path.join("..", ".bin", opts.binName);
123
+ await fs.promises.symlink(bin, link);
124
+ }
125
+
118
126
  // TODO: verify checksums
119
127
  console.info("Installed Supabase CLI successfully");
120
128
  }