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

Package updates 2024 08 #25

Merged
merged 6 commits into from
Aug 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 26 additions & 25 deletions .github/workflows/haskell-ci.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# This GitHub workflow config has been generated by a script via
#
# haskell-ci 'github' 'aws-arn.cabal' '--hlint' '--doctest'
# haskell-ci 'github' '--doctest' 'aws-arn.cabal'
#
# To regenerate the script (for example after adjusting tested-with) run
#
# haskell-ci regenerate
#
# For more information, see https://github.com/haskell-CI/haskell-ci
#
# version: 0.18.1
# version: 0.19.20240708
#
# REGENDATA ("0.18.1",["github","aws-arn.cabal","--hlint","--doctest"])
# REGENDATA ("0.19.20240708",["github","--doctest","aws-arn.cabal"])
#
name: Haskell-CI
on:
Expand All @@ -23,11 +23,21 @@ jobs:
timeout-minutes:
60
container:
image: buildpack-deps:bionic
image: buildpack-deps:jammy
continue-on-error: ${{ matrix.allow-failure }}
strategy:
matrix:
include:
- compiler: ghc-9.8.2
compilerKind: ghc
compilerVersion: 9.8.2
setup-method: ghcup
allow-failure: false
- compiler: ghc-9.6.6
compilerKind: ghc
compilerVersion: 9.6.6
setup-method: ghcup
allow-failure: false
- compiler: ghc-9.4.5
compilerKind: ghc
compilerVersion: 9.4.5
Expand Down Expand Up @@ -55,10 +65,10 @@ jobs:
apt-get update
apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5
mkdir -p "$HOME/.ghcup/bin"
curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup"
curl -sL https://downloads.haskell.org/ghcup/0.1.30.0/x86_64-linux-ghcup-0.1.30.0 > "$HOME/.ghcup/bin/ghcup"
chmod a+x "$HOME/.ghcup/bin/ghcup"
"$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
"$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
"$HOME/.ghcup/bin/ghcup" install cabal 3.12.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
env:
HCKIND: ${{ matrix.compilerKind }}
HCNAME: ${{ matrix.compiler }}
Expand All @@ -76,7 +86,7 @@ jobs:
echo "HC=$HC" >> "$GITHUB_ENV"
echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
echo "CABAL=$HOME/.ghcup/bin/cabal-3.12.1.0 -vnormal+nowrap" >> "$GITHUB_ENV"
HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')
echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV"
echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV"
Expand Down Expand Up @@ -124,9 +134,9 @@ jobs:
run: |
$CABAL v2-update -v
- name: cache (tools)
uses: actions/cache/restore@v3
uses: actions/cache/restore@v4
with:
key: ${{ runner.os }}-${{ matrix.compiler }}-tools-a7f684fe
key: ${{ runner.os }}-${{ matrix.compiler }}-tools-ac1dc7e1
path: ~/.haskell-ci-tools
- name: install cabal-plan
run: |
Expand All @@ -139,22 +149,16 @@ jobs:
cabal-plan --version
- name: install doctest
run: |
$CABAL --store-dir=$HOME/.haskell-ci-tools/store v2-install $ARG_COMPILER --ignore-project -j2 doctest --constraint='doctest ^>=0.20'
$CABAL --store-dir=$HOME/.haskell-ci-tools/store v2-install $ARG_COMPILER --ignore-project -j2 doctest --constraint='doctest ^>=0.22.0'
doctest --version
- name: install hlint
run: |
if [ $((HCNUMVER >= 90400)) -ne 0 ] ; then HLINTVER=$(cd /tmp && (${CABAL} v2-install -v $ARG_COMPILER --dry-run hlint --constraint='hlint >=3.5 && <3.6' | perl -ne 'if (/\bhlint-(\d+(\.\d+)*)\b/) { print "$1"; last; }')); echo "HLint version $HLINTVER" ; fi
if [ $((HCNUMVER >= 90400)) -ne 0 ] ; then if [ ! -e $HOME/.haskell-ci-tools/hlint-$HLINTVER/hlint ]; then echo "Downloading HLint version $HLINTVER"; mkdir -p $HOME/.haskell-ci-tools; curl --write-out 'Status Code: %{http_code} Redirects: %{num_redirects} Total time: %{time_total} Total Dsize: %{size_download}\n' --silent --location --output $HOME/.haskell-ci-tools/hlint-$HLINTVER.tar.gz "https://github.com/ndmitchell/hlint/releases/download/v$HLINTVER/hlint-$HLINTVER-x86_64-linux.tar.gz"; tar -xzv -f $HOME/.haskell-ci-tools/hlint-$HLINTVER.tar.gz -C $HOME/.haskell-ci-tools; fi ; fi
if [ $((HCNUMVER >= 90400)) -ne 0 ] ; then mkdir -p $CABAL_DIR/bin && ln -sf "$HOME/.haskell-ci-tools/hlint-$HLINTVER/hlint" $CABAL_DIR/bin/hlint ; fi
if [ $((HCNUMVER >= 90400)) -ne 0 ] ; then hlint --version ; fi
- name: save cache (tools)
uses: actions/cache/save@v3
uses: actions/cache/save@v4
if: always()
with:
key: ${{ runner.os }}-${{ matrix.compiler }}-tools-a7f684fe
key: ${{ runner.os }}-${{ matrix.compiler }}-tools-ac1dc7e1
path: ~/.haskell-ci-tools
- name: checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: source
- name: initial cabal.project for sdist
Expand Down Expand Up @@ -182,15 +186,15 @@ jobs:
echo " ghc-options: -Werror=missing-methods" >> cabal.project
cat >> cabal.project <<EOF
EOF
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: $_ installed\n" unless /^(aws-arn)$/; }' >> cabal.project.local
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: any.$_ installed\n" unless /^(aws-arn)$/; }' >> cabal.project.local
cat cabal.project
cat cabal.project.local
- name: dump install plan
run: |
$CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH --dry-run all
cabal-plan
- name: restore cache
uses: actions/cache/restore@v3
uses: actions/cache/restore@v4
with:
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
path: ~/.cabal/store
Expand All @@ -212,9 +216,6 @@ jobs:
run: |
cd ${PKGDIR_aws_arn} || false
doctest -XHaskell2010 src
- name: hlint
run: |
if [ $((HCNUMVER >= 90400)) -ne 0 ] ; then (cd ${PKGDIR_aws_arn} && hlint -XHaskell2010 src) ; fi
- name: cabal check
run: |
cd ${PKGDIR_aws_arn} || false
Expand All @@ -227,7 +228,7 @@ jobs:
rm -f cabal.project.local
$CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks all
- name: save cache
uses: actions/cache/save@v3
uses: actions/cache/save@v4
if: always()
with:
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.pre-commit-config.yaml
cabal.project.local*
dist/
dist-newstyle/
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Revision history for aws-arn

