diff --git a/.github/workflows/ghcjs.yml b/.github/workflows/ghcjs.yml index c4bd2d0f7..a36bccdd7 100644 --- a/.github/workflows/ghcjs.yml +++ b/.github/workflows/ghcjs.yml @@ -51,7 +51,7 @@ jobs: - name: 🔨 Build GHCJS version with Nix run: | - nix build .#try-rzk + nix build .#try-rzk || (nix log /nix/store/*-rzk-0.6.3.drv ; false) - name: 🔨 Collect build artifacts run: | diff --git a/docs/docs/getting-started/changelog.md b/docs/docs/getting-started/changelog.md index c72a59337..eebeeb85f 100644 --- a/docs/docs/getting-started/changelog.md +++ b/docs/docs/getting-started/changelog.md @@ -6,6 +6,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to the [Haskell Package Versioning Policy](https://pvp.haskell.org/). +## v0.6.4 — 2023-09-27 + +This version improves the stucture of the project, in particular w.r.t dependencies: + +- Add custom snapshot and explicit lower bounds (see [#108](https://github.com/rzk-lang/rzk/pull/108)) + ## v0.6.3 — 2023-09-27 This version contains a fix for the command line interface of `rzk`: diff --git a/rzk/ChangeLog.md b/rzk/ChangeLog.md index c72a59337..eebeeb85f 100644 --- a/rzk/ChangeLog.md +++ b/rzk/ChangeLog.md @@ -6,6 +6,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to the [Haskell Package Versioning Policy](https://pvp.haskell.org/). +## v0.6.4 — 2023-09-27 + +This version improves the stucture of the project, in particular w.r.t dependencies: + +- Add custom snapshot and explicit lower bounds (see [#108](https://github.com/rzk-lang/rzk/pull/108)) + ## v0.6.3 — 2023-09-27 This version contains a fix for the command line interface of `rzk`: diff --git a/rzk/package.yaml b/rzk/package.yaml index 52fc63f11..aee198888 100644 --- a/rzk/package.yaml +++ b/rzk/package.yaml @@ -1,5 +1,5 @@ name: rzk -version: 0.6.3 +version: 0.6.4 github: 'rzk-lang/rzk' license: BSD3 author: 'Nikolai Kudasov' @@ -18,26 +18,33 @@ category: Dependent Types # same as Agda # common to point users to the README.md file. description: Please see the README on GitHub at +flags: + lsp: + description: >- + Build with LSP support. + manual: true + default: true + build-tools: - - alex - - happy + alex: ">= 3.2.4" + happy: ">= 1.19.9" dependencies: - - array - - aeson - - base >= 4.7 && < 5 - - bifunctors - - bytestring - - mtl - - template-haskell - - text - - optparse-generic - - Glob - - lens - - filepath - - stm - - yaml - - data-default-class + array: ">= 0.5.3.0" + aeson: ">= 1.4.2.0" + base: ">= 4.7 && < 5" + bifunctors: ">= 5.5.3" + bytestring: ">= 0.10.8.2" + mtl: ">= 2.2.2" + template-haskell: ">= 2.14.0.0" + text: ">= 1.2.3.1" + optparse-generic: ">= 1.3.0" + Glob: ">= 0.9.3" + lens: ">= 4.17" + filepath: ">= 1.4.2.1" + stm: ">= 2.5.0.0" + yaml: ">= 0.11.0.0" + data-default-class: ">= 0.1.2.0" ghc-options: - -Wall @@ -58,7 +65,7 @@ library: - Language.Rzk.Syntax.Test - Language.Rzk.Syntax.ErrM - Language.Rzk.Syntax.Skel - - condition: '!impl(ghcjs)' + - condition: flag(lsp) && !impl(ghcjs) exposed-modules: - Language.Rzk.VSCode.Env - Language.Rzk.VSCode.Handlers @@ -66,8 +73,8 @@ library: - Language.Rzk.VSCode.State - Language.Rzk.VSCode.Tokenize dependencies: - - lsp - - lsp-types + lsp: ">= 2.1.0.0" + lsp-types: ">= 2.0.1.0" executables: rzk: @@ -80,9 +87,9 @@ executables: dependencies: - rzk when: - - condition: '!impl(ghcjs)' + - condition: flag(lsp) && !impl(ghcjs) dependencies: - - with-utf8 + with-utf8: ">= 1.0.2.4" tests: rzk-test: diff --git a/rzk/rzk.cabal b/rzk/rzk.cabal index 1708ff0a0..83204f2c4 100644 --- a/rzk/rzk.cabal +++ b/rzk/rzk.cabal @@ -5,7 +5,7 @@ cabal-version: 1.12 -- see: https://github.com/sol/hpack name: rzk -version: 0.6.3 +version: 0.6.4 synopsis: An experimental proof assistant for synthetic ∞-categories description: Please see the README on GitHub at category: Dependent Types @@ -25,6 +25,11 @@ source-repository head type: git location: https://github.com/rzk-lang/rzk +flag lsp + description: Build with LSP support. + manual: True + default: True + library exposed-modules: Free.Scoped @@ -45,26 +50,26 @@ library src ghc-options: -Wall -Wcompat -Widentities -Wincomplete-record-updates -Wincomplete-uni-patterns -Wmissing-home-modules -Wpartial-fields -Wredundant-constraints build-tools: - alex - , happy + alex >=3.2.4 + , happy >=1.19.9 build-depends: - Glob - , aeson - , array + Glob >=0.9.3 + , aeson >=1.4.2.0 + , array >=0.5.3.0 , base >=4.7 && <5 - , bifunctors - , bytestring - , data-default-class - , filepath - , lens - , mtl - , optparse-generic - , stm - , template-haskell - , text - , yaml + , bifunctors >=5.5.3 + , bytestring >=0.10.8.2 + , data-default-class >=0.1.2.0 + , filepath >=1.4.2.1 + , lens >=4.17 + , mtl >=2.2.2 + , optparse-generic >=1.3.0 + , stm >=2.5.0.0 + , template-haskell >=2.14.0.0 + , text >=1.2.3.1 + , yaml >=0.11.0.0 default-language: Haskell2010 - if !impl(ghcjs) + if flag(lsp) && !impl(ghcjs) exposed-modules: Language.Rzk.VSCode.Env Language.Rzk.VSCode.Handlers @@ -72,8 +77,8 @@ library Language.Rzk.VSCode.State Language.Rzk.VSCode.Tokenize build-depends: - lsp - , lsp-types + lsp >=2.1.0.0 + , lsp-types >=2.0.1.0 executable rzk main-is: Main.hs @@ -83,29 +88,29 @@ executable rzk app ghc-options: -Wall -Wcompat -Widentities -Wincomplete-record-updates -Wincomplete-uni-patterns -Wmissing-home-modules -Wpartial-fields -Wredundant-constraints -threaded -rtsopts -with-rtsopts=-N build-tools: - alex - , happy + alex >=3.2.4 + , happy >=1.19.9 build-depends: - Glob - , aeson - , array + Glob >=0.9.3 + , aeson >=1.4.2.0 + , array >=0.5.3.0 , base >=4.7 && <5 - , bifunctors - , bytestring - , data-default-class - , filepath - , lens - , mtl - , optparse-generic + , bifunctors >=5.5.3 + , bytestring >=0.10.8.2 + , data-default-class >=0.1.2.0 + , filepath >=1.4.2.1 + , lens >=4.17 + , mtl >=2.2.2 + , optparse-generic >=1.3.0 , rzk - , stm - , template-haskell - , text - , yaml + , stm >=2.5.0.0 + , template-haskell >=2.14.0.0 + , text >=1.2.3.1 + , yaml >=0.11.0.0 default-language: Haskell2010 - if !impl(ghcjs) + if flag(lsp) && !impl(ghcjs) build-depends: - with-utf8 + with-utf8 >=1.0.2.4 test-suite doctests type: exitcode-stdio-1.0 @@ -114,26 +119,26 @@ test-suite doctests test ghc-options: -Wall -Wcompat -Widentities -Wincomplete-record-updates -Wincomplete-uni-patterns -Wmissing-home-modules -Wpartial-fields -Wredundant-constraints build-tools: - alex - , happy + alex >=3.2.4 + , happy >=1.19.9 build-depends: Glob , QuickCheck - , aeson - , array + , aeson >=1.4.2.0 + , array >=0.5.3.0 , base - , bifunctors - , bytestring - , data-default-class + , bifunctors >=5.5.3 + , bytestring >=0.10.8.2 + , data-default-class >=0.1.2.0 , doctest - , filepath - , lens - , mtl - , optparse-generic - , stm + , filepath >=1.4.2.1 + , lens >=4.17 + , mtl >=2.2.2 + , optparse-generic >=1.3.0 + , stm >=2.5.0.0 , template-haskell - , text - , yaml + , text >=1.2.3.1 + , yaml >=0.11.0.0 default-language: Haskell2010 test-suite rzk-test @@ -145,23 +150,23 @@ test-suite rzk-test test ghc-options: -Wall -Wcompat -Widentities -Wincomplete-record-updates -Wincomplete-uni-patterns -Wmissing-home-modules -Wpartial-fields -Wredundant-constraints -threaded -rtsopts -with-rtsopts=-N build-tools: - alex - , happy + alex >=3.2.4 + , happy >=1.19.9 build-depends: - Glob - , aeson - , array + Glob >=0.9.3 + , aeson >=1.4.2.0 + , array >=0.5.3.0 , base >=4.7 && <5 - , bifunctors - , bytestring - , data-default-class - , filepath - , lens - , mtl - , optparse-generic + , bifunctors >=5.5.3 + , bytestring >=0.10.8.2 + , data-default-class >=0.1.2.0 + , filepath >=1.4.2.1 + , lens >=4.17 + , mtl >=2.2.2 + , optparse-generic >=1.3.0 , rzk - , stm - , template-haskell - , text - , yaml + , stm >=2.5.0.0 + , template-haskell >=2.14.0.0 + , text >=1.2.3.1 + , yaml >=0.11.0.0 default-language: Haskell2010 diff --git a/rzk/rzk.nix b/rzk/rzk.nix index e84f9b0eb..08c937a42 100644 --- a/rzk/rzk.nix +++ b/rzk/rzk.nix @@ -5,7 +5,7 @@ }: mkDerivation { pname = "rzk"; - version = "0.6.3"; + version = "0.6.4"; src = ./.; isLibrary = true; isExecutable = true; diff --git a/snapshot.yaml b/snapshot.yaml new file mode 100644 index 000000000..768bd4ac3 --- /dev/null +++ b/snapshot.yaml @@ -0,0 +1,8 @@ +resolver: nightly-2023-04-09 +name: rzk-snapshot +packages: + - with-utf8-1.0.2.4 + - lsp-2.1.0.0 + - lsp-types-2.0.1.0 + - row-types-1.0.1.2 + \ No newline at end of file diff --git a/stack-8.6.5.yaml b/stack-8.6.5.yaml index 0dd80e187..1a279c5be 100644 --- a/stack-8.6.5.yaml +++ b/stack-8.6.5.yaml @@ -2,4 +2,8 @@ resolver: url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/14/27.yaml packages: -- rzk/ + - rzk/ + +flags: + rzk: + lsp: false \ No newline at end of file diff --git a/stack.yaml b/stack.yaml index 94a17f29f..8ffec6992 100644 --- a/stack.yaml +++ b/stack.yaml @@ -1,74 +1,4 @@ -# This file was automatically generated by 'stack init' -# -# Some commonly used options have been documented as comments in this file. -# For advanced use and comprehensive documentation of the format, please see: -# https://docs.haskellstack.org/en/stable/yaml_configuration/ - -# Resolver to choose a 'specific' stackage snapshot or a compiler version. -# A snapshot resolver dictates the compiler version and the set of packages -# to be used for project dependencies. For example: -# -# resolver: lts-3.5 -# resolver: nightly-2015-09-21 -# resolver: ghc-7.10.2 -# -# The location of a snapshot can be provided as a file or url. Stack assumes -# a snapshot provided as a file might change, whereas a url resource does not. -# -# resolver: ./custom-snapshot.yaml -# resolver: https://example.com/snapshots/2018-01-01.yaml -resolver: nightly-2023-04-09 - -# User packages to be built. -# Various formats can be used as shown in the example below. -# -# packages: -# - some-directory -# - https://example.com/foo/bar/baz-0.0.2.tar.gz -# subdirs: -# - auto-update -# - wai +resolver: snapshot.yaml packages: - rzk -# Dependency packages to be pulled from upstream that are not in the resolver. -# These entries can reference officially published versions as well as -# forks / in-progress versions pinned to a git hash. For example: -# -# extra-deps: -# - acme-missiles-0.3 -# - git: https://github.com/commercialhaskell/stack.git -# commit: e7b331f14bcffb8367cd58fbfc8b40ec7642100a -# -extra-deps: - - with-utf8-1.0.2.4 - - Glob-0.10.2 - - lens-5.2.2 - - lsp-2.1.0.0 - - lsp-types-2.0.1.0 - - row-types-1.0.1.2 - - filepath-1.4.2.2 - - yaml-0.11.11.2 - - data-default-class-0.1.2.0 -# Override default flag values for local packages and extra-deps -# flags: {} - -# Extra package databases containing global packages -# extra-package-dbs: [] - -# Control whether we use the GHC we find on the path -# system-ghc: true -# -# Require a specific version of Stack, using version ranges -# require-stack-version: -any # Default -# require-stack-version: ">=2.9" -# -# Override the architecture used by Stack, especially useful on Windows -# arch: i386 -# arch: x86_64 -# -# Extra directories used by Stack for building -# extra-include-dirs: [/path/to/dir] -# extra-lib-dirs: [/path/to/dir] -# -# Allow a newer minor version of GHC than the snapshot specifies -# compiler-check: newer-minor + \ No newline at end of file diff --git a/stack.yaml.lock b/stack.yaml.lock index 34e0aeb5b..f35834ac6 100644 --- a/stack.yaml.lock +++ b/stack.yaml.lock @@ -11,20 +11,6 @@ packages: size: 1051 original: hackage: with-utf8-1.0.2.4 -- completed: - hackage: Glob-0.10.2@sha256:dd2ddbecae8f84e8f4cacb5b856901a19c25ceaa11f2525d3ee88d034acb0081,2938 - pantry-tree: - sha256: 3c9d365a19c0e15d7cf5e93ee994bdc81958c8e4056f43ec0408f34f1a3bb970 - size: 1432 - original: - hackage: Glob-0.10.2 -- completed: - hackage: lens-5.2.2@sha256:e01d5732173645b80f23a189a0f7e1f5cd0b2286de0ce20baf941cbf5c3b8435,15158 - pantry-tree: - sha256: b69117901be8d6fb47cf106504af0065a5271a10bdbf9d8ab89acbd0508c4653 - size: 8216 - original: - hackage: lens-5.2.2 - completed: hackage: lsp-2.1.0.0@sha256:ef6fc28eac6dc27672cd8471c9f83f14de646a9c1fcaf993a451d2ae4de274e8,3533 pantry-tree: @@ -46,27 +32,6 @@ packages: size: 1060 original: hackage: row-types-1.0.1.2 -- completed: - hackage: filepath-1.4.2.2@sha256:3622cbc524093b18af0235249087546473ab04e9fe275967680e97755a9eae6b,2225 - pantry-tree: - sha256: e8aa0c8f41f1f6801cbbc5e0f0bff434edc0fb7b9d822ec2690240051393d19b - size: 784 - original: - hackage: filepath-1.4.2.2 -- completed: - hackage: yaml-0.11.11.2@sha256:6f0a1859e0fb3068e50dbc7fe9bf9a26847741bc24344e35e16a03711a18f88d,5178 - pantry-tree: - sha256: 799f6815fe2c823561c3935bdf0cabe5f4f4a55462dc9c0d2a9838f963c97ea0 - size: 2044 - original: - hackage: yaml-0.11.11.2 -- completed: - hackage: data-default-class-0.1.2.0@sha256:63e62120b7efd733a5a17cf59ceb43268e9a929c748127172d7d42f4a336e327,542 - pantry-tree: - sha256: 5017630b11698aefa65fc61cab84a257ce97833c968d425e1b2d53d6c3b5c096 - size: 224 - original: - hackage: data-default-class-0.1.2.0 snapshots: - completed: sha256: cbf721fafa21237e4999d83cfd27137f440ae0e3032ff18fa96e8148d9bf5ce1