import { defineCliConfig } from "sanity/cli";

const projectId =
  process.env.NEXT_PUBLIC_SANITY_PROJECT_ID && process.env.NEXT_PUBLIC_SANITY_PROJECT_ID.length > 0
    ? process.env.NEXT_PUBLIC_SANITY_PROJECT_ID
    : "placeholder";
const dataset =
  process.env.NEXT_PUBLIC_SANITY_DATASET && process.env.NEXT_PUBLIC_SANITY_DATASET.length > 0
    ? process.env.NEXT_PUBLIC_SANITY_DATASET
    : "production";

export default defineCliConfig({
  api: { projectId, dataset },
});