## 0.3.2.0 -- 2024-08-20

* Use prisms and isos from `microlens-pro`.

## 0.3.1.0 -- 2023-03-01

* Add `Network.AWS.ARN.S3` with support for S3 bucket and object ARNs.
Expand Down
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,7 @@ add a new resource:
`test/Network/AWS/ARN/SomeAWSService/Test.hs`

4. Define a `_Foo` `Prism'` that combines the parsing/unparsing
functions above. Use the local definitions of prisms in
`Network.AWS.ARN.Internal.Lens`:
functions above:

```haskell
_Function :: Prism' Text Function
Expand Down
36 changes: 18 additions & 18 deletions aws-arn.cabal
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cabal-version: 2.2
name: aws-arn
version: 0.3.1.0
cabal-version: 2.2
name: aws-arn
version: 0.3.2.0
synopsis:
Types and optics for manipulating Amazon Resource Names (ARNs)

Expand All @@ -25,20 +25,20 @@ description:
add this support for more AWS resource types are __especially__
welcome.

bug-reports: http://github.com/bellroy/aws-arn/issues
license: BSD-3-Clause
license-file: LICENSE
author: Bellroy Tech Team <[email protected]>
maintainer: Bellroy Tech Team <[email protected]>
copyright: Copyright (C) 2020-2022 Bellroy Pty Ltd
category: AWS, Cloud
build-type: Simple
extra-source-files:
bug-reports: http://github.com/bellroy/aws-arn/issues
license: BSD-3-Clause
license-file: LICENSE
author: Bellroy Tech Team <[email protected]>
maintainer: Bellroy Tech Team <[email protected]>
copyright: Copyright (C) 2020-2022 Bellroy Pty Ltd
category: AWS, Cloud
build-type: Simple
extra-doc-files:
CHANGELOG.md
README.md

tested-with:
GHC ==8.10.7 || ==9.0.2 || ==9.2.5 || ==9.4.5 || ==9.6.5
GHC ==8.10.7 || ==9.0.2 || ==9.2.5 || ==9.4.5 || ==9.6.6 || ==9.8.2

common opts
default-language: Haskell2010
Expand All @@ -51,21 +51,21 @@ common opts

common deps
build-depends:
, base >=4.12 && <4.19
, base >=4.12 && <4.20
, deriving-compat >=0.5.10 && <0.7
, microlens-pro ^>=0.2
, profunctors >=5.0 && <5.7
, tagged ^>=0.8
, text ^>=1.2.3 || >=2.0 && <2.1 || ^>=2.1
, text ^>=1.2.3 || ^>=2.0 || ^>=2.1

library
import: opts, deps
exposed-modules:
Network.AWS.ARN
Network.AWS.ARN.Internal.Lens
Network.AWS.ARN.Lambda
Network.AWS.ARN.S3

build-depends: hashable >=1.3.0.0 && <1.5
build-depends: hashable >=1.3.0.0 && <1.6
hs-source-dirs: src

test-suite spec
Expand All @@ -81,7 +81,7 @@ test-suite spec
ghc-options: -threaded
build-depends:
, aws-arn
, tasty >=1.4.0.2 && <1.5 || ^>=1.5
, tasty ^>=1.4.0.2 || ^>=1.5
, tasty-hunit ^>=0.10.0.3

build-tool-depends: tasty-discover:tasty-discover >=4.2.2 && <5.1
Expand Down
17 changes: 0 additions & 17 deletions aws-arn.nix

This file was deleted.

95 changes: 87 additions & 8 deletions flake.lock

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

Loading
Loading