Thanks to visit codestin.com
Credit goes to github.com

Skip to content

allthingslinux/gitcord

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

GitCord

A Discord bot for GitOps-based Discord server management. Manage your server's channels and categories using YAML templates, version control, and GitHub integration.

Documentation License: GPL v3


πŸš€ Getting Started

Option 1: Use Pre-Hosted Bot (Recommended)

The easiest way to get started is to invite the pre-hosted GitCord bot to your Discord server:

πŸ“₯ Invite GitCord Bot

After inviting the bot, you can start using commands immediately. See the Quick Start Guide for usage examples.

Option 2: Self-Host (Advanced Users)

If you prefer to run your own instance of GitCord:

  1. Clone the repository:
    git clone https://github.com/evolvewithevan/gitcord.git
    cd gitcord
  2. Install dependencies (requires Python 3.9+ and uv)
    uv sync
  3. Set up environment variables:
    cp .env.example .env
    # Edit .env and add your Discord bot token
  4. Run the bot:
    python -m gitcord

For detailed self-hosting setup, see the Installation Guide.


πŸ“ What is GitCord?

GitCord is a Discord bot that lets you manage your server's structure using YAML configuration files, stored in Git and optionally synced with GitHub. It enables:

  • Version-controlled server configuration
  • Automated and manual sync of categories/channels
  • Bulk creation of channels/categories from templates
  • Easy server setup and reproducibility

✨ Features

  • Template-based Channel & Category Creation: Use YAML files to define your server structure
  • Manual & Planned Automatic Sync: Pull changes from a GitHub repo or local files
  • Slash & Prefix Commands: Use /createcategory, /createchannel, !createcategory, etc.
  • Permission Management: Follows Discord's permission system
  • Extensible: Modular cog system for easy extension
  • Open Source: GPL-3.0 License

See the full feature list.


πŸ› οΈ Example Usage

  • Create a channel from YAML:

    # general.yaml
    name: general
    type: text
    topic: General discussion
    position: 0
    nsfw: false

    Use: !createchannel

  • Create a category with channels:

    # community.yaml
    name: Community
    type: category
    position: 0
    channels:
      - general
      - memes
      - off-topic

    Use: !createcategory or /createcategory

See Quick Start and Templates Guide.


🧩 Main Commands

  • !hello / /hello β€” Greet the bot
  • !ping / /slashping β€” Check bot latency
  • !createchannel β€” Create a channel from YAML
  • !createcategory / /createcategory [yaml_path] β€” Create a category with channels
  • !fetchurl <url> / /fetchurl <url> β€” Fetch text from a website (admin)
  • !synccommands / /synccommands β€” Update slash commands (admin)
  • !help / /help β€” Show help and links

See Commands Reference.


πŸ“ Project Structure

gitcord/
β”œβ”€β”€ src/gitcord/           # Main source code
β”‚   β”œβ”€β”€ bot.py            # Main bot entry point
β”‚   β”œβ”€β”€ config.py         # Configuration management
β”‚   β”œβ”€β”€ events.py         # Discord event handlers
β”‚   β”œβ”€β”€ cogs/             # Discord.py cogs (command modules)
β”‚   β”œβ”€β”€ utils/            # Utility functions
β”‚   β”œβ”€β”€ views/            # Discord UI components
β”‚   └── constants/        # Constants and messages
β”œβ”€β”€ gitcord-template/     # Example template repository
β”œβ”€β”€ docs/                 # Documentation (mdBook)
β”œβ”€β”€ requirements.txt      # Python dependencies
β”œβ”€β”€ pyproject.toml        # Project metadata
└── README.md             # Project documentation

πŸ“ˆ Project Status & Roadmap

  • Alpha: Core features implemented, active development
  • See the Roadmap for planned features and progress
  • Planned Features:
    • Webhook-based automatic sync
    • Advanced template features (inheritance, variables)
    • More admin tools

🀝 Contributing

We welcome contributions! Please read CONTRIBUTING.md for:

  • Coding standards (PEP8, type hints, docstrings)
  • How to set up your dev environment
  • Testing and documentation guidelines
  • Pull request process

πŸ†˜ Support & Troubleshooting


πŸ“œ License

This project is licensed under the GNU General Public License v3.0. See LICENSE.


Made with ❀️ by the GitCord Team. Full Documentation

About

A Discord bot for Managing your discord's channel and role structure and roles via Git - GitOps

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Contributors 4

  •  
  •  
  •  
  •  

Languages