Commit Graph

1965 Commits

Author SHA1 Message Date
Anton-Latukha f4b116f197 add HNix small logo
A  doc/images/HNixSmall.svg
2020-07-23 20:37:39 +03:00
Anton-Latukha a8a9ebabb1 add HNix logo 2020-07-23 20:37:39 +03:00
Anton-Latukha e3d4254258 cabal: clean-up bound copies 2020-07-16 21:21:11 +03:00
Anton-Latukha 5f63b2aa61 cabal: library: m cosmetics 2020-07-16 21:21:11 +03:00
Anton-Latukha c6f9ab81b9 CHANGELOG: 0.9.1: mv additional info into additional; explain deps 2020-07-13 19:48:34 +03:00
Anton-Latukha 37fde9b3d0 CHANGELOG: 0.9.0: m upd on GHC support status 2020-07-13 19:48:34 +03:00
Richard Marko 0b61040bee hnix.cabal: version 0.9.1 2020-07-13 19:20:31 +03:00
Richard Marko e9c9a27504 changelog: add 0.9.1 2020-07-13 19:20:31 +03:00
Richard Marko 06edd4b8cf builtins.nixVersion: version 2.0 -> 2.3
Nixpkgs now has minimum required version 2.2, this allows us to
import it again.
2020-07-11 19:18:07 +03:00
Anton-Latukha 7fae8fa962 CI: .travis.yml: switch all builds to nixos-unstable
M  .travis.yml
2020-07-09 16:08:20 +03:00
Anton Latukha 3fb78fcc40
Merge pull request #658 from sorki/fix/repline_0_4
Epic Support repline 0.4
2020-07-08 18:43:07 +03:00
Richard Marko c9eb24626a repl: drop GHC pragams disabling warnings, prune imports 2020-07-04 18:42:16 +02:00
Richard Marko 0cf6be6be2 readme: add short REPL section 2020-07-04 18:42:16 +02:00
Richard Marko f964284c66 repl: improve tab completion 2020-07-04 18:42:16 +02:00
Richard Marko 8d0e325cf5 repl: Add ReplConfig and :set command 2020-07-04 18:42:16 +02:00
Richard Marko b84f4f6c19 repl: Support loading .hnixrc from current directory 2020-07-04 18:42:16 +02:00
Richard Marko f7704b4c28 repl: Pass result of --eval -E "..expr.." to REPL
Allows us to do
```
hnix --eval -E '{ a = 2; b = "test"; }' --repl

hnix> :browse
input = { a = 2; b = "test"; }
hnix> input.a
2
hnix> input.b
"test"
```

Closes #292.
2020-07-04 18:42:16 +02:00
Richard Marko 4ce176d1a1 repl: Better help using HelpOption type 2020-07-04 18:42:16 +02:00
Richard Marko 0e8e73ec88 repl: Extend IState, handle bindings, add browse and debug commands
Bindings are now handled correctly and you can do

```
a = 2
b = 3
c = a + b
:browse
:t c
```

Converted IState to data type instead of `newtype`.
Now tracks `replIt` for last entered expression that parsed
successfully.

`replCtx` is now extended with bindings and browseable via `:browse`.

:`debug` can be used to enable dumping of `IState` on input.

Scope taken from `replCtx` is now pushed to evaluated values.
2020-07-04 18:42:16 +02:00
Richard Marko d9303f385c repl: Refactor error handling
Drops Repline `abort`s and switches to `Maybe` result for `call` function.

Few other bits handled too:
- `M.empty` -> `mempty`
- qualified use of `Data.Text`
- minor formatting fixes for readability

