Skip to content

Repository files navigation

🐦 Twibble

Python uv Django License Stars

Twibble is a minimalist, Twitter-like microblogging platform built with Django. It lets users share short posts, follow others, and explore a simple, clean social feed.


Features

  • User registration and login
  • Post short messages (tweets)
  • Follow/unfollow other users
  • View a personalized feed
  • User profiles with follower/following counts
  • Profile editing and account settings
  • Responsive design using Bootstrap 5

Tech Stack

  • Python: 3.12+
  • Dependency management: uv
  • Backend: Django 6.0
  • Frontend: HTML, CSS, Bootstrap 5
  • Database: PostgreSQL (environment-configurable)
  • Auth: Django built-in authentication
  • Image Processing: Pillow
  • Env config: .env (python-dotenv)
  • Linting & Formatting: Ruff
  • Pre-commit Hooks: Automated linting, formatting, and tests

Reproducible Environment

This project uses modern python dependency management with:

  • pyproject.toml for dependency definitions.
  • uv.lock for exact dependency versions.

To recreate the exact environment:

uv sync

Screenshots

Screenshots coming soon!

📦 Installation

  1. Install uv uv is used to manage dependencies and virtual environments.
pip install uv

or

curl -Ls https://astral.sh/uv/install.sh | sh
  1. Clone the repository
git clone https://github.com/DevMohammad-SA/Twibble.git
cd Twibble
  1. Install dependencies
uv sync

This will:

  • Create a virtual environment automatically.
  • Install all dependencies specified in pyproject.toml.
  • Reproduce the exact development environment.
  1. Set up environment variables

    Copy the example environment file and update it with your configuration:

    cp example.env .env

    Or create a .env file manually in the root directory with at minimum:

    DEBUG=True
    SECRET_KEY=your-secret-key-here
    ALLOWED_HOSTS=127.0.0.1,localhost
    DB_ENGINE=django.db.backends.postgresql
    DB_NAME=twibble
    DB_USER=postgres
    DB_PASSWORD=postgres
    DB_HOST=localhost
    DB_PORT=5432

    Security Note: Generate a secure secret key for production. You can use python -c "from django.core.management.utils import get_random_secret_key; print(get_random_secret_key())" to generate one.

    DB_ENGINE defaults to django.db.backends.postgresql if unset. See example.env for additional configuration options including database, email, and timezone settings.

  2. Apply migrations and run server

    uv run python manage.py migrate
    uv run python manage.py runserver
  3. Access the app Open your browser and go to http://127.0.0.1:8000/

  4. Install pre-commit hooks

    uv run pre-commit run --all-files

To-Do

  • Add likes and replies
  • Add image uploads
  • Add search functionality
  • Create REST API (optional)
  • Add notifications system
  • Implement hashtags support
  • Add Arabic locale support
  • Implement bookmark support

Contributing

Contributions are welcome! Please see CONTRIBUTING for guidelines. Feel free to open issues or submit pull requests.


License

This project is licensed under the MIT License. See the LICENSE file for details.


Author

Made with ❤️ by Mohammad Albuainain

About

🐦 Twibble is a minimalist Twitter-like social media app built with Django. Users can register, post tweets, follow others, and view a personalized feed.

Topics

Resources

Contributing

Security policy

Stars

4 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages