DEV Community

TEKNOSAKU.COM
TEKNOSAKU.COM

Posted on

Tekno-Framer CLI: From YouTube to Reels in Seconds

GitHub Copilot CLI Challenge Submission

This is a submission for the GitHub Copilot CLI Challenge

Tekno-Framer CLI: From YouTube to Reels in Seconds πŸš€

πŸ“± Project Repository: https://github.com/alannmaulanaa/tekno-framer-cli

What I Built

As a tech content creator (for my channel Tekno Saku), I face a daily struggle: Repurposing long-form YouTube videos into short-form content (Reels/TikTok) is boring and repetitive.

I built Tekno-Framer CLI, a terminal-based automation tool that acts as my personal video editor. It handles the heavy lifting using Node.js, FFmpeg, and AI.

Key Features:

  1. βœ‚οΈ Auto-Cropper: Automatically detects landscape videos (16:9) and crops them into vertical format (9:16) while keeping the center focus.
  2. πŸ—£οΈ AI Narration: Integrates with ElevenLabs API to generate professional AI voiceovers from text input directly in the terminal.
  3. 🎬 Smart Merge: Combines the cropped video with the generated AI audio into a final, ready-to-upload MP4 file.
  4. 🎨 Hacker UI: A beautiful, interactive terminal interface using inquirer, figlet, and gradient-string.

It turns a 30-minute editing task into a 30-second command line operation.

Demo

Here is the tool in action directly from my VS Code terminal:

1. The Interactive Menu

The CLI greets me with a cool banner and options to manage my workflow.

CLI Menu

2. Generating AI Voice & Processing Video

Using ElevenLabs integration to create narration and FFmpeg to crop the video simultaneously.

Processing Video

3. Success!

The video is rendered and ready to upload.

Success Output

My Experience with GitHub Copilot CLI

I am comfortable with Node.js, but FFmpeg commands are a nightmare to memorize. This is where GitHub Copilot CLI became my MVP teammate.

1. Decoding FFmpeg Complex Filters

I needed to crop a 1920x1080 video to 1080x1920 (9:16) centered. Usually, I would spend 20 minutes Googling the math.

I asked Copilot CLI:

"Write a fluent-ffmpeg command to crop a video to 9:16 aspect ratio, keeping the center part."

Copilot generated:


javascript
.outputOptions(['-vf', 'crop=ih*(9/16):ih'])
It worked instantly! It understood the math (ih = input height) better than I did.

2. Debugging API Integration (The "401" Error)
During the development, I struggled with the ElevenLabs API returning 401 Unauthorized errors. I pasted the error log into Copilot CLI.

I asked Copilot CLI:

"I keep getting 401 Unauthorized from this Axios request. How do I properly pass the xi-api-key header?"

Copilot immediately pointed out that I was passing the key in the wrong object depth and suggested the correct header structure. It even reminded me to check if my API key was hardcoded or in .env.

3. Modernizing the Codebase (ESM Migration)
I started the project using CommonJS (require), but some libraries like ora and inquirer forced me to switch to ES Modules (import). This caused a lot of require is not defined errors.

Copilot CLI guided me through updating package.json with "type": "module" and refactoring my imports across all files automatically.

Conclusion
Building Tekno-Framer with GitHub Copilot CLI felt like pair-programming with a senior engineer who has memorized every documentation page. It allowed me to focus on the logic and creativity (making content for Tekno Saku) rather than getting stuck on syntax errors.
Enter fullscreen mode Exit fullscreen mode

Top comments (1)

Collapse
 
alan_maulanaibrahim_e18c_8 profile image
TEKNOSAKU.COM

wish me luck