Closes #505.
2020-07-04 18:42:16 +02:00
Simon Jakobi b4e3b3b2f4
Improve the documentation in Nix.{Atoms,Expr.Types} (#662)
This also removes some commented out TH from the haddocks
2020-07-03 01:35:30 +02:00
Richard Marko 59e65d094a repl: support multi-line input
```
Welcome to hnix 0.9.0. For help type :help

hnix> :paste
-- Entering multi-line mode. Press <Ctrl-D> to finish.
| { just
| =
| ''
| testing
| '';
| }
|
{ just = "<CYCLE>"; }
hnix>
Goodbye.
```

Closes #665.
2020-07-02 14:04:13 +02:00
Richard Marko 710bc84309 Support repline 0.4
Closes #651.

`haskeline` override needs `dontCheck` as it tries to run an executable.

Tested build and repl itself.
2020-07-02 14:04:13 +02:00
Richard Marko 704323ecd6 Add cabal.project, only .gitignore cabal.project.local
This prevents accidental surprises like the one I've managed to hit
today - `git worktree add master` and building in master directory
tries to look-up `cabal.project` but only discovers one in parent
directory and starts reusing `dist-newstyle` for the build.

Better to have this explicit which devs can also use as a template to
add other temporary deps.
2020-06-27 23:25:16 +03:00
Simon Jakobi 220209c090
Use neat-interpolation instead of interpolate (#635)
In addition to `interpolate`, this also removes the following
transitive dependencies:

 - `haskell-src-exts`
 - `haskell-src-meta`
 - `safe`
 - `th-expand-syns`
 - `th-lift`
 - `th-lift-instances`
 - `th-orphans`
 - `th-reify-many`

Since `neat-interpolation`'s `text` quasiquoter trims more whitespace
than `interpolate`'s `i`, the expected output of some tests for
`unsafeGetAttrPos` had to be updated.

This also improves the test failure output of the `constantEqual`
helper.

Fixes #634.
2020-06-27 10:43:50 +02:00
Anton-Latukha fed62e9a54 README: add Repology page
Repology is social, logging and analytical network for software projects and
software stores.

M  README.md
2020-06-24 17:48:20 +03:00
Anton Latukha 529f950696
Merge pull request #650 from Anton-Latukha/upd-CI-refactor-01
Merge docs (`build.sh`->`default.nix`).

  - [x] Included some minor clean-up.

  - [x] This consolidates most of the docs for options in the `default.nix`, since it is an entry point for API, it increases its header, but currently, I do not know the more useful, convenient way to expose all these features to the all users.

  This closes the #645.

  - [x] With Nix installer rollout and after refactoring removing obviously redundant previous hack Nix updates in `.travis.yml`.

  - [x] After refactor observed that service changes do not need the `daemon-reload`, so simplified the service to `restart`.

  - [x] We still have Nix and channel update right before builds, so I also added into `build.sh` reporting of Nixpkgs revision of the build.
2020-06-24 04:10:07 +03:00
Anton-Latukha ba73fa26d8
CI: build.sh: add report of Nixpkgs channel revision
Since Nix and Nixpkgs channel were just updated and build is next - report the
revision.

M  build.sh
2020-06-24 03:57:04 +03:00
Anton-Latukha 2bd98c2d92
CI: .travis.yml: upd service restart
Since service is not touched the daemon-reload is probably not needed, restart
is sufficient.

M  .travis.yml
2020-06-24 03:44:34 +03:00
Anton-Latukha e3e6511c91
CI: .travis.yml: rm Nix updates
After refactoring they are right beside/before build.sh Nix updates, so this
update can be reduced.

M  .travis.yml
2020-06-24 03:41:09 +03:00
Anton-Latukha 249e1797e2
CI: build.sh: rm most of NOTE tags
M  build.sh
2020-06-24 03:30:28 +03:00
Anton-Latukha c60e875da2
CI: merge docs (build.sh->default.nix)
M  build.sh
M  default.nix
2020-06-24 03:19:43 +03:00
Anton-Latukha cbe22270b6
CI: mv rev doc (build.sh->default.nix)
M  build.sh
M  default.nix
2020-06-24 03:19:37 +03:00
Anton-Latukha 601659af16
CI: default.nix: upd header disclamer
M  build.sh
2020-06-24 03:08:35 +03:00
Anton-Latukha b597748fa5
CI: {build.sh,default.nix}: upd settings structure, upd descriptions
M  build.sh
M  default.nix
2020-06-24 03:05:05 +03:00
Anton-Latukha 1a730fcfd0
CI: .travis.yml: rm irrelevant remount
M  .travis.yml
2020-06-24 02:57:49 +03:00
Anton Latukha b3f0361468
Merge pull request #647 from Anton-Latukha/upd-CI-setup
CI: refactor CI setup config

Working gradually, need to test CI passage.

Now when most docs are removed, it is more obvious where to reduce the NOTEs.

Also synchronized the interface explicitness with what `build.sh` provides.

Would test and maybe add a new build feature check.

Working towards  #645 and #637.

Renamed `(GHCVERSION->compiler)` to correspond option with the `nix-build` and Nixpkgs Haskell Lib.

---

In the middle of work Nix installer got a major release, so also includded a bigger CI refactoring to keep CI working #648
2020-06-24 02:09:44 +03:00
Anton-Latukha b33262ccfe
CI: {.travis.yml,build.sh}: upd: make conf work with new Nix installer
M  .travis.yml
M  build.sh
2020-06-24 01:53:16 +03:00
Anton-Latukha 1871a91f94
CI: default.nix: add `compiler` explanation
M  default.nix
2020-06-23 21:06:50 +03:00
Anton-Latukha 209d0956f5
CI: {.travis.yml,build.sh}: rename (GHCVERSION->compiler)
M  .travis.yml
M  build.sh
2020-06-23 21:06:02 +03:00
Anton-Latukha 7f5798286e
CI: .travis.yml: GHC 8.10: add Haddock and sources hyperlinking
M  .travis.yml
2020-06-23 20:48:49 +03:00
Anton-Latukha 14acf24ba5
CI: .travis.yml: upd CACHIX_SIGNING_KEY explanation
M  .travis.yml
2020-06-23 20:44:11 +03:00
Anton-Latukha ebc8cb3de5
CI: .travis.yml: rm ALL_TESTS, since it does not work for nix-build
and also just plainly does not passes itself, so it is useless in CI build setup

M  .travis.yml
2020-06-23 20:37:18 +03:00
Anton-Latukha 3d9b0dae01
CI: .travis.yml: upd the disclaimer
M  .travis.yml
2020-06-23 20:35:43 +03:00
Anton-Latukha 5d0a09f3b4
CI: build.sh: mv doHyperlinkSource into logical place
M  build.sh
2020-06-23 20:31:39 +03:00
Anton-Latukha 962af5d6ba
CI: .travis.yml: {add,set,sort} features from `build.sh` explicitly
M  .travis.yml
2020-06-23 20:29:13 +03:00
Anton-Latukha 7cba5b2043
CI: .travis.yml: rm NOTEs from less important explanations
M  .travis.yml
2020-06-23 20:17:44 +03:00
Anton Latukha d3b789c631
Merge pull request #646 from Anton-Latukha/upd-CI-slash-the-docs
CI: merging the docs (`.travis.yml` -> `build.sh`)
2020-06-23 20:01:18 +03:00
Anton-Latukha e593c0ea82
CI: {.travis.yml,build.sh}: merge documentation into buildh.sh
M  .travis.yml
M  build.sh
2020-06-23 19:42:37 +03:00
Anton-Latukha 234507604f
CI: {.travis.yml,build.sh}: rename (name->project) more unique and descriptive
M  .travis.yml
M  build.sh
2020-06-23 19:42:37 +03:00