Skip to content

Commit

Permalink
Merge pull request #4770 from rkaippully/mx-linux-support
Browse files Browse the repository at this point in the history
MX linux support
  • Loading branch information
borsboom authored May 2, 2019
2 parents 28138a9 + ab7a59a commit 83f9a61
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 2 additions & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,8 @@ Behavior changes:

Other enhancements:

* Support MX Linux in get-stack.sh. Fixes
[#4769](https://github.com/commercialhaskell/stack/issues/4769).
* Defer loading up of files for local packages. This allows us to get
plan construction errors much faster, and avoid some unnecessary
work when only building a subset of packages. This is especially
Expand Down
8 changes: 6 additions & 2 deletions etc/scripts/get-stack.sh
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@ GETDISTRO
ubuntu|linuxmint|elementary|neon)
do_ubuntu_install "$VERSION"
;;
debian|kali|raspbian)
debian|kali|raspbian|mx)
do_debian_install "$VERSION"
;;
fedora)
Expand Down Expand Up @@ -609,7 +609,11 @@ try_install_pkgs() {

# Install packages using apt-get
apt_get_install_pkgs() {
if ! dpkg-query -W "$@"|grep -v '^\S\+\s\+.\+$' > /dev/null; then
# Grepping the output of dpkg-query and checking the overall status of the pipeline
# causes differing behaviors across various shell versions. So it is more portable to
# just check the staus of dpkg-query.
# See https://github.com/commercialhaskell/stack/pull/4770#pullrequestreview-229732166
if dpkg-query -W "$@" > /dev/null 2>&1; then
info "Already installed!"
elif ! sudocmd "install required system dependencies" apt-get install -y ${QUIET:+-qq} "$@"; then
die "Installing apt packages failed. Please run 'apt-get update' and try again."
Expand Down

0 comments on commit 83f9a61

Please sign in to comment.