Skip to content

Commit

Permalink
Merge remote-tracking branch 'tracsis/master' into release
Browse files Browse the repository at this point in the history
  • Loading branch information
dten committed Jul 11, 2024
2 parents 12ea6ad + ac79e7e commit 858a3fe
Show file tree
Hide file tree
Showing 420 changed files with 22,094 additions and 15,011 deletions.
3 changes: 0 additions & 3 deletions .devcontainer/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
!/assets/cradles/
!/assets/cradles/cabal/
!/assets/cradles/stack/
!/backups/
!/bind-mounts/
!/conf/
!/conf/etc/
!/conf/etc/stack/
Expand All @@ -27,4 +25,3 @@
!/README.md

!.gitignore
!.keep
26 changes: 16 additions & 10 deletions .devcontainer/GHC.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ ARG STACK_VERSION
ARG HLS_GHC_VERSION=${HLS_VERSION:+$GHC_VERSION}
ARG HLS_SFX=/${HLS_GHC_VERSION:-all}/hls:${HLS_VERSION:-none}

ARG STACK_VERSION_OVERRIDE=${STACK_VERSION:-none}
ARG STACK_VERSION_OVERRIDE=${STACK_VERSION}

FROM ${BUILD_ON_IMAGE}:${GHC_VERSION} as files

Expand All @@ -20,8 +20,6 @@ RUN find /files -type d -exec chmod 755 {} \; \
&& find /files -type f -exec chmod 644 {} \; \
&& find /files/usr/local/bin -type f -exec chmod 755 {} \;

FROM glcr.b-data.ch/commercialhaskell/ssi:${STACK_VERSION_OVERRIDE} as ssi

FROM ${BUILD_ON_IMAGE}${HLS_SFX} as hls

FROM glcr.b-data.ch/ndmitchell/hlsi:latest as hlsi
Expand Down Expand Up @@ -88,8 +86,6 @@ RUN if [ -n "$USE_ZSH_FOR_ROOT" ]; then \
fi

## Copy binaries as late as possible to avoid cache busting
## Install Stack
COPY --from=ssi /usr/local /usr/local
## Install HLS
COPY --from=hls /usr/local /usr/local
## Install HLint
Expand All @@ -100,13 +96,23 @@ COPY --from=sci --chown=root:root /bin/shellcheck /usr/local/bin
ARG HLS_VERSION
ARG STACK_VERSION

ARG STACK_VERSION_OVERRIDE=${STACK_VERSION}
ARG STACK_VERSION_OVERRIDE

ENV HLS_VERSION=${HLS_VERSION} \
STACK_VERSION=${STACK_VERSION_OVERRIDE:-$STACK_VERSION}

