Skip to content

Commit

Permalink
Use hasktorch in nixpkgs
Browse files Browse the repository at this point in the history
  • Loading branch information
junjihashimoto committed Jan 9, 2025
1 parent be66e63 commit 510f1f2
Show file tree
Hide file tree
Showing 15 changed files with 58 additions and 890 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,12 @@ Similar to the [Cardano Skeleton](https://github.com/input-output-hk/cardano-ske
this repository serves as an example of how a downstream user of both Nix and Hasktorch
can set up a development environment.

The Nix shell installs ghc with hasktorch. When there is a hasktorch cache in nixpkgs, building hasktorch will be skipped.

# 3 Steps to happy Hasktorch coding

1. Fork this repo and clone it locally.
2. Launch a Nix shell with (optionally) CUDA, `ghcide`, and VS Code, `nix-shell --arg cudaSupport true --argstr cudaMajorVersion 10 --command "code ."`
2. Launch a Nix shell with (optionally) CUDA, `hls`, and VS Code, `nix develop"`
3. Install the [Haskell Language Server plugin](https://marketplace.visualstudio.com/items?itemName=alanz.vscode-hie-server) and set the `HIE Variant` to `ghcide`.

Happy Hasktorch hacking!
21 changes: 0 additions & 21 deletions cabal.project
Original file line number Diff line number Diff line change
@@ -1,23 +1,2 @@
packages:
*.cabal

source-repository-package
type: git
location: https://github.com/hasktorch/hasktorch
tag: d7dd1f0a83971621526caf80c0dfafc5eb0bc8be
--sha256: 1rh6xssbzcp6gix80w55qdv9ilynsrjlyn9m283bi5c5i876hrvl
subdir: libtorch-ffi-helper

source-repository-package
type: git
location: https://github.com/hasktorch/hasktorch
tag: d7dd1f0a83971621526caf80c0dfafc5eb0bc8be
--sha256: 1rh6xssbzcp6gix80w55qdv9ilynsrjlyn9m283bi5c5i876hrvl
subdir: libtorch-ffi

source-repository-package
type: git
location: https://github.com/hasktorch/hasktorch
tag: d7dd1f0a83971621526caf80c0dfafc5eb0bc8be
--sha256: 1rh6xssbzcp6gix80w55qdv9ilynsrjlyn9m283bi5c5i876hrvl
subdir: hasktorch
69 changes: 0 additions & 69 deletions default.nix

This file was deleted.

160 changes: 21 additions & 139 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 510f1f2

Please sign in to comment.