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

WIP: Add flake.nix for a Nix build #3334

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

msgilligan
Copy link
Member

@msgilligan msgilligan commented Dec 15, 2023

You should now be able to use:

  • nix develop -- to get a development shell
  • nix run .#wallettool to build and run the wallet-tool
  • nix run .#wallettemplate to build and run the wallettemplate

see README_NIX.adoc for details.

Known issues:

  1. The builds are currently using the "escape hatch" method and should be using something like gradle2nix.
  2. There should be a separate target to install bitcoinj-core and possibly for some of the other module and dependency JARs.
  3. As a result of the above two issues there is a conflict if you install both applications. It can be resolved with the --priority option see the note in README_NIX.adoc.

gitignore,
...
}:
flake-parts.lib.mkFlake {inherit inputs;} {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure this isn't one indentation too many? It doesn't cleanly unwind if you look at the end of the file.

Copy link
Member Author

@msgilligan msgilligan Dec 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure -- I'm still learning the Nix language and any coding style conventions that come with it.

I based the code on this example: https://github.com/brianmcgee/nix-gradle-sample/blob/main/flake.nix and have not changed the indentation. Note that there is one other place in the code with a }: and in both cases the following line is indented.

flake.lock Show resolved Hide resolved
@msgilligan
Copy link
Member Author

This has been rebased and also updated to use nixpkgs-unstable and the jdk21 package.

You should now be able to use:

* `nix develop` -- to get a development shell
* `nix run .#wallettool` to build and run the wallet-tool
* `nix run .#wallettemplate` to build and run the wallettemplate

see README_NIX.adoc for details.
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