Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposal: Nix development environment and package #16

Merged
merged 3 commits into from
Jul 22, 2021
Merged

Conversation

jpotier
Copy link

@jpotier jpotier commented Jul 20, 2021

(I'm opening this MR mostly as a discussion, and although I'd like to see some of these changes pulled upstream, it is in no way blocking anyone from working with the current project as it is. No pressure)

Adding two files:

  • shell.nix provides a shell environment for development. In the project
    directory, entering the development shell by invoking nix-shell will pull
    all required dependencies to build the project (based on the latest stable
    release).
  • default.nix provides a package description of the latest stable release of
    the project. This allows people to quickly install m8c on their machine, by
    referencing the github project.

Added some documentation on how to use nix to automatically pull
dependencies, or quickly install m8c locally.

Adding two files:

- `shell.nix` provides a shell environment for development. In the project
  directory, entering the development shell by invoking `nix-shell` will pull
  all required dependencies to build the project (based on the latest stable
  release).
- `default.nix` provides a package description of the latest stable release of
  the project. This allows people to quickly install m8c on their machine, by
  referencing the github project.

Added some documentation on how to use nix to automatically pull
dependencies, or quickly install m8c locally.
@laamaa
Copy link
Owner

laamaa commented Jul 21, 2021

Thank you, the package files are a good addition. Could you please describe how to maintain them on updated versions? Just update the version and hash in default.nix?

It might be better to leave only the bonus stuff in the readme. The installation part is meant to be more of a newbie guide, the part in the middle might just confuse most people just trying to get the thing running on their Raspberry Pi/whatever. I would imagine that Nix/Nixos users already know their way around the system :)

@jpotier
Copy link
Author

jpotier commented Jul 21, 2021

I'll add a mention on how to maintain the files (as a comment maybe, or in a CONTRIBUTING.md) when I can (probably in the evening today)

@jpotier
Copy link
Author

jpotier commented Jul 21, 2021

@laamaa I've added some docs, and removed all but the bonus stuff in README, is that better?

btw, the nix support for building and dev env should work in OSX as-is (untested), but also in Windows WSL2 (untested).

@laamaa laamaa merged commit 7368152 into laamaa:main Jul 22, 2021
@laamaa
Copy link
Owner

laamaa commented Jul 22, 2021

Looks good to me, merged

laamaa added a commit that referenced this pull request May 27, 2022
Nix development environment and package
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants