Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

genopen

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

genopen

Markdown to blog generator

  • 1.1.0
  • PyPI
  • Socket score

Maintainers
1

Genopen

Genopen Logo

Genopen is a Python application that allows you to create blogs easily and quickly from content written in Markdown. Whether you are a writer, a developer, or just someone who wants to share their thoughts online, Genopen provides an intuitive command-line interface to easily generate blogs ready to be published.

Table of Contents

  • Features
  • Installation
  • Usage
  • Project Structure
  • Themes
  • Configuration
  • License

Features

  • Project Creation: Generate a new empty project.
  • Markdown Writing: Add posts using Markdown syntax, which will be automatically converted to HTML.
  • Customizable Themes: Use the default theme or create your own to customize the appearance of your blog.
  • Automatic Generation: Convert all your posts into a complete static website.
  • Sitemap and RSS: Automatically generate a sitemap and an RSS feed for your blog.

Installation

Make sure you have Python installed on your machine. Then, clone the repository and install the dependencies:

# Clone the repository
$ git clone https://github.com/your-username/genopen.git

# Navigate to the project directory
$ cd genopen

# Install the dependencies
$ pip install -r requirements.txt

# Install the application locally
$ pip install .

Usage

Genopen is used via a command-line interface (CLI). Here are the main commands:

Creating a Project

To create a new blog project:

$ genopen create <project_name>

This command creates a new directory containing the necessary structure to start working on your blog.

Adding Posts

Once the project is created, you can add new posts:

$ cd <project_name>
$ genopen add "Title of Your Post"

This command creates a pre-filled Markdown file with the title and necessary metadata.

Generating the Blog

To generate the HTML pages for your blog:

$ genopen build

The generated blog will be placed in a directory named web/. This directory will contain all the pages and resources ready to be deployed on a server.

Project Structure

Here is an overview of the project structure:

<project_name>/
  |-- content/
  |    |-- posts/               # Contains the blog posts in Markdown
  |    |-- assets/              # Contains images and other resources for the posts
  |
  |-- themes/                   # Contains themes to customize your blog
  |    |-- default/             # Default theme
  |
  |-- genopen.config            # Project configuration file
  |-- web/                      # Generated folder containing the final blog

Themes

The themes/ folder contains HTML, CSS, and other resources needed to customize the appearance of your blog. By default, Genopen includes a simple theme, but you can create and use your own themes.

Creating a New Theme

To create a new theme, add a folder under themes/ and include the HTML files (e.g., index.html, post.html) as well as the CSS and other necessary resources. Update the configuration (genopen.config) to point to the new theme.

Configuration

The genopen.config file allows you to configure your blog.

  • Mandatory Variables: The following three variables are required for the genopen build command:

    • theme: Specifies the theme to be used.
    • date_format: Defines the date format.
    • locale: Sets the language and local format.
  • Theme-Specific Variables: Other variables (e.g., blog_name, domain) are optional and depend on the theme being used. You can define them in the configuration file if your theme requires them.

  • Environment Variables: Sensitive data (e.g., API keys) can be configured using environment variables with a defined prefix (environment_prefix). This allows secrets to be securely managed.

License

This project is licensed under the MIT License. You are free to use, modify, and distribute it as you wish.

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc