install-dt

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Install the Dovetail CLI (
dt
)

安装Dovetail CLI(
dt

Installs
dt
, the Dovetail command-line tool for importing content from Notion, Confluence, Google Drive, Airtable, Marvin, Condens, EnjoyHQ, Productboard, local files, and more.
本工具用于安装Dovetail命令行工具
dt
,支持从Notion、Confluence、Google Drive、Airtable、Marvin、Condens、EnjoyHQ、Productboard、本地文件等多种来源导入内容。

Installation

安装

Option 1: Global install via npm (recommended)

选项1:通过npm全局安装(推荐)

bash
npm install -g @heydovetail/dt
Verify:
bash
dt --version
bash
npm install -g @heydovetail/dt
验证安装:
bash
dt --version

Option 2: One-off use via npx

选项2:通过npx单次使用

bash
npx @heydovetail/dt <command>
Use this in CI/CD or when a global install is not possible.
bash
npx @heydovetail/dt <command>
适合在CI/CD场景或无法进行全局安装时使用。

Initial setup

初始设置

After installing, run the setup wizard to connect your Dovetail workspace:
bash
export DOVETAIL_API_KEY="your-api-key"  # from your workspace Settings > API
dt init
dt init
configures your workspace URL and API key, then walks you through adding your first data source.
Run a health check at any time:
bash
dt doctor
安装完成后,运行设置向导连接你的Dovetail工作区:
bash
export DOVETAIL_API_KEY="your-api-key"  # 可在工作区设置 > API页面获取
dt init
dt init
会配置你的工作区URL和API密钥,随后引导你添加首个数据源。
你可随时运行健康检查命令:
bash
dt doctor

When to use

适用场景

  • Before running any
    dt
    commands for the first time
  • When setting up a new machine or CI environment
  • Use global install when
    dt
    will be called repeatedly
  • Use npx for one-off or ephemeral environments
  • 首次运行任意
    dt
    命令前
  • 配置新机器或CI环境时
  • 需要频繁调用
    dt
    时选择全局安装
  • 单次使用或临时环境下使用npx

Troubleshooting

故障排查

IssueFix
command not found: dt
after global install
Run
npm config get prefix
and ensure
<prefix>/bin
is on your
PATH
Permission denied during global installUse
sudo npm install -g @heydovetail/dt
or configure a user-writable npm prefix
dt doctor
reports connectivity errors
Confirm
DOVETAIL_API_KEY
is set and your workspace URL is correct in
dt.json
问题解决方案
全局安装后提示
command not found: dt
运行
npm config get prefix
,确认
<prefix>/bin
已加入你的
PATH
环境变量
全局安装时提示权限不足使用
sudo npm install -g @heydovetail/dt
命令,或配置用户可写的npm前缀
dt doctor
报告连接错误
确认
DOVETAIL_API_KEY
已正确设置,且
dt.json
中的工作区URL无误