baoyu-post-to-x

Publishes text, images, videos, and Markdown articles to X via Chrome browser automation.

2|Updated May 30, 2026
One-click install
npx skills add https://github.com/virahitvin8/crafty-gis --skill baoyu-post-to-x-virahitvin8
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: baoyu-post-to-x
Source: https://github.com/virahitvin8/crafty-gis/tree/main/GIT_STAR/assignment-generator/antigravity-skills-main/antigravity-skills-main/skills/baoyu-post-to-x
Command: npx skills add https://github.com/virahitvin8/crafty-gis --skill baoyu-post-to-x-virahitvin8

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires baoyu-chrome-cdp, baoyu-md, front-matter, highlight.js, marked, remark-cjk-friendly, remark-parse, remark-stringify, unified, and includes scripts (resource) and references (resource) components.

What problem does it solve? Publishing content to X (Twitter) manually is repetitive, and X's anti-automation detection blocks standard tools like Playwright or Puppeteer. This Skill automates posting through a real Chrome browser using CDP, Chrome Computer Use, or the Codex Chrome plugin, while keeping the final publish action under user confirmation. ## Core Features & Use Cases - Regular Posts: Compose text posts with up to 4 images via clipboard copy and real paste keystrokes that bypass synthetic-event detection. - Video & Quote Posts: Attach MP4/MOV/WebM videos or quote existing tweets with comments through the browser UI. - X Articles: Convert Markdown (with frontmatter, images, Mermaid diagrams, and CJK support) to HTML and publish long-form articles, inserting images at placeholder positions via the editor's Insert > Media flow. - Use Case: A blogger writes a post in Markdown with local images and runs the article workflow; the Skill converts it, fills the X Articles editor in their logged-in Chrome, inserts each image, opens Preview, and waits for explicit confirmation before publishing. ## Quick Start Ask the agent to post "Hello from my blog!" with the image ./photo.png to X using Chrome.

Frequently Asked Questions about baoyu-post-to-x

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I post to X (Twitter) from the command line?

Run the x-browser.ts script with bun, passing the post text and optional --image flags for up to 4 images. It opens a real Chrome window with the content filled in so you can review and publish manually.

How do I publish a Markdown article to X Articles?

Convert the Markdown with md-to-html.ts, which extracts the title, cover image, and content images into placeholders, then use x-article.ts or the Chrome Computer Use flow to fill the X Articles editor. X Premium is required for Articles.

Why does X block Playwright or Puppeteer automation?

X detects synthetic input events and automation flags used by headless frameworks. This Skill launches real Chrome via CDP with a persistent profile and sends genuine paste keystrokes through osascript, xdotool, or PowerShell instead.

Does this work on Linux and Windows or only macOS?

It is cross-platform. Clipboard and paste operations use Swift/AppKit on macOS, wl-copy or xclip plus xdotool/ydotool on Linux, and PowerShell SendKeys on Windows.

What are the limitations of automated X posting?

First run requires manual login to save the session, videos are limited to 140 seconds without Premium, and the final Post or Publish click always requires explicit user confirmation. Image pasting on macOS needs Accessibility permission for the terminal.