Giter VIP home page Giter VIP logo

dev-templates's Introduction

Nix flake templates for easy dev environments

built with nix

To initialize (where ${ENV} is listed in the table below):

nix flake init --template github:the-nix-way/dev-templates#${ENV}

Here's an example (for the rust template):

# Initialize in the current project
nix flake init --template github:the-nix-way/dev-templates#rust

# Create a new project
nix flake new --template github:the-nix-way/dev-templates#rust ${NEW_PROJECT_DIRECTORY}

How to use the templates

Once your preferred template has been initialized, you can use the provided shell in two ways:

  1. If you have nix-direnv installed, you can initialize the environment by running direnv allow.
  2. If you don't have nix-direnv installed, you can run nix develop to open up the Nix-defined shell.

Available templates

Language/framework/tool Template
Clojure clojure
C# csharp
Cue cue
Dhall dhall
Elixir elixir
Elm elm
Gleam gleam
Go go
Hashicorp tools hashi
Haxe haxe
Java java
Kotlin kotlin
LaTeX latex
Nickel nickel
Nim nim
Nix nix
Node.js node
OCaml ocaml
Open Policy Agent opa
PHP php
Protobuf protobuf
Pulumi pulumi
Purescript purescript
Ruby ruby
Rust rust
Scala scala
[Shell] shell
Zig zig

Template contents

The sections below list what each template includes. In all cases, you're free to add and remove packages as you see fit; the templates are just boilerplate.

  • Ruby 3.2.2, plus the standard Ruby tools (bundle, gem, etc.)
  • Rust, including cargo, Clippy, and the other standard tools. The Rust version is determined as follows, in order:

    • From the rust-toolchain.toml file if present
    • From the rust-toolchain file if present
    • Version 1.70.0 if neither is present
  • rust-analyzer 2023-07-10

  • cargo-audit 0.17.0

  • cargo-deny 0.12.1

Code organization

All of the templates have only the root flake as a flake input. That root flake provides a common revision of Nixpkgs and flake-utils to all the templates.

dev-templates's People

Contributors

lucperkins avatar nothingmuch avatar g0dm0d avatar 573 avatar derekbelrose avatar drupol avatar sstubbs avatar bwkam avatar ymgyt avatar jakuzure avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.