Skip to content

codeitlikemiley/rust-on-steroids

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

76 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rust on Steroids

Rust Dev Machine ready to be used by you and your team with either Codespace or DevContainers.

Built for Rust

  • Uses Very Fast Linker MOLD , set as default linker
  • Uses Sccache for caching crates
  • Bonus Vscode Plugins for 10X Rust Developers
    • cargo runner - Run , Test , Doc-Test , Build Without Mental Overhead
    • cargo bin - Run any cargo bin commands on your $CARGO_HOME/bin

Requirements

  • Vscode
  • Codespace
  • Devcontainer

Usage

  • clone this repo
git clone https://github.com/codeitlikemiley/rust-on-steroids YOUR_NEXT_BIG_PROJECT
  • update .env.mysql or .env.postgres depending on your db of choice, then cp .env.example .env on .devcontainer folder

e.g. change Database URL on .devcontainer/.env if you wanna use external service like planetscale, you can set it here.

DATABASE_URL=postgresql://postgres:secret@db:5432/db_name?sslmode=disable
  • Update .devcontainer/.bash_aliases

  • Open Command Palette type Open Folder in Container or Create new Codespace

  • Open Command Palette type Open Terminal

cd crates

CLI Tools Bundled

GPG Keys Issue?

  • Export keys
gpg --list-secret-keys
gpg --armor --export-secret-keys [key-ID] > privatekey.asc
  • Copy the key
cat privatekey.asc | pbcopy
  • Create a new file on /workspace/private.asc and paste the key there
code /workspace/private.asc
  • Import they key
gpg --import private.asc

Set up git

  • open terminal and run
gs

Note: you can only git commit inside vscode after you run gs and import gpg key

Creating GRPC Server and Services

  • generate service
cd services
generate example 
# the command below can be optionally run
ws add services/example
  • Generate a new Server
generate server
// default service is example
# we need to add server to workspace
ws add server

Known Issue

Some pre-installed CLI are incompatible , e.g. cargo-nextest , if you cannot run that the solution is to run

cargo binstall -y --force cargo-nextest

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published