Skip to main content

Blog Uploader

blog-uploader is a command-line tool to help you manage your Hugo blog posts. It allows you to create new posts from local markdown files, remove existing posts, and list all current posts.

Features

  • Create New Posts: Quickly create a new Hugo post from a markdown file.
  • Remove Posts: Safely delete a post by its folder name.
  • List Posts: View a list of all your current blog posts.
  • Git Integration: Automatically clones your blog's repository, and commits and pushes changes.
  • Cross-Platform: Works on Windows, macOS, and Linux.

Requirements

  • Hugo: This tool depends on Hugo. Before using blog-uploader, please ensure that Hugo is installed and accessible in your system's PATH. The tool will automatically check for Hugo's presence and guide you if it's missing.

Installation

You can install blog-uploader via pip:

pip install .

(After navigating into the blog-uploader directory)

Or, once it's published on PyPI:

pip install blog-uploader

Usage

The tool provides three main commands: new, remove, and list.

1. Create a New Post

To create a new post, use the new command and provide the path to your markdown file.

blog-uploader new /path/to/your/post.md

The tool will:

  1. Clone or pull the latest version of your blog repository.
  2. Create a new post in Hugo.
  3. Append the content of your file to the new post's index.md.
  4. Automatically open the new file in Typora for editing (if Typora is found).
  5. Prompt you to confirm after you have set the title and other metadata.
  6. After you confirm, it will rename the post's folder based on the title.
  7. Build the site with Hugo, and commit and push the changes to your repository.

2. Remove a Post

To remove a post, use the remove command with the post's folder name.

blog-uploader remove "name-of-the-post-folder"

You will be asked for confirmation before the post is deleted.

3. List All Posts

To see a list of all your posts, use the list command.

blog-uploader list

This will display the folder names of all posts in your content/post directory.

Configuration

Currently, the tool is configured with a hardcoded Git repository URL. In future versions, this will be customizable through a configuration file.

Metadata

Release files for blog-uploader 0.1.8

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for blog-uploader 0.1.8
File Interpreter ABI Platform Actions
blog_uploader-0.1.8-py3-none-any.whl Python 3 none any Details for blog_uploader-0.1.8-py3-none-any.whl

Release files / blog_uploader-0.1.8-py3-none-any.whl

Download URL blog_uploader-0.1.8-py3-none-any.whl
Size 9.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ceb8d94f18c7c27422b6d7af5bbbbee6b860b87ba5b8a19379fbf2d62605dd66
BLAKE2b-256 checksum
How to use checksums
5c83229be6bf299392e93c6c954f0b5215c345534a4142bb6148fde5a51fa385
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.5

Security for blog-uploader 0.1.8

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page