Skip to content

0Nulliu/rust_dev_environment

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RUST "Playspace" | Using Docker and Neovim

This repository has it role as a containerized development environment for building Rust applications.

The environment uses:

  • Debian bookworm as a stable OS in combination with Neovim
  • Rust toolchain (rustc, cargo, rust-analyzer).
  • Neovim (v0.11.4) | As a preferred choice of coding.
  • PostgreSQL | To integrate a database service for future applications
  • The standard build tools (clang, lld, git..)

Prerequisites

Quick Start

  1. SSH Key not added to Github/Gitlab already
 ssh-keygen -t ed25519 -C "[email protected]"
 cat ~/.ssh/id_ed25519.pub << "Add this inside of GitHub or GitLab"
 # Test your key... 
 ssh -T [email protected]
 ssh -T [email protected] 
  1. Clone the repository (with submodule for neovim config):
    git clone --recurse-submodules https://github.com/0Nulliu/rust_dev_environment
    cd rust_dev_environment
  2. Prepare SSH: (step needs to be repeated on every access for safety) This environment uses SSH forwarding to securely handle Git credentials. Run these commands.
    eval "$(ssh-agent -s)"
    ssh-add ~/.ssh/id_ed25519
    newgrp docker (alternative is to add docker as a USER)
  3. Build and start (only need to run once):
    docker-compose up -d --build
  4. Enter the Docker:
    docker-compose up -d
    docker-compose exec dev bash
  5. Happy days! and Happy coding!
 cd /home/devuser/project
 cargo new future_billion_dollar_company
 cd future_billion_dollar_company
 nvim .
  1. When you're done shut down the containers
 docker-compose down

PostgreSQL is a bit shifty right now, future instructions will be given once I've set it up better.

Is neovim configured?

Yes there is a .nvim.conf situated inside of the ~/devuser/project

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published