1
1
mirror of https://github.com/tweag/nickel.git synced 2024-10-04 07:07:10 +03:00
Commit Graph

79 Commits

Author SHA1 Message Date
Yann Hamdaoui
96d6c40c92
Remove double build of nickel-repl 2023-01-17 15:34:02 +01:00
Guillaume Desforges
6220703738 Apply suggestions from code review
Co-authored-by: Julien Debon <julien.debon@protonmail.com>
Co-authored-by: Yann Hamdaoui <yann.hamdaoui@gmail.com>
2023-01-16 16:38:24 +01:00
Guillaume Desforges
2976aee8c4 wip nix build 2023-01-16 16:38:24 +01:00
Guillaume Desforges
6e122939ad init Python bindings 2023-01-16 16:38:24 +01:00
matthew healy
bff8451f7e
Add snapshot testing infrastructure (#1034)
* Update regex crate to 1.7

We want to use the regex filtering feature of the insta snapshot testing
library. That has a dependency on a newer version of the regex crate
than Nickel currently does, so this commit updates the Nickel version to
a more recent compatible version.

* Add insta dependency

* Add cargo-insta to dev shells

* Add snapshot testing infrastructure

This uses the insta crate to implement snapshot testing.

Each snapshot test invokes the debug nickel binary with some set of
arguments, then captures the output & compares it to a file in the
snapshots directory

* Add nixpkgs-fmt to dev shell

This makes it possible to easily reformat flake.nix from within a dev
shell.

* Update HACKING.md

* Add snapshot testing README
2023-01-09 11:32:40 +01:00
Yann Hamdaoui
9b1318a208
Merge pull request #1014 from tweag/devops/wasm-to-crane
Build the WASM crate using `crane` and get rid of import-from-cargo
2022-12-26 20:40:53 +01:00
Yann Hamdaoui
619fe9ae33
Apply suggestions from code review 2022-12-25 12:17:39 +01:00
Yann Hamdaoui
7283165af0
Get rid of import-cargo: use crane for WASM build 2022-12-24 13:17:24 +01:00
Solene Rapenne
f706fee8c7 make nix run to find nickel binary 2022-12-23 10:57:27 +01:00
matthew healy
dbf782d411
Re-enable rustfmt pre-commit check (#972) 2022-12-06 10:50:37 +01:00
Julien Debon
62128a642f
Migrate Nix build from import-cargo to Crane (#963)
* Refactor flake inputs because it's been annoying me for weeks now
* Fix a long-standing bug in mk_uniftype.rs
Can be reproduced by running `cargo test --workspace`.
This was never noticed before in CI because the `--workspace` flag is not passed.
This will be addressed in the Crane migration
* Remove utilities/Cargo.lock
This is probably a fragment of the past, back when Nickel did not use Cargo workspaces.
* Fix Clippy issues in tests
* Rustfmt and clippy are no longer in preview
* Update README with Nix flake shell command
* Migrate from import-cargo to crane for Nickel
Nickel WASM build is intentionally left intact and still uses the old
import-cargo.
This is because the change is already massive, and in practice the WASM build
relies more on `wasm-pack` than Cargo (even though under the hood, `wasm-pack`
uses Cargo).

If Crane looks good, both for DX and for CI, we will consider migrating Nickel
WASM to Crane too in a future PR.
* Remove support for Rust nightly channel
* Only Nix check for Rust `stable` channel
* Fix deprecated Nix build documentation commands
* Fix completion test
2022-12-05 17:28:45 +01:00
Julien Debon
2c9654b972 Add the VS Code extension to CI 2022-11-24 09:57:53 +01:00
Julien Debon
79521f5c6e Fix VS Code extension Nix build
* Fix VS Code extension Nix build
  * Regenerate the 3 `node2nix` files with a more recent `node2nix`
  * Add the missing `vsce` dependency
  * Pass the `--development` flag to `node2nix` to correctly include dev
    dependencies like `typescript` or `vsce`
* Use the verbose form of `tsc` parameters in `package.json`
* Add `node2nix`, `markdownlint` and `nodejs` to the dev shell
* Add a `README.md` to the VS Code extension directory

Close https://github.com/tweag/nickel/issues/893
2022-11-24 09:57:53 +01:00
Yann Hamdaoui
1ddf52bdeb
[CI] Add clippy check (#793)
* Print logs when running `nix flake check` in CI
* Add clippy to the flake checks and git hooks
* Clippy auto fix
  `cargo clippy --fix --workspace --no-deps --frozen --offline -- --deny warnings --allow "clippy::new-without-default" --allow "clippy::match_like_matches_macro"`
* Manually fix remaining Clippy warnings

Co-authored-by: Julien Debon <julien.debon@tweag.io>
2022-11-17 18:18:49 +01:00
Julien Debon
bb66cb0266 Update wasm-bindgen from 0.2.74 to 0.2.83
Version 0.2.74 no longer builds with recent `nixpkgs` because of openssl.

* Update wasm-bindgen from 0.2.74 to 0.2.83
* Refactor `wasm-bindgen-cli` overlay to override Nixpkgs' definition, rather
than build the package from Github
* Remove the no longer used `wasm-bindgen-api-Cargo.lock` file
* Add comments about the hidden coupling between `wasm-bindgen` in `Cargo.toml`
and `wasm-bindgen-cli` in `flake.nix`
2022-11-03 11:36:34 +01:00
Yann Hamdaoui
5934b325cd
Update flake.nix 2022-10-28 17:10:21 +02:00
Yann Hamdaoui
9552154268
Documenting cargoHome use in the flake definition 2022-10-28 17:08:45 +02:00
matthew healy
db55f960ee
Avoid double-negative
Co-authored-by: Julien Debon <julien.debon@tweag.io>
2022-10-28 15:19:45 +02:00
Matthew Healy
f5f66c6433 Add rust-analyzer to devShells 2022-10-28 14:11:19 +02:00
Yann Hamdaoui
66d60a7e61 Enable markdown linting
Add configuration for markdown linting (disabling some rules) and enable
markdown linting in the pre-commit hooks and the checks of the flake.
2022-08-05 11:55:21 +02:00
Yann Hamdaoui
e0767e44a1 Remove deprecated devShell and defaultPackage 2022-08-04 18:35:18 +02:00
Yann Hamdaoui
952a10169d Update to the new cachix instance 2022-08-01 15:51:45 +02:00
Yann Hamdaoui
9de227b5aa
Merge pull request #744 from tweag/task/build-stdlib-doc-2
Add flake output to build stdlib documentation
2022-06-29 12:15:27 +02:00
Yann Hamdaoui
c65f101fe5
Remove Makam specification 2022-06-24 16:46:36 +02:00
Yann Hamdaoui
edc532b420
Add flake output to build stdlib doc 2022-06-22 11:13:47 +02:00
Yann Hamdaoui
841cfb7db1
Separate the WASM repl in wrapper crate 2022-06-15 16:53:38 +02:00
Yann Hamdaoui
0b1ed40e40 Rename crates nickel* to nickel-lang* 2022-03-06 22:27:57 +01:00
Yann Hamdaoui
c73203424a Expose the user manual as a flake outut 2022-02-28 18:09:25 +01:00
Rok Garbas
5ae5034d16 nixpkgs: updated 2022-02-04 22:39:13 +00:00
Rok Garbas
fdc718f25b flake-utils: updated 2022-02-04 10:36:53 +00:00
Rok Garbas
38accff2b0
Don't check or format generated Nix files
like the files generated by node2nix.
2022-01-19 22:39:09 +01:00
Rok Garbas
ea319cda3a
Getting pre-commit check to work
also some refractoring when creating rust platform
2022-01-19 09:23:22 +01:00
Rok Garbas
63c077b776
Replace custom git hooks with pre-commit-hooks.nix 2022-01-18 23:30:08 +01:00
Rok Garbas
dba0dbf90c
Switching from nixpkgs-mozilla overlay to rust-overlay 2022-01-17 12:53:18 +01:00
Rok Garbas
9826d59d90
Simplify flake.nix with flake-utils 2022-01-16 23:17:41 +01:00
Rok Garbas
3cd07b5510
Use overlay to pin wasm-bindgen-cli 2022-01-14 22:47:05 +01:00
Avi Dessauer
30fb71a1f1 Fix comment 2022-01-04 14:42:03 -05:00
Avi Dessauer
c71cf5d736 Add a comment explaining sed ugliness 2022-01-04 13:58:00 -05:00
Avi Dessauer
5f22ff51ab
Merge branch 'master' into avi/24gb-benchmarks-are-better-than-none 2022-01-03 11:06:38 -05:00
Yannik Sander
fa259ae6d2
Merge pull request #505 from tweag/language-server/vs-code-client
[Language server] vs code client
2022-01-03 16:36:28 +01:00
Avi Dessauer
4a039e2351 Deduplicate [lib] 2022-01-01 01:12:41 -05:00
Avi Dessauer
9b9c7a682e This is a hack to prevent the fs2 crate from being compiled on wasm
Adding a bench feature, or using target does not work due to open Cargo issues.
2021-12-31 23:54:52 -05:00
Yannik Sander
4c1d904c96 Add vsix as flake output 2021-12-13 17:10:19 +01:00
Yann Hamdaoui
5b9d507a2b Only check formating on stable channel 2021-12-10 12:07:47 +01:00
Yannik Sander
55c3e05c76 Mark Cachix cache as __extra__-substitutor 2021-12-06 15:19:39 +01:00
Yann Hamdaoui
e097445fa8
Merge pull request #463 from silverraven691/fix-387
Work around IFD in nixpkgs-mozilla
2021-11-22 15:53:27 +01:00
Alexander Bantyev
2c1fc82ee6
Add the substituter to flake.nix and README 2021-11-17 14:25:22 +03:00
silverraven691
d5aa96d06d Work around IFD in nixpkgs-mozilla 2021-11-16 14:20:52 +01:00
regnat
e2070ee731 Install the lsp server with Nix
Add the `nls` executable to the `nix build` output.
This makes it much easier to use (for me at least).
2021-10-19 16:30:06 +02:00
Yannik Sander
41e9ca74b0 Use nix supplied rust/cargo binary
Allows hook to work in tools that are not using the `nix develop` environment
2021-09-27 20:09:56 +03:00