RUN if [ "${GHC_VERSION%.*}" = "9.2" ]; then \
if [ -f /usr/local/bin/stack ]; then \
mv -f /usr/local/bin/stack /usr/bin/; \
fi \
RUN if [ -n "$STACK_VERSION_OVERRIDE" ]; then \
## Install Stack
cd /tmp || exit ;\
curl -sSLO https://github.com/commercialhaskell/stack/releases/download/v"$STACK_VERSION"/stack-"$STACK_VERSION"-linux-"$(uname -m)".tar.gz; \
curl -sSLO https://github.com/commercialhaskell/stack/releases/download/v"$STACK_VERSION"/stack-"$STACK_VERSION"-linux-"$(uname -m)".tar.gz.sha256; \
sha256sum -cs stack-"$STACK_VERSION"-linux-"$(uname -m)".tar.gz.sha256; \
tar -xzf stack-"$STACK_VERSION"-linux-"$(uname -m)".tar.gz; \
if dpkg --compare-versions "${GHC_VERSION%.*}" le "9.2"; then \
mv -f stack-"$STACK_VERSION"-linux-"$(uname -m)"/stack /usr/bin/stack; \
else \
mv -f stack-"$STACK_VERSION"-linux-"$(uname -m)"/stack /usr/local/bin/stack; \
fi; \
## Clean up
rm -rf /tmp/*; \
fi
2 changes: 1 addition & 1 deletion .devcontainer/LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2023 Olivier Benz
Copyright (c) 2023-2024 Olivier Benz

The code in this directory is not part of Stack (the software) and, with the
exceptions noted below, is distributed under the terms of the MIT License:
Expand Down
Empty file removed .devcontainer/backups/.keep
Empty file.
Empty file removed .devcontainer/bind-mounts/.keep
Empty file.
14 changes: 2 additions & 12 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
"build": {
"dockerfile": "GHC.Dockerfile",
"args": {
"GHC_VERSION": "9.4.7",
"HLS_VERSION": "2.2.0.0",
"GHC_VERSION": "9.6.5",
"HLS_VERSION": "2.6.0.0",
"USE_ZSH_FOR_ROOT": "unset-to-use-ash",
"SET_LANG": "C.UTF-8",
"SET_TZ": ""
Expand Down Expand Up @@ -47,16 +47,6 @@

// Set 'remoteUser' to 'root' to connect as root instead.
"remoteUser": "vscode",
"mounts": [
"source=stack-default-home-vscode,target=/home/vscode,type=volume"
// "source=${localWorkspaceFolder}/.devcontainer/bind-mounts/stack-default-home-vscode,target=/home/vscode,type=bind"
],

// "remoteUser": "root",
// "mounts": [
// "source=stack-default-root,target=/root,type=volume"
// // "source=${localWorkspaceFolder}/.devcontainer/bind-mounts/stack-default-root,target=/root,type=bind"
// ],

// Pip: Install packages to the user site
"remoteEnv": {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"name": "GHC 9.6.2",
"name": "GHC 9.8.1",
"build": {
"dockerfile": "../GHC.Dockerfile",
"context": "..",
"args": {
"GHC_VERSION": "9.6.2",
"GHC_VERSION": "9.8.1",
"USE_ZSH_FOR_ROOT": "unset-to-use-ash",
"SET_LANG": "C.UTF-8",
"SET_TZ": ""
Expand Down Expand Up @@ -45,16 +45,6 @@

// Set 'remoteUser' to 'root' to connect as root instead.
"remoteUser": "vscode",
"mounts": [
"source=stack-ghc-9.6.2-home-vscode,target=/home/vscode,type=volume"
// "source=${localWorkspaceFolder}/.devcontainer/bind-mounts/stack-ghc-9.6.2-home-vscode,target=/home/vscode,type=bind"
],

// "remoteUser": "root",
// "mounts": [
// "source=stack-ghc-9.6.2-root,target=/root,type=volume"
// // "source=${localWorkspaceFolder}/.devcontainer/bind-mounts/stack-ghc-9.6.2-root,target=/root,type=bind"
// ],

// Pip: Install packages to the user site
"remoteEnv": {
Expand Down
13 changes: 12 additions & 1 deletion .devcontainer/scripts/usr/local/bin/onCreateCommand.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@

set -e

mkdir -p "$HOME/.cabal/bin"
if dpkg --compare-versions "${CABAL_VERSION%.*.*}" le-nl "3.8"; then
mkdir -p "$HOME/.cabal/bin";
fi
mkdir -p "$HOME/.local/bin"

# Copy Zsh-related files and folders from the untouched home directory
Expand All @@ -27,12 +29,21 @@ else
fi

# Set PATH so it includes user's private bin if it exists
if ! grep -q "user's private bin" "$HOME/.bashrc"; then
echo -e "\nPATH=\"\${PATH%:\$HOME/.local/bin}\"" >> "$HOME/.bashrc";
echo -e "\n# set PATH so it includes user's private bin if it exists\nif [ -d \"\$HOME/bin\" ] && [[ \"\$PATH\" != *\"\$HOME/bin\"* ]] ; then\n PATH=\"\$HOME/bin:\$PATH\"\nfi" >> "$HOME/.bashrc";
echo -e "\n# set PATH so it includes user's private bin if it exists\nif [ -d \"\$HOME/.local/bin\" ] && [[ \"\$PATH\" != *\"\$HOME/.local/bin\"* ]] ; then\n PATH=\"\$HOME/.local/bin:\$PATH\"\nfi" >> "$HOME/.bashrc";
fi
if ! grep -q "user's private bin" "$HOME/.zshrc"; then
echo -e "\nPATH=\"\${PATH%:\$HOME/.local/bin}\"" >> "$HOME/.zshrc";
echo -e "\n# set PATH so it includes user's private bin if it exists\nif [ -d \"\$HOME/bin\" ] && [[ \"\$PATH\" != *\"\$HOME/bin\"* ]] ; then\n PATH=\"\$HOME/bin:\$PATH\"\nfi" >> "$HOME/.zshrc";
echo -e "\n# set PATH so it includes user's private bin if it exists\nif [ -d \"\$HOME/.local/bin\" ] && [[ \"\$PATH\" != *\"\$HOME/.local/bin\"* ]] ; then\n PATH=\"\$HOME/.local/bin:\$PATH\"\nfi" >> "$HOME/.zshrc";
fi

# Set PATH so it includes cabal's bin if it exists
if ! grep -q "cabal's bin" "$HOME/.bashrc"; then
echo -e "\n# set PATH so it includes cabal's bin if it exists\nif [ -d \"\$HOME/.cabal/bin\" ] && [[ \"\$PATH\" != *\"\$HOME/.cabal/bin\"* ]] ; then\n PATH=\"\$HOME/.cabal/bin:\$PATH\"\nfi" >> "$HOME/.bashrc";
fi
if ! grep -q "cabal's bin" "$HOME/.zshrc"; then
echo -e "\n# set PATH so it includes cabal's bin if it exists\nif [ -d \"\$HOME/.cabal/bin\" ] && [[ \"\$PATH\" != *\"\$HOME/.cabal/bin\"* ]] ; then\n PATH=\"\$HOME/.cabal/bin:\$PATH\"\nfi" >> "$HOME/.zshrc";
fi
Expand Down
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ about: Report a bug in Stack

Please follow the steps below for reporting a bug in Stack:

Make sure that you are using the latest release (currently Stack 2.11.1). See the
Make sure that you are using the latest release (currently Stack 2.13.1). See the
[upgrade instructions](http://docs.haskellstack.org/en/stable/install_and_upgrade/#upgrade)
to upgrade.

Expand Down Expand Up @@ -45,7 +45,7 @@ stack <your command here> <args> --verbose

~~~text
stack --version
Version 2.11.1, Git revision c1167a6abc3f4978ccded5ba0246a57387da0e2f x86_64 hpack-0.35.2
Version 2.13.1, Git revision 8102bb8afce90fc954f48efae38b87f37cabc988 x86_64 hpack-0.36.0
~~~

### Method of installation
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Feature Request
about: Request a feature be added to Stack, or discuss such a feature
---

Make sure that you are using the latest release (currently Stack 2.11.1). See the
Make sure that you are using the latest release (currently Stack 2.13.1). See the
[upgrade instructions](http://docs.haskellstack.org/en/stable/install_and_upgrade/#upgrade)
to upgrade.

Expand Down
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/question.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ the [stack-templates](https://github.com/commercialhaskell/stack-templates)
repository instead.

If you still want to ask the question here instead, please make sure that you
are using the latest release (currently Stack 2.11.1). See the
are using the latest release (currently Stack 2.13.1). See the
[upgrade instructions](http://docs.haskellstack.org/en/stable/install_and_upgrade/#upgrade)
to upgrade.

### Stack version

~~~text
stack --version
Version 2.11.1, Git revision c1167a6abc3f4978ccded5ba0246a57387da0e2f x86_64 hpack-0.35.2
Version 2.13.1, Git revision 8102bb8afce90fc954f48efae38b87f37cabc988 x86_64 hpack-0.36.0
~~~

### Method of installation
Expand Down
Loading

0 comments on commit 858a3fe

Please sign in to comment.