guide
How to Auto-Post GitHub Commits to X/Twitter (3 Ways Compared)
Stop manually tweeting your commits. GitHub Actions, custom bots, and hosted tools compared — with setup steps, costs, and what each looks like in your feed.
If you're building in public, you already know the drill: ship something, open X, try to remember what you actually did today, write a tweet about it, post it, repeat tomorrow. Miss a day and the streak — and the habit — quietly dies. The fix everyone reaches for eventually is the same one: stop manually tweeting commits and let something else turn git push into a post.
There are three genuinely different ways to do that. None of them is a scam or a trap — each one is a real trade-off between control, effort, and how good the result looks in your followers' feed. Here's an honest comparison of all three, including where each one falls apart.
Option 1: GitHub Actions + a tweet action
This is the first thing most developers try, because it lives right where you already work. GitHub Actions can run on a schedule (cron), read your repo's commit history for the day, and hand the text off to a small script or an existing "post to X" action from the Marketplace.
A minimal version looks something like this:
name: tweet-daily-commits
on:
schedule:
- cron: "30 8 * * *" # 08:30 UTC daily
workflow_dispatch: {}
jobs:
post:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Collect today's commits
id: commits
run: |
MSG=$(git log --since="24 hours ago" --pretty=format:"- %s" | head -20)
echo "log<<EOF" >> "$GITHUB_OUTPUT"
echo "$MSG" >> "$GITHUB_OUTPUT"
echo "EOF" >> "$GITHUB_OUTPUT"
- name: Post to X
if: steps.commits.outputs.log != ''
uses: nearform-actions/github-action-post-tweet@v1
with:
status: |
Shipped today:
${{ steps.commits.outputs.log }}
env:
TWITTER_CONSUMER_API_KEY: ${{ secrets.X_API_KEY }}
TWITTER_CONSUMER_API_SECRET: ${{ secrets.X_API_SECRET }}
TWITTER_ACCESS_TOKEN: ${{ secrets.X_ACCESS_TOKEN }}
TWITTER_ACCESS_TOKEN_SECRET: ${{ secrets.X_ACCESS_TOKEN_SECRET }}Before this runs at all, you need X API developer access: a developer account on the X developer portal, an app inside it, and generated keys with write permission for the account you want to post from. That part alone can take longer than writing the workflow — X reviews applications, and posting write access at any real daily volume sits behind a paid API tier, not the free one. Budget for that before you budget any engineering time.
Once it's running, the workflow is genuinely low-maintenance — until it isn't. The failure modes are the boring kind: a secret expires, the Marketplace action you depend on gets abandoned or changes its interface, X tweaks a rate limit, or your cron fires during a day with zero commits and posts an empty or malformed tweet. You'll only find out when you check the Actions tab or a follower asks why you tweeted nothing.
The bigger issue is what actually gets posted. git log output is written for other engineers, not for your audience. "fix null check in useAuth" or "wip refactor pass 2" means something to you and nothing to a founder deciding whether to try your product. Raw commit messages, straight to a public feed, is the default outcome of this approach unless you add formatting logic yourself.
Best for:hobbyist projects, weekend tinkering, or developers who want full ownership of a simple pipeline and don't mind raw output or occasional silent failures.
Option 2: Write your own bot
The natural next step once Actions feels limiting is to write a proper script: a cron job (on a VPS, a serverless function, wherever) that calls the GitHub API for commits and the X API v2 to post them. This gets you full control — you decide exactly how commits are fetched, filtered, formatted, and scheduled, with no Marketplace action in the middle.
That control comes with a list of things you now own:
- OAuth token refresh. X access tokens expire in hours, not days. Your script needs a refresh flow that runs reliably, or it silently stops posting until you notice.
- Rate limits. The X API enforces per-window limits on both reads and writes. A retry-without-backoff bug can burn through your quota and lock you out for the rest of the window.
- Media upload.If you want an image attached (a stat card, a screenshot, anything more than plain text), that's a separate upload endpoint with its own auth and size limits to handle correctly.
- Formatting the message.Same problem as Option 1 — nothing formats raw commit messages for you. You'll write that logic yourself, and you'll be the one maintaining it as your commit style changes.
- Uptime. A cron job on a server you manage is another thing that can go down, run out of disk, or get orphaned when you switch hosting providers.
None of this is hard individually. Together, it's a small internal tool you now maintain indefinitely, for a task that's adjacent to — not part of — the product you're actually trying to ship.
Best for:developers who want complete customization (custom formatting rules, unusual posting logic, integration with other internal tools) and are fine treating "post my commits" as its own small piece of infrastructure.
Option 3: A hosted tool (like gittomarket)
The third option is to hand the whole pipeline to a service built specifically for this. gittomarket connects to your GitHub repo and your X account, and each morning renders a designed stat card covering the previous day's commits — not a raw commit dump — and posts it automatically. Captions are written for your audience rather than pulled straight from git log, and days with zero commits are skipped automatically, so your feed never shows an empty or fabricated update.
Compared to the two DIY routes:
- No X API keys of your own.You don't need a developer account, an approved app, or a paid API tier — posting is included in the subscription.
- Designed output, not raw text. Stat cards and captions are built to be readable by customers and non-engineers, not just other developers scanning a commit log.
- Multi-platform. The same daily update can go to X, LinkedIn, and Bluesky, instead of you writing separate posting logic for each.
- Approval or full auto. You can review each post in Telegram before it goes out, or let it run entirely hands-off.
- Beyond the post. gittomarket also generates a build page with a waitlist and auto-written SEO articles, reachable at
gittomarket.io/w/your-slugor your own domain, plus ag2xCLI and an MCP server if you want to script parts of it yourself.
The honest trade-off: you give up some control. You're not editing a YAML file or a script — you're working within a product's settings. And it's a subscription, not a one-time setup. gittomarket's free plan includes 10 auto-posts a month plus a 14-day trial of the full Pro plan with no card required; Pro is $29/month, and the first 20 founding-beta seats are $9/month forever.
Best for: anyone who wants consistent, audience-readable posts with zero ongoing maintenance — and who would rather spend the next hour shipping than debugging a cron job.
It's also worth noting: gittomarket reads only your commit counts and commit messages, never your code's contents, which matters if you're weighing this against a bot you'd run yourself with full repo access anyway.
Which one should you actually use?
If you like tinkering and this is a side project you're not trying to keep running for months, GitHub Actions is the cheapest way to try it. If you need very specific formatting or posting logic that no tool will offer as a setting, writing your own bot gives you that — at the cost of owning it forever. If what you actually want is a daily post that looks good, reads well to non-engineers, and never needs your attention, a hosted tool is built for exactly that job.
For more on the broader toolkit — schedulers, screenshot tools, and where full automation fits — see The Best Build-in-Public Tools in 2026 and How to Build in Public as an Indie Hacker. If you're comparing hosted tools specifically, see how gittomarket stacks up in gittomarket vs Hypefury, or try the free stat card generator to see what the designed output actually looks like before connecting anything. Our own build log, generated the same way, is public at /w/gittomarket.
FAQ
Do I need a paid X developer account to auto-post commits?
For the DIY routes (GitHub Actions or your own bot), yes — X's API requires a developer account, and write access at any meaningful daily volume sits behind a paid API tier. A hosted tool like gittomarket includes posting in the subscription, so you don't need your own X developer keys at all.
Will my followers understand a feed of raw commit messages?
Usually not. Commit messages are written for other engineers ('fix null check in useAuth', 'wip refactor'), not for the founders, customers, or investors who might follow your build-in-public account. That's the main gap both DIY routes leave open — you either post the raw message or write your own formatting logic.
Can I switch from GitHub Actions to a hosted tool later?
Yes. Nothing about a GitHub Actions workflow locks you in — it's just a YAML file in your repo. If you outgrow it, you disable the workflow and connect your repo to a hosted tool instead. No data migration needed since there's no separate database to move.
Does auto-posting work if some days have zero commits?
It should skip them. A tool that posts on a schedule regardless of activity will eventually publish an empty or fabricated update on a day you did nothing — which looks worse than posting nothing. gittomarket skips zero-commit days by design; if you build your own bot or Action, you'll want the same guard.
Turn git push into a post, without maintaining a bot
Connect a repo and an X account and gittomarket handles the rest — designed cards, readable captions, zero-commit days skipped automatically.
Start free — 14 days of full Pro, no card