@@ -98,18 +98,31 @@ export const TEMPLATES: TemplateEntry[] = [
9898 } ,
9999] ;
100100
101+ /** Human-friendly labels for skill repos, shown during install. */
102+ const SKILL_REPO_LABELS : Record < string , string > = {
103+ 'firecrawl/cli' : 'core firecrawl skills' ,
104+ 'firecrawl/skills' : 'skills to build with firecrawl' ,
105+ } ;
106+
107+ function skillRepoLabel ( repo : string ) : string {
108+ return SKILL_REPO_LABELS [ repo ] ?? repo ;
109+ }
110+
101111/**
102112 * Install one skill repo quietly. Captures `npx skills add` output instead of
103113 * inheriting it, so users see a single line per repo. Returns the number of
104114 * skills installed (parsed from the captured stdout), or null if unknown.
105115 *
106- * In a TTY, shows a transient "↓ <repo>" line that gets overwritten by
107- * "✓ <repo> (N skills)" on success. In a non-TTY, prints only the final line.
116+ * In a TTY, shows a transient "↓ Installing <label>..." line that gets
117+ * overwritten by "✓ <label> (N)" on success. In a non-TTY, prints only
118+ * the final line.
108119 */
109120async function installSkillRepoQuiet (
110121 repo : string ,
111122 options : InitOptions
112123) : Promise < number | null > {
124+ const label = skillRepoLabel ( repo ) ;
125+
113126 if ( hasNpx ( ) ) {
114127 const args = buildSkillsInstallArgs ( {
115128 repo,
@@ -121,28 +134,29 @@ async function installSkillRepoQuiet(
121134
122135 const isTty = process . stdout . isTTY ;
123136 if ( isTty ) {
124- process . stdout . write ( ` ${ dim } ↓ ${ repo } ${ reset } ` ) ;
137+ process . stdout . write ( ` ${ dim } ↓ Installing ${ label } ... ${ reset } ` ) ;
125138 }
126139 try {
127140 const stdout = execSync ( args . join ( ' ' ) , {
128141 stdio : [ 'ignore' , 'pipe' , 'pipe' ] ,
129142 env : cleanNpmEnv ( ) ,
130143 } ) ;
131144 const count = parseSkillCount ( stdout ?. toString ( ) ?? '' ) ;
132- const suffix = count != null ? ` ${ dim } (${ count } skills)${ reset } ` : '' ;
145+ const suffix = count != null ? ` ${ dim } (${ count } )${ reset } ` : '' ;
146+ const padding = ' ' . repeat ( 20 ) ; // clears any leftover "Installing..." text
133147 if ( isTty ) {
134148 process . stdout . write (
135- `\r ${ green } ✓${ reset } ${ repo } ${ suffix } \n`
149+ `\r ${ green } ✓${ reset } ${ label } ${ suffix } ${ padding } \n`
136150 ) ;
137151 } else {
138- console . log ( ` ${ green } ✓${ reset } ${ repo } ${ suffix } ` ) ;
152+ console . log ( ` ${ green } ✓${ reset } ${ label } ${ suffix } ` ) ;
139153 }
140154 return count ;
141155 } catch ( err ) {
142156 if ( isTty ) {
143- process . stdout . write ( `\r ${ dim } ✗${ reset } ${ repo } \n` ) ;
157+ process . stdout . write ( `\r ${ dim } ✗ ${ label } ${ ' ' . repeat ( 20 ) } ${ reset } \n` ) ;
144158 } else {
145- console . log ( ` ${ dim } ✗${ reset } ${ repo } ` ) ;
159+ console . log ( ` ${ dim } ✗${ reset } ${ label } ` ) ;
146160 }
147161 const stderr =
148162 err && typeof err === 'object' && 'stderr' in err
@@ -187,20 +201,27 @@ function printNextSteps(skillCount: number | null): void {
187201 console . log ( ` ${ summary } ` ) ;
188202 console . log ( '' ) ;
189203 console . log (
190- ` ${ arrow } ${ dim } Ask your AI:${ reset } "Use firecrawl to scrape pricing into JSON"`
204+ ` ${ dim } Connect & interact with the web ${ reset } ${ dim } (direct or in your AI agent):${ reset } `
205+ ) ;
206+ console . log (
207+ ` ${ arrow } ${ bold } Scrape${ reset } "Scrape the pricing page of stripe.com" ${ dim } firecrawl scrape https://stripe.com/pricing${ reset } `
208+ ) ;
209+ console . log (
210+ ` ${ arrow } ${ bold } Search${ reset } "Search for the latest stories in AI" ${ dim } firecrawl search "latest stories in AI"${ reset } `
191211 ) ;
192212 console . log (
193- ` ${ arrow } ${ dim } Run direct: ${ reset } ${ bold } firecrawl scrape ${ reset } https://example.com `
213+ ` ${ arrow } ${ bold } Interact ${ reset } "Extract the pricing tiers as JSON" ${ dim } firecrawl interact "extract pricing tiers as JSON" ${ reset } `
194214 ) ;
215+ console . log ( '' ) ;
195216 console . log (
196- ` ${ arrow } ${ dim } Add MCP: ${ reset } ${ bold } firecrawl setup mcp${ reset } `
217+ ` ${ arrow } ${ dim } Add MCP: ${ reset } ${ bold } firecrawl setup mcp${ reset } `
197218 ) ;
198219 console . log (
199220 ` ${ arrow } ${ dim } All commands:${ reset } ${ bold } firecrawl --help${ reset } `
200221 ) ;
201222 console . log ( '' ) ;
202223 console . log (
203- ` ${ dim } In your AI agent, just describe what you want to build or integrate.${ reset } `
224+ ` ${ dim } Building with firecrawl? Just describe what you want to build or integrate.${ reset } `
204225 ) ;
205226 console . log (
206227 ` ${ dim } Example:${ reset } ${ bold } "I want to use firecrawl to build an onboarding flow for my insurance company"${ reset } `
0 commit comments